Contact Identifiers
Mostly, Contacts are identified by their email address. However, Contact Identifiers can also be used to retrieve a Contact's information. Most current Contact Identifiers are Loyalty Cards, which have been around since the start of Piggy. However, if needed, virtually anything can be used as a Contact Identifier, provided they use a unique value (within the Account).
Find Contact Identifier
Finds the Contact Identifier. Returns contact
as null if not yet linked to a Contact.
https://api.piggy.eu/api//contact-identifiers/find?contact_identifier_value={{contact_identifier_value}}
Bearer {{ access_token | api_key }}
application/json
contact_identifier_value
string
REQUIRED
1
2
3
4
5
6
7
8
9
10
11
12
{
"data": {
"name": "Loyalty Card",
"value": "ABCDE12356-90",
"active": true,
"contact": {
"uuid": "123abc-def789-qwerty-34567",
"email": "john@doe.com
}
},
"meta": []
}
Code
Message
1003
60003
60004
Create Contact Identifier
Creates a Contact Identifier. You can link it directly to a Contact when you send a contact_uuid
along.
https://api.piggy.eu/api//contact-identifiers
Bearer {{ access_token | api_key }}
application/json
Body
contact_identifier_value
string
REQUIRED
contact_uuid
string
OPTIONAL
contact_identifier_name
string
OPTIONAL
1
2
3
4
5
6
7
8
9
10
11
12
{
"data": {
"name": "Loyalty Card",
"value": "ABCDE12356-90",
"active": true,
"contact": {
"uuid": "123abc-def789-qwerty-34567",
"email": "john@doe.com
}
},
"meta": []
}
Code
Message
1003
55031
60006
Link Contact Identifier
Links an existing, unlinked Contact Identifier to an existing Contact.
https://api.piggy.eu/api//contact-identifiers/link
Bearer {{ access_token | api_key }}
application/json
Body
contact_identifier_value
string
REQUIRED
contact_uuid
string
REQUIRED
1
2
3
4
5
6
7
8
9
10
11
12
{
"data": {
"name": "Loyalty Card",
"value": "ABCDE12356-90",
"active": true,
"contact": {
"uuid": "123abc-def789-qwerty-34567",
"email": "john@doe.com
}
},
"meta": []
}
Code
Message
1003
60003
60004
55031
60014
Unlink Contact Identifier
Removes a linked Contact from a Contact Identifier.
https://api.piggy.eu/api//contact-identifiers/unlink
Bearer {{ access_token | api_key }}
application/json
Body
contact_identifier_value
string
REQUIRED
1
2
3
4
5
6
7
8
9
{
"data": {
"name": "Loyalty Card",
"value": "ABCDE12356-90",
"active": true,
"contact": null
},
"meta": []
}
Code
Message
1003
60003
60004
Update Contact Identifier
Updates a Contact Identifier. Note: only the identifier's name
and active
properties can be updated. The value cannot be updated.
https://api.piggy.eu/api//contact-identifiers
Bearer {{ access_token | api_key }}
application/json
Body
contact_identifier_value
string
REQUIRED
contact_identifier_name
string
OPTIONAL
contact_identifier_active
boolean
OPTIONAL
1
2
3
4
5
6
7
8
9
10
11
12
{
"data": {
"name": "Loyalty Card",
"value": "ABCDE12356-90",
"active": true,
"contact": {
"uuid": "123abc-def789-qwerty-34567",
"email": "john@doe.com
}
},
"meta": []
}
Code
Message
1003
55031
60006
Delete Contact Identifier
Deletes an Contact Identifier.
https://api.piggy.eu/api//contact-identifiers
Bearer {{ access_token | api_key }}
application/json
Body
contact_identifier_value
string
REQUIRED
Code
Message
1003
60003