|
| 1 | +operationId: images_post_account_transfer_accept |
| 2 | + |
| 3 | +summary: Accept an Image Account Transfer |
| 4 | + |
| 5 | +description: | |
| 6 | + To accept an account transfer for an image, send a POST request to |
| 7 | + `/v2/images/$IMAGE_ID/account_transfer/accept`. |
| 8 | +
|
| 9 | + Only snapshot images may be transferred by this endpoint to another account. |
| 10 | + |
| 11 | + An image account transfer always has exactly one recipient, specified in the request body. |
| 12 | + The recipient can be one of the following: |
| 13 | +
|
| 14 | + * A DigitalOcean account, denoted by `recipient_email` in the request body. |
| 15 | + The recipient will receive an email with instructions to accept the transfer. |
| 16 | + Once the recipient accepts the transfer, the image will be moved to their |
| 17 | + account. |
| 18 | +
|
| 19 | + * A DigitalOcean team, denoted by `recipient_uuid` in the request body. If the |
| 20 | + user has sufficient permissions in the recipient team, the transfer will be |
| 21 | + automatically accepted and the image will be moved to the recipient team's |
| 22 | + account. Otherwise, the transfer will be pending until a user with sufficient |
| 23 | + permissions in the recipient team accepts the transfer. |
| 24 | +tags: |
| 25 | + - Images |
| 26 | + |
| 27 | +parameters: |
| 28 | + - $ref: 'parameters.yml#/image_id' |
| 29 | + |
| 30 | +requestBody: |
| 31 | + required: true |
| 32 | + |
| 33 | + content: |
| 34 | + application/json: |
| 35 | + schema: |
| 36 | + $ref: 'models/images_post_account_transfer_accept.yml' |
| 37 | + |
| 38 | +responses: |
| 39 | + '201': |
| 40 | + $ref: '../../shared/responses/no_content.yml' |
| 41 | + |
| 42 | + '400': |
| 43 | + $ref: '../../shared/responses/bad_request.yml' |
| 44 | + |
| 45 | + '401': |
| 46 | + $ref: '../../shared/responses/unauthorized.yml' |
| 47 | + |
| 48 | + '404': |
| 49 | + $ref: '../../shared/responses/not_found.yml' |
| 50 | + |
| 51 | + '429': |
| 52 | + $ref: '../../shared/responses/too_many_requests.yml' |
| 53 | + |
| 54 | + '500': |
| 55 | + $ref: '../../shared/responses/server_error.yml' |
| 56 | + |
| 57 | + default: |
| 58 | + $ref: '../../shared/responses/unexpected_error.yml' |
| 59 | + |
| 60 | +x-codeSamples: |
| 61 | + - $ref: 'examples/curl/images_post_account_transfer_accept.yml' |
| 62 | + |
| 63 | +security: |
| 64 | + - bearer_auth: |
| 65 | + - 'image:create' |
0 commit comments