Description
You have to call this method when you want to cancel an unsubscription request made by user in DruID Identity (CIAM).
You will need a user logged with access token. You can not perform this operation with no logged user
Please, read first: https://dru-id.com/developers/apis/oauth-2/ to learn about Oauth2 protocol and the meaning of each token.
Endpoint URL:
DELETE https://{{graph_host}}/activityid/v1/user/unsubscribe
Request parameters
| Parameter | Description | Type | Required |
|---|---|---|---|
| Authorization | “Bearer access_token” Literal text Bearer followed by access_token that is the user access token obtained from /oauth2/token endpoint | string | yes |
| Content-Type | The type of content that will be used for requests to be JSON | string | yes |
| Accept | The type of content that will be used for responses to be JSON | string | yes |
| From | Name of the entrypoint | string | yes |
| Accept-Language | Language for this request | Locale | no |
Query string parameters
| Parameter | Description | Type | Required | Default value |
|---|
Request Example
| Parameter | Description | Type | Required | Value |
|---|---|---|---|---|
| actor.id | Object ID of user who request action | string | yes | object_id |
| actor.objectType | Type of the object which represents the actor. | string | yes | ‘user’ |
| verb | Verb used for action | string | yes | ‘retract’ |
| source.id | Type of device doing the activity | string | yes | ‘unknown’ | ‘pc’ | ‘mobile’ | ‘tablet’ | ‘game_console’ | ‘itv’ |
| source.objectType | Type of source | string | yes | ‘device’ |
Response examples
Response: Request success (Accepted)
Response codes
| Code | Type | Description |
|---|---|---|
| 400 | Error | Bad Request: The request could not be understood by the server due to malformed syntax |
| 401 | Error | Unauthorized: authentication is required and has failed or has not yet been provided (token is invalid, etc) |
| 428 | Error | Precondition required: User need to configure MFA or needs to send a MFA code. Check the MFA API |
| 500 | Error | Internal Server Error: The server encountered an unexpected condition which prevented it from fulfilling the request |
| 504 | Error | Gateway TimeoutService can not contact with oauth server to do some internal operations |
| 202 | Success | User unsubcription has been cancelled |
