How to upload a txt/img file through POSTMAN POST Call
Hi @Lions ignitz Welcome to the Atlassian Community!
You can add attachment to a confluence page by sending a POST request to the /rest/api/content/<pageID>/child/attachment API endpoint.
Example Curl Command -
curl -u $USER_NAME:$USER_PASSWORD -X POST -H "X-Atlassian-Token: nocheck" -F "file=@${ATTACHMENT_FILE_NAME}" -F "comment=File attached via REST API" ${CONFLUENCE_BASE_URL}/rest/api/content/${PAGE_ID}/child/attachment
Please change USER_NAME/USER_PASSWORD/ATTACHMENT_FILE_NAME/CONFLUENCE_BASE_URL/PAGE_ID as necessary in the above command.
Hi @Lions ignitz ,
welcome to the Atlassian Community!
Would you please provide us with more information, what you are trying to achieve? Add one or more attachments to an existing Confluence content?
Thank you!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.