Skip to main content

Add an asset to an extension

POST/contributors/{contributorId}/extensions/{extensionId}/assets/
v2
POST
extension-request-asset-upload

Request

  • contributorIdstring
    required
  • extensionIdstring (uuid)
    required

Responses

application/json

The Upload of an asset for the extension has been requested.

  • assetRefIdstring (uuid)
    required

    Use the ID as upload token at /v2/files/{assetRefId}. This ID will also be the ID of your asset in extension.

  • rulesobject
    required

    Constraints for the asset image or video upload, defers on the given assetType.

    • extensionsarray of string
      required
      • Array[
      • *string
      • ]
  • fileTypesarray of object
    required
    • Array[
    • *object
      • extensionsarray of string
        required
        • Array[
        • *string
        • ]
    • mimeTypestring
      required
  • ]
  • maxSizeInBytesinteger
    required
  • mimeTypesarray of string
    required
    • Array[
    • *string
    • ]
  • propertiesobject
    • imageDimensionsobject
      • maxobject
        required
        • heightinteger
        • widthinteger
      • minobject
        required
        • heightinteger
        • widthinteger
  • Usage examples

    $ curl \
    --fail \
    --location \
    -X POST \
    -d '{"assetType":"image"}' \
    -H "Authorization: Bearer $MITTWALD_API_TOKEN" \
    -H 'Content-Type: application/json' \
    https://api.mittwald.de/v2/contributors/string/extensions/f0f86186-0a5a-45b2-aa33-502777496347/assets