Secure File Integration for Developers
Upload files instantly. Generate secure links. Share with confidence.
99.9%
Uptime
256-bit
Encryption
∞
Bandwidth
report.pdf
presentation.mp4
design.png
Upload Files
Drag & drop or click to upload files (Max 5 files, 200MB each)
Drop files here
or click to browse
Up to 5 files
200MB each
Secure links
Upload History
Your previously uploaded files
No upload history yet
Upload files to see them here
Developer Integration
Integrate LinkCore into your applications
// LinkCore API Integration - JavaScript
async function uploadToLinkCore(file) {
const formData = new FormData();
formData.append('file', file);
try {
const response = await fetch('api.php', {
method: 'POST',
body: formData
});
const data = await response.json();
if (data.success) {
console.log('File uploaded successfully:', data.url);
return data.url;
} else {
throw new Error(data.error || 'Upload failed');
}
} catch (error) {
console.error('Upload error:', error);
throw error;
}
}
// Usage
const fileInput = document.getElementById('fileInput');
fileInput.addEventListener('change', async (e) => {
const file = e.target.files[0];
if (file) {
const link = await uploadToLinkCore(file);
// Use the generated link
}
});
# LinkCore API Integration - Python
import requests
def upload_to_linkcore(file_path):
"""
Upload a file to LinkCore and get the shareable link
"""
url = 'https://yourdomain.com/api.php'
with open(file_path, 'rb') as file:
files = {'file': file}
response = requests.post(url, files=files)
data = response.json()
if data.get('success'):
return data['url']
else:
raise Exception(data.get('error', 'Upload failed'))
# Usage
try:
file_link = upload_to_linkcore('document.pdf')
print(f"File uploaded: {file_link}")
except Exception as e:
print(f"Error: {e}")
// LinkCore API Integration - PHP
function uploadToLinkCore($file) {
$apiUrl = 'https://yourdomain.com/api.php';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $apiUrl);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, [
'file' => new CURLFile($file['tmp_name'], $file['type'], $file['name'])
]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
$data = json_decode($response, true);
if ($data['success']) {
return $data['url'];
} else {
throw new Exception($data['error'] ?? 'Upload failed');
}
}
// Usage
if ($_FILES['file']) {
try {
$link = uploadToLinkCore($_FILES['file']);
echo "File uploaded: " . $link;
} catch (Exception $e) {
echo "Error: " . $e->getMessage();
}
}
// LinkCore API Integration - Node.js
const axios = require('axios');
const FormData = require('form-data');
const fs = require('fs');
async function uploadToLinkCore(filePath) {
const formData = new FormData();
formData.append('file', fs.createReadStream(filePath));
try {
const response = await axios.post('https://yourdomain.com/api.php', formData, {
headers: formData.getHeaders()
});
if (response.data.success) {
return response.data.url;
} else {
throw new Error(response.data.error || 'Upload failed');
}
} catch (error) {
console.error('Upload error:', error);
throw error;
}
}
// Usage
uploadToLinkCore('./document.pdf')
.then(link => console.log('File uploaded:', link))
.catch(error => console.error('Error:', error));
# LinkCore API Integration - cURL
curl -X POST https://yourdomain.com/api.php \
-F "file=@/path/to/your/file.pdf" \
-H "Content-Type: multipart/form-data"
# Expected response:
# {
# "success": true,
# "url": "https://files.linkcore.com/abc123.pdf",
# "filename": "file.pdf",
# "size": "2.5 MB"
# }
# With error handling
response=$(curl -s -X POST https://yourdomain.com/api.php \
-F "file=@document.pdf")
echo $response | grep -q '"success":true'
if [ $? -eq 0 ]; then
url=$(echo $response | grep -o '"url":"[^"]*"' | cut -d'"' -f4)
echo "Upload successful: $url"
else
error=$(echo $response | grep -o '"error":"[^"]*"' | cut -d'"' -f4)
echo "Upload failed: $error"
fi
Secure & Encrypted
All transfers are encrypted with 256-bit SSL
Fast & Reliable
Global CDN with 99.9% uptime guarantee
No Rate Limits
Unlimited uploads with generous bandwidth