Description

You should call this method after you have made a social login in DRUID and you are required to accept the Terms & Conditions. If you need to know which T&Cs are to be accepted, you can make a call to consult the information about the entrypoint, its fields and consents to be accepted. After that, use the access token of the social login and make the call.

Please, read first: https://dru-id.com/developers/apis/oauth-2/ to learn about Oauth2 protocol and the meaning of each token.

Endpoint URL:

 POST https://{your-endpoint-domain.com}/activityid/v1/assertions/social/accept

Request parameters

ParameterDescriptionTypeRequired
AuthorizationBearer ${access_token}
Literal text Bearer followed by access_token that is the token for current logged user obtained from social login endpoint
stringyes
Content-TypeThe type of content that will be used for requests to be JSONstringyes
AcceptThe type of content that will be used for responses to be JSONstringyes
FromName of the entry pointstringyes
Accept-LanguageLanguage of this requestLocaleno

Request example

ParameterDescriptionTypeRequiredValue
actor.idapp_id of the application you are using to log userstringyesapp id
actor.objectTypeType of the object which represents the actorstringyes‘application’
verbVerb used for the loginstringyes‘accept’
object.objectTypeObjectType represents the userstringyes‘user’
object.idsUser identifiers. More info about user identifiers User Infostructyesstruct
object.assertionsStruct that defines legalities manage by the user. More info about user assertions User Infostructyesstruct
source.idType of device doing the activitystringyes‘unknown’ | ‘pc’ | ‘mobile’ | ‘tablet’ | ‘game_console’ | ‘itv’
source.objectTypeType of sourcestringyes‘device’

Response examples

Response: terms accepted successfully

Response KO: Terms & Conditions not approved by the user

ParameterDescriptionType
contentData receive with the responsestruct
content.assertionsList of assertions not completed by the userarray
content.assertions.objectTypeObjectType represents the assertions list‘assertions’
content.assertions.itemsList of assertions. More info about assertions at User Infoarray
result.statusHTTP status codeint
errors.messageErrors descriptionstring

Response codes

CodeTypeDescription
400ErrorBad Request: The request could not be understood by the server due to malformed syntax
401ErrorUnauthorized: authentication is required and has failed or has not yet been provided (token is invalid, etc)
403ErrorForbidden: user id or password are invalid
451ErrorUnavailable For Legal Reasons: user must accept new terms and conditions
500ErrorInternal Server Error: The server encountered an unexpected condition which prevented it from fulfilling the request
504ErrorGateway TimeoutService can not contact with oauth server to do some internal operations
200SucessUser accept t&c conditions successfully.