Get upload links for large files
For files too large to send inline (one request to the API stays under 4 MB). Send path, sha256 and bytes for each file; the response contains an upload_url for each file. PUT the exact bytes to it within 15 minutes (curl -T file '<upload_url>'); the upload checks size, SHA-256 and the type of the bytes (422 type_mismatch) and stores the file. Video and audio above the inline limit (paid plans: up to the bytes_per_media limit) can only be uploaded this way. Then deploy with POST /sites or PUT /sites/{id}, naming the file with path, sha256 and bytes instead of content. A file another site of this project already has needs no new upload. The size is checked against the limits of the project's plan. Free: at most 200 files, 5 MB per file (a PDF 10 MB, video or audio 10 MB) and 50 MB together; with a paid plan or credit 2,000 files, 25 MB per file (a PDF 25 MB, video or audio up to 90 MB via create_upload_urls) and 1 GB together.
Request
- Base URL: https://api.hypamoon.com/api/v1
- URL: https://api.hypamoon.com/api/v1/sites/uploads
- Auth: one of:
- HTTP bearer
- OAuth 2 (authorization code, authorization URL https://app.hypamoon.com/oauth/authorize, token URL https://api.hypamoon.com/oauth/token, scopes: sites:write)
Request body
Response
The upload links.
Changes
No recorded changes to this operation across all 1 revision of this API.