Skip to main content
POST
/
v3
/
orgs
/
{org_id}
/
media
/
images
Creates a new image
curl --request POST \
  --url https://api.ctrl-hub.com/v3/orgs/{org_id}/media/images \
  --header 'Content-Type: application/vnd.api+json' \
  --header 'X-Session-Token: <api-key>' \
  --data '
{
  "data": {
    "type": "<string>",
    "attributes": {
      "content": "<string>"
    }
  }
}
'
{
  "data": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "type": "<string>",
    "attributes": {
      "content": "<string>",
      "mime_type": "<string>",
      "extension": "<string>",
      "width": 2,
      "height": 2,
      "bytes": 1
    },
    "meta": {
      "created_at": "2023-11-07T05:31:56Z",
      "updated_at": "2023-11-07T05:31:56Z"
    },
    "relationships": {
      "organisation": {
        "data": {
          "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "type": "<string>"
        }
      },
      "author": {
        "data": {
          "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "type": "<string>"
        }
      }
    }
  },
  "jsonapi": {
    "version": "<string>"
  }
}

Authorizations

X-Session-Token
string
header
required

Session token for authentication.

Path Parameters

org_id
string<uuid>
required

The unique identifier for the organisation.

Body

application/vnd.api+json

The image to create.

data
object
required

Response

Get an image.

JSON API response object

data
object
required

An image

jsonapi
object
required