Request an upload slot for a file. The server responds with a
pre-signed upload URL (or equivalent mechanism) and the UHRP URL
that will address the content once the upload is complete.
The client then issues a PUT request to the returned uploadURL with
the raw file bytes.
Body application/json
fileSizeintegerrequired
Exact byte length of the file to be uploaded.
sha256stringrequired
SHA-256 hash of the file content (hex, 64 characters).
mimeTypestring
Optional MIME type of the file.
retentionDaysinteger
Requested number of days the advertisement token should remain
valid. The server may cap this value.
Response
Upload slot allocated.
uhrpUrlstring
The UHRP URL that will address this content. Encoded as
Base58Check with prefix ce00 over the SHA-256 hash.
uploadUrlstring<uri>
Pre-signed HTTPS URL. The client MUST issue a PUT request with
the raw file bytes to this URL to complete the upload.
expiresAtinteger
UNIX timestamp (seconds) when the upload URL expires.
Bad request — invalid input.
errorstring
Human-readable error description.
codestring
Machine-readable error code (see specs/errors.md).
Missing or invalid BRC-103 authentication.
errorstring
Human-readable error description.
codestring
Machine-readable error code (see specs/errors.md).
Internal server error.
errorstring
Human-readable error description.
codestring
Machine-readable error code (see specs/errors.md).