Users
Get current user informations
This endpoint retrieves all basic informations associated to current user.
HTTP Request
GET /v1/users
Example
- Request
- Response
$ curl --request GET --url 'https://app.winesitting.com/v1/users' \
--header 'AccessKey: YourAccessKey' \
--header 'SecretKey: YourSecretKey' \
--header 'content-type: application/json'
{
"firstname": "Test",
"lastname": "Test",
"company": null,
"gender": "m",
"birthday": "2009-03-31T00:00:00+00:00",
"email_billing": "email@domain.com",
"email_stock": "email@domain.com",
"minimum_stock": null,
"email_preference": null,
"cellar_preference": [
"potential"
]
}
Update current user informations
This endpoint lets you update users informations.
HTTP Request
PUT /v1/users
Address parameters
Name | Required | Type | Details |
---|---|---|---|
firstname | optional | string | |
lastname | optional | string | |
company | optional | string | |
gender | optional | string | m or f |
birthday | optional | string | |
optional | string | ||
password | optional | string | |
email_preference | optional | array | The array of email types you want to receive |
cellar_preference | optional | array | The array of columns you want to hide your web cellar |
email_billing | optional | string | This email will be in CC of invoice notifications |
email_stock | optional | string | This email will be in CC of stock notifications |
minimum_stock | optional | integer | The stock below which you want to be alerted (by reference) |
Example
- Request
- Response
$ curl --request PUT --url 'https://app.winesitting.com/v1/users' \
--header 'AccessKey: YourAccessKey' \
--header 'SecretKey: YourSecretKey' \
--header 'content-type: application/json' \
--data '
{
"firstname": "Test1",
"email_preference" : [
"invoiceValidated",
"getOutRequestNew",
"getOutRequestReady",
"getOutRequestShipped",
"bottleReceived"
],
"cellar_preference": [
"potential"
]
},
'
{
"firstname": "Test",
"lastname": "Test",
"company": null,
"gender": "m",
"birthday": "2009-03-31T00:00:00+00:00",
"email_billing": "email@domain.com",
"email_stock": "email@domain.com",
"minimum_stock": null,
"email_preference": [
"invoiceValidated",
"getOutRequestNew",
"getOutRequestReady",
"getOutRequestShipped",
"bottleReceived"
],
"cellar_preference": [
"potential"
]
}