github.com/phrase/openapi@v0.0.0-20240514140800-49e8a106740e/paths/invitations/update.yaml (about) 1 --- 2 summary: Update an invitation 3 description: Update an existing invitation (must not be accepted yet). The <code>email</code> cannot be updated. Developers and translators need <code>project_ids</code> and <code>locale_ids</code> assigned to access them. Access token scope must include <code>team.manage</code>. 4 operationId: invitation/update 5 tags: 6 - Invitations 7 parameters: 8 - "$ref": "../../parameters.yaml#/X-PhraseApp-OTP" 9 - "$ref": "../../parameters.yaml#/account_id" 10 - "$ref": "../../parameters.yaml#/id" 11 responses: 12 '200': 13 description: OK 14 content: 15 application/json: 16 schema: 17 "$ref": "../../schemas/invitation.yaml#/invitation" 18 headers: 19 X-Rate-Limit-Limit: 20 "$ref": "../../headers.yaml#/X-Rate-Limit-Limit" 21 X-Rate-Limit-Remaining: 22 "$ref": "../../headers.yaml#/X-Rate-Limit-Remaining" 23 X-Rate-Limit-Reset: 24 "$ref": "../../headers.yaml#/X-Rate-Limit-Reset" 25 '400': 26 "$ref": "../../responses.yaml#/400" 27 '401': 28 "$ref": "../../responses.yaml#/401" 29 '403': 30 "$ref": "../../responses.yaml#/403" 31 '404': 32 "$ref": "../../responses.yaml#/404" 33 '429': 34 "$ref": "../../responses.yaml#/429" 35 x-code-samples: 36 - lang: Curl 37 source: |- 38 curl "https://api.phrase.com/v2/accounts/:account_id/invitations/:id" \ 39 -u USERNAME_OR_ACCESS_TOKEN \ 40 -X PATCH \ 41 -d '{"role":"Invitiation role","project_ids":"abcd1234abcd1234abcd1234,abcd1234abcd1234abcd1235","locale_ids":"abcd1234abcd1234abcd1234,abcd1234abcd1234abcd1235","space_ids":["abcd1234abcd1234abcd1234","abcd1234abcd1234abcd1235"],"team_ids":["abcd1234abcd1234abcd1234","abcd1234abcd1234abcd1235"],"default_locale_codes":["de","en"],"permissions":{"create_upload":true}}' \ 42 -H 'Content-Type: application/json' 43 - lang: CLI v2 44 source: |- 45 phrase invitations update \ 46 --account_id <account_id> \ 47 --id <id> \ 48 --data '{"role": "Invitiation role", "project_ids":"abcd1234abcd1234abcd1234,abcd1234abcd1234abcd1235", "locale_ids":"abcd1234abcd1234abcd1234,abcd1234abcd1234abcd1235", "space_ids":["abcd1234abcd1234abcd1234","abcd1234abcd1234abcd1235"],"team_ids":["abcd1234abcd1234abcd1234","abcd1234abcd1234abcd1235"], "default_locale_codes":["de","en"], "permissions":"{"create_upload"=>true}"}' \ 49 --access_token <token> 50 requestBody: 51 required: true 52 content: 53 application/json: 54 schema: 55 type: object 56 title: invitation/update/parameters 57 properties: 58 role: 59 description: Invitiation role, can be any of Manager, Developer, Translator 60 type: string 61 example: Invitiation role 62 project_ids: 63 description: List of project ids the invited user has access to 64 type: string 65 example: abcd1234abcd1234abcd1234,abcd1234abcd1234abcd1235 66 locale_ids: 67 description: List of locale ids the invited user has access to 68 type: string 69 example: abcd1234abcd1234abcd1234,abcd1234abcd1234abcd1235 70 space_ids: 71 description: List of spaces the user is assigned to. 72 type: array 73 items: 74 type: string 75 example: 76 - abcd1234abcd1234abcd1234 77 - abcd1234abcd1234abcd1235 78 team_ids: 79 description: List of teams the user is assigned to. 80 type: array 81 items: 82 type: string 83 example: 84 - abcd1234abcd1234abcd1234 85 - abcd1234abcd1234abcd1235 86 default_locale_codes: 87 description: List of default locales for the user. 88 type: array 89 items: 90 type: string 91 example: 92 - en 93 - de 94 permissions: 95 description: Additional permissions depending on invitation role. 96 type: object 97 additionalProperties: 98 type: string 99 example: 100 create_upload: true 101 x-cli-version: '2.5'