|
| 1 | +--- |
| 2 | +title: Travel Request v4 - Participant Resources |
| 3 | +layout: reference |
| 4 | +--- |
| 5 | + |
| 6 | +{% include prerelease.html %} |
| 7 | + |
| 8 | +# Travel Request v4 - Participant Resources |
| 9 | + |
| 10 | +Manage participants and child requests attached to a Budget Request. |
| 11 | + |
| 12 | +## <a name="get-request-participants"></a>Get Participants for a Budget Request |
| 13 | + |
| 14 | +This endpoint will enable you to retrieve the list of participants of a Budget Request, as well as the child Requests for each of the participants. |
| 15 | + |
| 16 | +### Scopes |
| 17 | + |
| 18 | +`travelrequest.write` - Refer to [Scope Usage](./v4.get-started.html#scope-usage) for full details. |
| 19 | + |
| 20 | +### HTTP Request |
| 21 | + |
| 22 | +##### URI Template |
| 23 | + |
| 24 | +``` |
| 25 | +GET {datacenter}/travelrequest/v4/requests/{requestUuid}/participants |
| 26 | +``` |
| 27 | + |
| 28 | +#### Parameters |
| 29 | + |
| 30 | +Name|Type|Format|Description |
| 31 | +---|---|---|--- |
| 32 | +`requestUuid`|`string`|[RFC 4122]|**Required** The unique identifier of the Request. |
| 33 | +`userId`|`string`|-|The unique identifier of the user getting the participants list. If empty when using a Company token the default system user will be assumed to perform the action. |
| 34 | + |
| 35 | +#### Headers |
| 36 | + |
| 37 | +`concur-correlationid` is a specific custom header used for technical support in the form of a [RFC 4122 A Universally Unique IDentifier (UUID) URN Namespace](https://tools.ietf.org/html/rfc4122). |
| 38 | + |
| 39 | +#### Payload |
| 40 | + |
| 41 | +None. |
| 42 | + |
| 43 | +### HTTP Response |
| 44 | + |
| 45 | +#### HTTP Status Codes |
| 46 | + |
| 47 | +To learn more about response HTTP status codes for this API see [Travel Request v4 - HTTP Status Codes](./v4.response-codes.html). |
| 48 | + |
| 49 | +#### Payload |
| 50 | + |
| 51 | +[ParentRequestParticipant](./v4.endpoints.schemas.html#schema-parentrequestparticipant) |
| 52 | + |
| 53 | +### Example - One participant with two Child Requests and One Participant without Child Request |
| 54 | + |
| 55 | +#### HTTP Request |
| 56 | + |
| 57 | +```shell |
| 58 | +GET https://us.api.concursolutions.com/travelrequest/v4/requests/224AF3CDCC2A5244A37C72FA5770C6F2/participants |
| 59 | +Accept: application/json |
| 60 | +Authorization: Bearer {token} |
| 61 | +Concur-CorrelationId: 5512c7be-3fab-4d65-ae69-8a74a04a0c7f |
| 62 | +``` |
| 63 | + |
| 64 | +#### HTTP Response |
| 65 | + |
| 66 | +```shell |
| 67 | +200 OK |
| 68 | +``` |
| 69 | + |
| 70 | +```json |
| 71 | +[ |
| 72 | + { |
| 73 | + "participant": { |
| 74 | + "id": "60dea1fd-489f-48b9-925f-0d62a5b48175" |
| 75 | + }, |
| 76 | + "requests": [ |
| 77 | + { |
| 78 | + "href": "https://us.api.concursolutions.com/travelrequest/v4/requests/A1B2C3D4E5F6A1B2C3D4E5F6A1B2C3D4", |
| 79 | + "id": "A1B2C3D4E5F6A1B2C3D4E5F6A1B2C3D4", |
| 80 | + "template": "https://us.api.concursolutions.com/travelrequest/v4/requests/{id}" |
| 81 | + }, |
| 82 | + { |
| 83 | + "href": "https://us.api.concursolutions.com/travelrequest/v4/requests/B2C3D4E5F6A1B2C3D4E5F6A1B2C3D4E5", |
| 84 | + "id": "B2C3D4E5F6A1B2C3D4E5F6A1B2C3D4E5", |
| 85 | + "template": "https://us.api.concursolutions.com/travelrequest/v4/requests/{id}" |
| 86 | + }, |
| 87 | + ] |
| 88 | + }, |
| 89 | + { |
| 90 | + "participant": { |
| 91 | + "id": "72efb2ae-5a0e-59ca-b037-1e73b6c59286" |
| 92 | + } |
| 93 | + } |
| 94 | +] |
| 95 | +``` |
| 96 | + |
| 97 | +## <a name="patch-request-participants"></a>Manage Participants of a Budget Request |
| 98 | + |
| 99 | +This endpoint will enable to manage participants (add or remove them) from a Budget Request. |
| 100 | + |
| 101 | +### Scopes |
| 102 | + |
| 103 | +`travelrequest.write` - Refer to [Scope Usage](./v4.get-started.html#scope-usage) for full details. |
| 104 | + |
| 105 | +### HTTP Request |
| 106 | + |
| 107 | +##### URI Template |
| 108 | + |
| 109 | +``` |
| 110 | +PATCH {datacenter}/travelrequest/v4/requests/{requestUuid}/participants |
| 111 | +``` |
| 112 | + |
| 113 | +#### Parameters |
| 114 | + |
| 115 | +Name|Type|Format|Description |
| 116 | +---|---|---|--- |
| 117 | +`requestUuid`|`string`|[RFC 4122]|**Required** The unique identifier of the Request. |
| 118 | +`userId`|`string`|-|The unique identifier of the user updating the participants list. **Required** when connecting with a Company token. If empty, a 400 `missingRequiredParam` error. |
| 119 | + |
| 120 | +#### Headers |
| 121 | + |
| 122 | +`concur-correlationid` is a specific custom header used for technical support in the form of a [RFC 4122 A Universally Unique IDentifier (UUID) URN Namespace](https://tools.ietf.org/html/rfc4122). |
| 123 | + |
| 124 | +#### Payload |
| 125 | + |
| 126 | +[Request Participants For Patch](./v4.endpoints.schemas.html#schema-requestparticipantsforpatch) |
| 127 | + |
| 128 | +### HTTP Response |
| 129 | + |
| 130 | +#### HTTP Status Codes |
| 131 | + |
| 132 | +To learn more about response HTTP status codes for this API see [Travel Request v4 - HTTP Status Codes](./v4.response-codes.html). |
| 133 | + |
| 134 | +#### Payload |
| 135 | + |
| 136 | +None. |
| 137 | + |
| 138 | +### Example - adding and removing a participant to a Budget Request |
| 139 | + |
| 140 | +#### HTTP Request |
| 141 | + |
| 142 | +```shell |
| 143 | +PATCH https://us.api.concursolutions.com/travelrequest/v4/requests/224AF3CDCC2A5244A37C72FA5770C6F2/participants |
| 144 | +Content-Type: application/merge-patch+json |
| 145 | +Accept: application/json |
| 146 | +Authorization: Bearer {token} |
| 147 | +Concur-CorrelationId: 5512c7be-3fab-4d65-ae69-8a74a04a0c7f |
| 148 | +``` |
| 149 | + |
| 150 | +```json |
| 151 | +{ |
| 152 | + "value": [ |
| 153 | + { |
| 154 | + "id": "8422A66-A9B0-1424-5802-0D9BCD4351D3" |
| 155 | + }, |
| 156 | + { |
| 157 | + "id": "9C33FBA0-ACB7-4F85-83BD-FC0DF3A78522", |
| 158 | + "@deleted": true |
| 159 | + } |
| 160 | + ] |
| 161 | +} |
| 162 | +``` |
| 163 | + |
| 164 | +#### HTTP Response |
| 165 | + |
| 166 | +```shell |
| 167 | +204 No Content |
| 168 | +``` |
0 commit comments