This API allows the user to provide grants on a customer to other customers. Refer Customer grants for information about what is a grant.
 For the successful execution of this API: 
| Method | URL | Description | 
|---|---|---|
| POST | /ws/v12/interaction/customer/grant | Provides grants on a customer to one or more customers. | 
Authentication is required. The client must be logged in to call this API. Each API request must contain X-egain-session request header returned by Login API.
All of the following are required:
The logged in user must have the following licenses:
| Name | Description | Allowed values | Default value | 
|---|---|---|---|
| X-egain-session | Session ID obtained from Login API response header | N/A | N/A | 
| Accept | Content type accepted by client. | application/xmlorapplication/json | N/A | 
| Content-Type | Media type sent by the client | application/xmlorapplication/json | N/A | 
| Accept-Language | Language locale accepted by client (used for locale specific fields in resource representation and in error responses) | Supported 'Accept-Language' header codes | default system language | 
The request body is mandatory. Request body can be in either XML or JSON format:
| Name | Description | 
|---|---|
| grantsOn.customer.id | Customer on whom the grants will be provided. | 
| grantsTo.customer.id | This will specify the customers to whom the grant will be provided. | 
None
None
None
| Name | Description | Possible values | 
|---|---|---|
| X-egain-session | Session ID of the current user session | N/A | 
| Content-Type | Media type of response body | application/xml or application/json | 
| Location | URL listing the grants for the customer providing the grants | interaction/customer/{ID}/grant | 
201 - Created 
 
400 - Bad Request
401 - Unauthorized
403 - Forbidden
406 - Not Acceptable
500 - Internal server error
Example 1 - Provide grants to a single customer 
 Example 2 - Provide grants to multiple customers