POST /api/boards/items/artifacts

Adds the first artifact, such as an uploaded image or file, to be used in the markdown for a Board item that is being created.

Note: If you are adding an artifact to a new board item, use the POST /api/boards/items/artifacts operation (this operation). The BoardItemID is assigned, and is returned in the response. If you are adding a subsequent artifact, use the POST /api/boards/items/{BoardItemID}/artifacts operation, referencing the BoardItemID that was assigned in the response for the first operation.

Authorization Roles/Permissions: Must be logged in. Must have visibility of the Board. For more information about how authorization and visibility work for Board operations, see Boards in the developer portal.

This topic includes the following sections:

HTTP Method


Back to top



Back to top

Sample Request

The example below shows adding an artifact to a new board item.

Request URL


Sample request headers

POST http://{hostname}/api/boards/items/artifacts HTTP/1.0
Host: {hostname}
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8

Sample request body

The request body is the uploaded image or other file.

Back to top

Request Headers

For general information on request header values, refer to HTTP Request Headers.

Header Description
Accept application/json, application/vnd.soa.v71+json, application/vnd.soa.v72+json, application/vnd.soa.v80+json, application/vnd.soa.v81+json
Content-Type multipart/form-data
AtmoAuthToken_{fedmemberid} The platform cookie. This is the Akana API Platform authorization token, and must be sent with every API request that requires login.
X-Csrf-Token_{fedmemberID} The CSRF prevention header; may or may not be required, depending on platform settings. See CSRF Prevention on the Platform. By default, the CSRF header is not required for GET operations and is required for all others, with a few exceptions relating to user login.

Back to top

Request Parameters

Parameter Parm Type Data Type Required Description
BoardItemID Path string Required The unique ID for a specific Board item. Can be the unique ID for any Board item that supports markdown: Discussion, Ticket, Alert, Review, or Comment.
InMultiPart Body multipart Required The artifact; an image or other file to be uploaded as part of the content of the board item. For more information, see Managing Multipart/Form-Data Uploads.

Back to top


If successful, this operation returns HTTP status code 200, with information about the artifact that was uploaded.

Back to top

Sample Response

The sample response below shows successful completion of this operation. The Board Item ID is assigned as a result of this operation.

Sample response headers: application/json

HTTP/1.1 200 OK
Content-Type: text/html
Expires: Fri, 22 May 2015 14:40:04 GMT

Sample response body: application/json

  "ContextID" : "f4827eb8-5a9f-429a-8b2a-4ef2f7f8af8c.acmepaymentscorp",
  "FileName" : "img_dollars.jpg",
  "BaseUri" : "http://{hostname}",
  "UriPath" : "/api/boards/items/f4827eb8-5a9f-429a-8b2a-4ef2f7f8af8c.acmepaymentscorp/img_dollars.jpg"

Back to top

Response Headers

For general information on response header values, refer to HTTP Response Headers.

Header Description
Content-Type application/json, application/vnd.soa.v71+json, application/vnd.soa.v72+json, application/vnd.soa.v80+json, application/vnd.soa.v81+json

Back to top

Response Body

Name Type Description
BoardItemArtifact BoardItemArtifact Contains information about an image or other artifact associated with a Board item. Applicable only if the DescriptionMediaType for the Board item is text/markdown.

Back to top

Error Codes/Messages

If the call is unsuccessful an error code/message is returned. One or more examples of possible errors for this operation are shown below.

Item Value
401 Unauthorized. For example, you would get this response if you didn't include the custom X-Csrf-Token_{fedmemberID} header in the request, when it was required by the platform settings; or if you included an invalid or expired value for this header. You would also get this response for any operation that requires login (almost all) if the login cookie was missing.

An error occurred processing the call.

You would also get this error if you try to upload an artifact that already exists.

More information about Akana API Platform API error messages.

Back to top

Related Topics