Files
medusa-store/www/apps/api-reference/specs/admin/paths/admin_uploads.yaml
github-actions[bot] d6dcda5b8f chore(docs): Updated API Reference (v2) (#8929)
Automated changes by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action
2024-09-02 07:45:24 +00:00

70 lines
2.0 KiB
YAML

post:
operationId: PostUploads
summary: Create Upload
description: Create a upload.
x-authenticated: true
parameters: []
security:
- api_token: []
- cookie_auth: []
- jwt_token: []
requestBody:
content:
application/json:
schema:
oneOf:
- type: object
description: SUMMARY
required:
- files
properties:
files:
type: array
description: The upload's files.
items:
oneOf:
- type: object
description: The file's files.
required:
- name
- content
properties:
name:
type: string
title: name
description: The file's name.
content:
type: string
title: content
description: The file's content.
- $ref: ../components/schemas/File.yaml
- $ref: ../components/schemas/FileList.yaml
description: SUMMARY
x-codeSamples:
- lang: Shell
label: cURL
source:
$ref: ../code_samples/Shell/admin_uploads/post.sh
tags:
- Uploads
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: ../components/schemas/AdminFileListResponse.yaml
'400':
$ref: ../components/responses/400_error.yaml
'401':
$ref: ../components/responses/unauthorized.yaml
'404':
$ref: ../components/responses/not_found_error.yaml
'409':
$ref: ../components/responses/invalid_state_error.yaml
'422':
$ref: ../components/responses/invalid_request_error.yaml
'500':
$ref: ../components/responses/500_error.yaml
x-workflow: uploadFilesWorkflow