Postonus
APIReferenceUploads

Import a file from a public URL

POST
/uploads/from-url

Authorization

apiKey
headerx-api-key<token>

Request Body

application/json
  1. body
url*string
Formaturi
scenarioId*string
Value in"post_attachments""user_avatar"

Response Body

OK

application/json
  1. response
uploadId*string
Formatuuid
mediaId*|null
publicUrl*string
type*string
Value in"IMAGE""GIF""VIDEO"
bytes?integer
Range-9007199254740991 <= value <= 9007199254740991
Example Request
curl -X POST 'https://app.postonus.com/api/v1/uploads/from-url' \  -H 'Content-Type: application/json' \  -d '{  "url": "http://example.com",  "scenarioId": "post_attachments"}'
Example Response
{  "uploadId": "ef523ba8-509e-47af-8e2c-5fa751596497",  "mediaId": "5a8ffac5-2288-485d-b463-90c3cd9941ad",  "publicUrl": "string",  "type": "IMAGE",  "bytes": -9007199254740991}