Consents
API operation of consents.
1
2
3
4
5
6
7
8
9
10
{
"msisdn" : "+123456789" ,
"client" : "youtube" ,
"purpose" : "dpv:Advertising" ,
"scopes" : [
"sim-swap" ,
"number-verification:verify" ,
"kyc-match:match"
]
}
Name
Type
Required
Description
msisdn
string
true
A public identifier addressing a telephone subscription. In mobile networks it corresponds to the MSISDN (Mobile Station International Subscriber Directory Number). In order to be globally unique it has to be formatted in international format, according to E.164 standard, prefixed with ‘+’.
client
string
true
Application that makes the request to consume the capacity.
purpose
string
true
Purpose for which the capability is to be consumed. Typically this will start with ‘dpv:’ followed by a value from the Data Privacy Vocabulary (DPV) ontology.
scopes
[string]
true
Capabilities to be consumed
Request example
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
curl -X POST https://opengateway.masstack.com/v1/orgs/{ org_id} /consents/validate \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
--data-raw "{
'msisdn': '+123456789',
'client': 'youtube',
'purpose': 'dpv:Advertising',
'scopes': [
'sim-swap',
'number-verification:verify',
'kyc-match:match'
]
}"
200 - JsonObject
Custom schema example
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
{
"purpose" : "dpv:FraudPreventionAndDetection" ,
"consents" : [
{
"id" : "SimSwap_FraudPreventionAndDetection_Agregador1App1" ,
"scope" : "sim-swap" ,
"status" : "ACCEPTED"
},
{
"id" : "NumberVerification_FraudPreventionAndDetection_Agregador2App2" ,
"scope" : "number-verification:verify" ,
"status" : "PENDING"
}
]
}
Parameters
Name
In
Type
Required
Description
org_id
path
string
true
‘none’
body
body
ConsentsCreateRequest
true
‘none’
1
2
3
4
5
{
"client" : "Vinted_aggr1" ,
"scope" : "sim-swap" ,
"purpose" : "dpv:Advertising"
}
Name
Type
Required
Description
client
string
true
Application that makes the request to consume the capacity.
scope
string
true
capabilities to be consumed
purpose
string
true
purpose for which the capability is to be consumed
Request example
1
2
3
4
5
6
7
8
9
10
curl -X POST https://opengateway.masstack.com/v1/orgs/{ org_id} /consents/create \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
--data-raw "{
'client': 'Vinted_aggr1',
'scope': 'sim-swap',
'purpose': 'dpv:Advertising'
}"