---
ai:
  exclude: true
search:
  tags:
    - project
    - POST
seo:
  description: >-
    Creates temporary… Reference for the POST
    /api/2/project/{projectIdOrKey}/avatar/temporary endpoint in the Jira
    Software Data Center REST API Reference.
sidebar:
  label: Store temporary avatar using multipart
  badge: POST
title: Store temporary avatar using multipart
type: openapi-operation
---
Creates temporary avatar using multipart. The response is sent back as JSON stored in a textarea. This is because
the client uses remote iframing to submit avatars using multipart. So we must send them a valid HTML page back from
which the client parses the JSON.

`POST /api/2/project/{projectIdOrKey}/avatar/temporary`

**Request body** (`multipart/form-data`)

- `contentType` (string)
- `formField` (boolean)
- `inputStream` (object)
- `name` (string)
- `size` (integer<int64>)
- `value` (string)

Request body example:

```json
{
  "contentType": "string",
  "formField": true,
  "inputStream": {},
  "name": "string",
  "size": 0,
  "value": "string"
}
```

**Responses**

- `201` — Temporary avatar cropping instructions embeded in HTML page. Error messages will also be embeded in the page.
- `404` — Returned if the currently authenticated user does not have EDIT PROJECT permission

Response example, 201:

```json
{
  "cropperOffsetX": 50,
  "cropperOffsetY": 50,
  "cropperWidth": 120,
  "needsCropping": true,
  "url": "http://example.com/jira/secure/temporaryavatar?cropped=true"
}
```
