Coorpacademy External Resources API

Mints a presigned S3 URL for uploading external content of a given file extension. 1 path / 1 operation. The published spec declares no security scheme.

OpenAPI Specification

coorpacademy-external-openapi.json Raw ↑
{"openapi":"3.0.0","info":{"description":"API to get external resources","version":"1.0.0","title":"external API"},"servers":[{"url":"https://api.coorpacademy.com/external","description":"production"},{"url":"https://api-staging.coorpacademy.com/h5p","description":"staging"}],"components":{"schemas":{"Success":{"type":"string","description":"s3 url","example":"{\"uploadUrl\":\"https://s3.eu-west-1.amazonaws.com/external-staging.coorpacademy.com/resource-id.content_type&Content-Type=application/content_type&x-amz-meta-content-disposition=inline&x-amz-security-token=secret&Signature=foo\",\"fetchUrl\":\"//localhost:7004/resource-id.content_type\"}"},"InternalError":{"description":"InternalError","type":"string","example":"Unable to get presigned upload URL from S3"},"NotDefinedError":{"description":"NotDefinedError","type":"string","example":"File extension is not defined"}}},"paths":{"/presignedUrl/{ext}":{"post":{"tags":["External post"],"parameters":[{"name":"ext","in":"path","required":true,"schema":{"type":"string"},"description":"The type of the external content","example":"pdf, mp4, png"}],"summary":"Get signed s3 url for external content upload.","description":"","operationId":"externalPOST","responses":{"200":{"description":"Get signed s3 url for external content upload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"description":"Undefined/ Internal errors.","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/NotDefinedError"},{"$ref":"#/components/schemas/InternalError"}]}}}}}}}}}