Memento Payments
Search…
⌃K

Contacts

The contact object

A contact can be either a reference to a User or an independent object with a person's name.
Attribute
Type
Description
id
uuid
The unique identifier for the announcement.
user_id
uuid
The User object representing the contact, if the contact is a registered user.
first_name
string
The first name of the contact.
last_name
string
The last name of the contact.
full_name
string
The full name of the contact.
country
string
Two letter ISO 3166-1 alpha-2 country code representing the country the contact is located in.
user
User
An optional user.
created_at
time
The time when the contact was created.
updated_at
time
The time when the contact was updated.

Example

{
"id": "d6edcdba-f3f1-4249-96bc-bb977fde27fb",
"user_id": "fbc521f9-aea8-4da7-840a-1e13ec924b28",
"first_name": "John",
"last_name": "Dough",
"full_name": "John Dough",
"country": "UK",
"user": {
"id": "add5c52a-0c57-4d5c-7525-db14566f2f1a",
"first_name": "John",
"last_name": "Dough",
"full_name": "John Dough",
"username": "jondough",
"country": "UK",
"timezone": "Europe/London",
"timezone_utc_offset": 0,
"verified": true,
"official": true,
"image": {
"id": "75cc21be-fe47-4702-74bc-07b84beed5fb",
"url": "https://{imagehost}/ui/users/ad2636c3-82fe-4c45-af2d-d6324b2e618f.jpg",
"full_screen_url": "https://{imagehost}/full/users/ad2636c3-82fe-4c45-af2d-d6324b2e618f.jpg",
"thumbnail_url": "https://{imagehost}/thumbnail/users/ad2636c3-82fe-4c45-af2d-d6324b2e618f.jpg",
"created_at": "2017-09-04T12:26:43.403883Z",
"updated_at": "2017-09-04T12:26:43.403883Z"
},
},
"created_at": "2017-09-04T12:25:52.43349Z",
"updated_at": "2017-09-04T12:25:52.43349Z"
}

Get a list of contacts

Get a list of all of the user's contacts.
Request
Response
GET /v1/contacts
200 OK
Returns a list of contact objects.

Get a contact

Get a single contact by ID.
Request
Response
GET /v1/contacts/{id}
200 OK
Returns a contact object.

Create a contact with User ID

Create a new contact by providing a user ID.
Request
Response
POST /v1/contacts
Attribute
Type
Description
user_id
uuid
The unique identifier of the user. required
{
"user_id": "d6edcdba-f3f1-4249-96bc-bb977fde27fb"
}
201 Created
Returns a contact object.

Create a contact without a user

Request
Response
POST /v1/contacts
Attribute
Type
Description
first_name
string
The first name of the contact. required
last_name
string
The last name of the contact.
phone
string
The user's phone number.
{
"first_name": "Jane",
"last_name": "Dough",
"phone": "+1 1231231234"
}
201 Created
Returns a contact object.

Delete a contact

Delete an existing contact.
Request
Response
DELETE /v1/contacts/{id}
200 OK