Get current customer account
curl --request GET \
--url https://b.anny.co/api/v1/customer-accountimport requests
url = "https://b.anny.co/api/v1/customer-account"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://b.anny.co/api/v1/customer-account', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://b.anny.co/api/v1/customer-account",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://b.anny.co/api/v1/customer-account"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://b.anny.co/api/v1/customer-account")
.asString();require 'uri'
require 'net/http'
url = URI("https://b.anny.co/api/v1/customer-account")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"data": {
"type": "customer-accounts",
"id": "5fb1965e-66b4-4676-8b04-fbf39d57cc64",
"attributes": {
"title": null,
"sex": 0,
"birth_date": null,
"given_name": "Florian",
"family_name": "Schmitt",
"email": "florian.schmitt@anny.co",
"company": null,
"mobile": "+491741234656",
"mobile_verified_at": null,
"phone": null,
"locale": "en",
"timezone": "UTC",
"activated_at": null,
"created_at": "2021-09-24T09:37:35.000000Z",
"updated_at": "2021-09-24T09:38:38.000000Z"
},
"links": {
"self": "https://b.anny.co/api/v1/customer-accounts/5fb1965e-66b4-4676-8b04-fbf39d57cc64"
}
},
"value": {
"data": {
"type": "customer-accounts",
"id": "19ef1b4f-9d06-4843-95aa-90f9a5ac22d5",
"attributes": {
"title": "Herr",
"sex": 0,
"birth_date": "1997-02-18",
"given_name": "Lucian",
"family_name": "Holtwiesche",
"email": "lucian@anny.co",
"company": "anny",
"mobile": "+491742095775",
"mobile_verified_at": null,
"phone": null,
"locale": "de",
"timezone": "Europe/Berlin",
"activated_at": null,
"has_organization": true,
"created_at": "2021-11-07T15:41:40.000000Z",
"updated_at": "2023-03-28T22:24:53.000000Z"
},
"relationships": {
"primary_address": {
"data": {
"type": "addresses",
"id": "191"
}
},
"liked_favorites": {
"data": [
{
"type": "favorites",
"id": "2a8e3e7e-f774-4192-9bdd-85625d0b86e7"
},
{
"type": "favorites",
"id": "4c1aee78-6ec5-4197-991b-f00dfcc8198d"
},
{
"type": "favorites",
"id": "81c3eda6-48b4-4406-b604-0bdb8e59b4f6"
},
{
"type": "favorites",
"id": "979a84a2-2806-4330-8129-04ad5402d056"
},
{
"type": "favorites",
"id": "8c402100-875c-4b3f-8481-1956db0f815c"
}
]
},
"communities": {
"data": [
{
"type": "communities",
"id": "abteilung-sales-duzlS6uj"
},
{
"type": "communities",
"id": "test-afeah4gr"
},
{
"type": "communities",
"id": "abteilung-a-MA3ihySi"
},
{
"type": "communities",
"id": "test-service-aHVLzVV9"
},
{
"type": "communities",
"id": "miglieder-woHq4gwS"
}
]
},
"profile_image": {
"data": null
}
},
"links": {
"self": "https://bookings-api-alt.test/api/v1/customer-accounts/19ef1b4f-9d06-4843-95aa-90f9a5ac22d5"
},
"meta": {
"has_subscriptions": true
}
},
"included": [
{
"type": "addresses",
"id": "191",
"attributes": {
"name": null,
"street_address": "Test Str. 5",
"zip_code": "52066",
"city": "Aachen",
"country_code": "DE",
"latitude": null,
"longitude": null
},
"meta": {
"address_line": "Test Str. 5, 52066 Aachen, DE"
}
},
{
"type": "favorites",
"id": "2a8e3e7e-f774-4192-9bdd-85625d0b86e7",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "1",
"model_type": "resources",
"created_at": "2022-04-24T15:10:05+00:00",
"order_index": 0
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/2a8e3e7e-f774-4192-9bdd-85625d0b86e7/model"
}
}
}
},
{
"type": "favorites",
"id": "4c1aee78-6ec5-4197-991b-f00dfcc8198d",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "22",
"model_type": "resources",
"created_at": "2022-04-29T21:22:52+00:00",
"order_index": 4
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/4c1aee78-6ec5-4197-991b-f00dfcc8198d/model"
}
}
}
},
{
"type": "favorites",
"id": "81c3eda6-48b4-4406-b604-0bdb8e59b4f6",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "41",
"model_type": "resources",
"created_at": "2022-05-05T14:47:21+00:00",
"order_index": 2
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/81c3eda6-48b4-4406-b604-0bdb8e59b4f6/model"
}
}
}
},
{
"type": "favorites",
"id": "979a84a2-2806-4330-8129-04ad5402d056",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "5",
"model_type": "resources",
"created_at": "2022-05-05T21:36:08+00:00",
"order_index": 3
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/979a84a2-2806-4330-8129-04ad5402d056/model"
}
}
}
},
{
"type": "favorites",
"id": "8c402100-875c-4b3f-8481-1956db0f815c",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "42",
"model_type": "resources",
"created_at": "2022-05-08T19:15:18+00:00",
"order_index": 1
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/8c402100-875c-4b3f-8481-1956db0f815c/model"
}
}
}
},
{
"type": "communities",
"id": "abteilung-sales-duzlS6uj",
"attributes": {
"slug": "abteilung-sales-duzlS6uj",
"name": "Abteilung Sales",
"color": "#8e5dca",
"icon": "money-bill",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
},
{
"type": "communities",
"id": "test-afeah4gr",
"attributes": {
"slug": "test-afeah4gr",
"name": "Test",
"color": "var(--secondary-color)",
"icon": "building",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
},
{
"type": "communities",
"id": "abteilung-a-MA3ihySi",
"attributes": {
"slug": "abteilung-a-MA3ihySi",
"name": "Abteilung A",
"color": "#ed8047",
"icon": "money-bill",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
},
{
"type": "communities",
"id": "test-service-aHVLzVV9",
"attributes": {
"slug": "test-service-aHVLzVV9",
"name": "Test Service",
"color": "var(--secondary-color)",
"icon": "building",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
},
{
"type": "communities",
"id": "miglieder-woHq4gwS",
"attributes": {
"slug": "miglieder-woHq4gwS",
"name": "Miglieder",
"color": "var(--secondary-color)",
"icon": "address-book",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
}
]
}
}Account
Get customer account information
Fetch the logged in customer identified by Bearer Token.
GET
/
api
/
v1
/
customer-account
Get current customer account
curl --request GET \
--url https://b.anny.co/api/v1/customer-accountimport requests
url = "https://b.anny.co/api/v1/customer-account"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://b.anny.co/api/v1/customer-account', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://b.anny.co/api/v1/customer-account",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://b.anny.co/api/v1/customer-account"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://b.anny.co/api/v1/customer-account")
.asString();require 'uri'
require 'net/http'
url = URI("https://b.anny.co/api/v1/customer-account")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"data": {
"type": "customer-accounts",
"id": "5fb1965e-66b4-4676-8b04-fbf39d57cc64",
"attributes": {
"title": null,
"sex": 0,
"birth_date": null,
"given_name": "Florian",
"family_name": "Schmitt",
"email": "florian.schmitt@anny.co",
"company": null,
"mobile": "+491741234656",
"mobile_verified_at": null,
"phone": null,
"locale": "en",
"timezone": "UTC",
"activated_at": null,
"created_at": "2021-09-24T09:37:35.000000Z",
"updated_at": "2021-09-24T09:38:38.000000Z"
},
"links": {
"self": "https://b.anny.co/api/v1/customer-accounts/5fb1965e-66b4-4676-8b04-fbf39d57cc64"
}
},
"value": {
"data": {
"type": "customer-accounts",
"id": "19ef1b4f-9d06-4843-95aa-90f9a5ac22d5",
"attributes": {
"title": "Herr",
"sex": 0,
"birth_date": "1997-02-18",
"given_name": "Lucian",
"family_name": "Holtwiesche",
"email": "lucian@anny.co",
"company": "anny",
"mobile": "+491742095775",
"mobile_verified_at": null,
"phone": null,
"locale": "de",
"timezone": "Europe/Berlin",
"activated_at": null,
"has_organization": true,
"created_at": "2021-11-07T15:41:40.000000Z",
"updated_at": "2023-03-28T22:24:53.000000Z"
},
"relationships": {
"primary_address": {
"data": {
"type": "addresses",
"id": "191"
}
},
"liked_favorites": {
"data": [
{
"type": "favorites",
"id": "2a8e3e7e-f774-4192-9bdd-85625d0b86e7"
},
{
"type": "favorites",
"id": "4c1aee78-6ec5-4197-991b-f00dfcc8198d"
},
{
"type": "favorites",
"id": "81c3eda6-48b4-4406-b604-0bdb8e59b4f6"
},
{
"type": "favorites",
"id": "979a84a2-2806-4330-8129-04ad5402d056"
},
{
"type": "favorites",
"id": "8c402100-875c-4b3f-8481-1956db0f815c"
}
]
},
"communities": {
"data": [
{
"type": "communities",
"id": "abteilung-sales-duzlS6uj"
},
{
"type": "communities",
"id": "test-afeah4gr"
},
{
"type": "communities",
"id": "abteilung-a-MA3ihySi"
},
{
"type": "communities",
"id": "test-service-aHVLzVV9"
},
{
"type": "communities",
"id": "miglieder-woHq4gwS"
}
]
},
"profile_image": {
"data": null
}
},
"links": {
"self": "https://bookings-api-alt.test/api/v1/customer-accounts/19ef1b4f-9d06-4843-95aa-90f9a5ac22d5"
},
"meta": {
"has_subscriptions": true
}
},
"included": [
{
"type": "addresses",
"id": "191",
"attributes": {
"name": null,
"street_address": "Test Str. 5",
"zip_code": "52066",
"city": "Aachen",
"country_code": "DE",
"latitude": null,
"longitude": null
},
"meta": {
"address_line": "Test Str. 5, 52066 Aachen, DE"
}
},
{
"type": "favorites",
"id": "2a8e3e7e-f774-4192-9bdd-85625d0b86e7",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "1",
"model_type": "resources",
"created_at": "2022-04-24T15:10:05+00:00",
"order_index": 0
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/2a8e3e7e-f774-4192-9bdd-85625d0b86e7/model"
}
}
}
},
{
"type": "favorites",
"id": "4c1aee78-6ec5-4197-991b-f00dfcc8198d",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "22",
"model_type": "resources",
"created_at": "2022-04-29T21:22:52+00:00",
"order_index": 4
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/4c1aee78-6ec5-4197-991b-f00dfcc8198d/model"
}
}
}
},
{
"type": "favorites",
"id": "81c3eda6-48b4-4406-b604-0bdb8e59b4f6",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "41",
"model_type": "resources",
"created_at": "2022-05-05T14:47:21+00:00",
"order_index": 2
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/81c3eda6-48b4-4406-b604-0bdb8e59b4f6/model"
}
}
}
},
{
"type": "favorites",
"id": "979a84a2-2806-4330-8129-04ad5402d056",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "5",
"model_type": "resources",
"created_at": "2022-05-05T21:36:08+00:00",
"order_index": 3
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/979a84a2-2806-4330-8129-04ad5402d056/model"
}
}
}
},
{
"type": "favorites",
"id": "8c402100-875c-4b3f-8481-1956db0f815c",
"attributes": {
"liked": true,
"recent": false,
"viewed": false,
"model_id": "42",
"model_type": "resources",
"created_at": "2022-05-08T19:15:18+00:00",
"order_index": 1
},
"relationships": {
"model": {
"links": {
"related": "https://bookings-api-alt.test/api/v1/favorites/8c402100-875c-4b3f-8481-1956db0f815c/model"
}
}
}
},
{
"type": "communities",
"id": "abteilung-sales-duzlS6uj",
"attributes": {
"slug": "abteilung-sales-duzlS6uj",
"name": "Abteilung Sales",
"color": "#8e5dca",
"icon": "money-bill",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
},
{
"type": "communities",
"id": "test-afeah4gr",
"attributes": {
"slug": "test-afeah4gr",
"name": "Test",
"color": "var(--secondary-color)",
"icon": "building",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
},
{
"type": "communities",
"id": "abteilung-a-MA3ihySi",
"attributes": {
"slug": "abteilung-a-MA3ihySi",
"name": "Abteilung A",
"color": "#ed8047",
"icon": "money-bill",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
},
{
"type": "communities",
"id": "test-service-aHVLzVV9",
"attributes": {
"slug": "test-service-aHVLzVV9",
"name": "Test Service",
"color": "var(--secondary-color)",
"icon": "building",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
},
{
"type": "communities",
"id": "miglieder-woHq4gwS",
"attributes": {
"slug": "miglieder-woHq4gwS",
"name": "Miglieder",
"color": "var(--secondary-color)",
"icon": "address-book",
"welcome_text": null,
"is_private": true,
"allow_customer_requests": false,
"allow_organization_requests": false
},
"relationships": {
"logo_image": [],
"resources": [],
"resource_groups": [],
"services": [],
"organizations": []
},
"meta": []
}
]
}
}Abfrageparameter
Include relations. Newly relevant for business-account bootstrap: business_account, business_account.logo_image, business_account.primary_address.
Verfügbare Optionen:
addresses, primary_address, delivery_address, favorites, liked_favorites, communities, communities.external_links, profile_image, subscriptions, community_accounts, community_accounts.community, community_accounts.community.external_links, skills, account_skills.skill, booking_passes, booking_passes.booking_quota_grants, booking_passes.booking_quotas, connection_requests, connection_requests.requested_of, account_connections, account_connections.granted_to, inverse_connection_requests, inverse_connection_requests.requested_of, business_account, business_account.logo_image, business_account.primary_address Beispiel:
"business_account.logo_image,business_account.primary_address"
Antwort
OK
An end-user account (authenticated customer) with profile and community features.
Show child attributes
Show child attributes
⌘I