Update a specific resource
curl --request PATCH \
--url https://b.anny.co/api/v1/resources/{resource_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/vnd.api+json' \
--data '
{
"data": {
"id": "string",
"type": "resources",
"attributes": {
"slug": "string",
"name": "string",
"description": "string",
"plain_description": "string",
"availabilityMode": "string",
"continuous": true,
"color": "string",
"auto_accept_bookings": true,
"timezone": "string",
"quantity": 1,
"staggered_quantity": 1,
"has_children": true,
"available_from": "2019-08-24",
"available_to": "2019-08-24",
"created_at": "2019-08-24T14:15:22Z",
"seo": true,
"live": true,
"public_listing": true,
"display_public_description": true,
"hidden": true,
"settings": [
{
"checkIn.autoExpiry": true,
"checkIn.autoExpiresAfter": 0,
"checkIn.allowedAdvancePeriod": 1,
"checkIn.allowedDelayPeriod": 1
}
],
"preview_token": "string",
"email_info": "string"
},
"relationships": {
"parent": {
"id": "string"
},
"children": {
"id": "string"
},
"cover_image": {
"id": "string"
},
"gallery_images": {
"id": "string"
},
"organization": {
"id": "string"
},
"group": {
"id": "string"
},
"category": {
"id": "string"
},
"resource_properties": {
"id": "string"
},
"featured_properties": {
"id": "string"
},
"schedules": {
"id": "string"
},
"external_calendars": {
"id": "string"
},
"services": {
"id": "string"
},
"custom_address": {
"id": "string"
},
"location": {
"id": "string"
}
},
"meta": {
"is_available": true,
"booking_count": 0,
"number_available": true,
"minimal_service": "string",
"service_list": "string",
"services_count": 0,
"settings": "string",
"meta_settings": "string",
"zoom": "string",
"client_url": "http://example.com",
"preview_url": "http://example.com"
},
"links": {
"self": "http://example.com"
}
}
}
'import requests
url = "https://b.anny.co/api/v1/resources/{resource_id}"
payload = { "data": {
"id": "string",
"type": "resources",
"attributes": {
"slug": "string",
"name": "string",
"description": "string",
"plain_description": "string",
"availabilityMode": "string",
"continuous": True,
"color": "string",
"auto_accept_bookings": True,
"timezone": "string",
"quantity": 1,
"staggered_quantity": 1,
"has_children": True,
"available_from": "2019-08-24",
"available_to": "2019-08-24",
"created_at": "2019-08-24T14:15:22Z",
"seo": True,
"live": True,
"public_listing": True,
"display_public_description": True,
"hidden": True,
"settings": [
{
"checkIn.autoExpiry": True,
"checkIn.autoExpiresAfter": 0,
"checkIn.allowedAdvancePeriod": 1,
"checkIn.allowedDelayPeriod": 1
}
],
"preview_token": "string",
"email_info": "string"
},
"relationships": {
"parent": { "id": "string" },
"children": { "id": "string" },
"cover_image": { "id": "string" },
"gallery_images": { "id": "string" },
"organization": { "id": "string" },
"group": { "id": "string" },
"category": { "id": "string" },
"resource_properties": { "id": "string" },
"featured_properties": { "id": "string" },
"schedules": { "id": "string" },
"external_calendars": { "id": "string" },
"services": { "id": "string" },
"custom_address": { "id": "string" },
"location": { "id": "string" }
},
"meta": {
"is_available": True,
"booking_count": 0,
"number_available": True,
"minimal_service": "string",
"service_list": "string",
"services_count": 0,
"settings": "string",
"meta_settings": "string",
"zoom": "string",
"client_url": "http://example.com",
"preview_url": "http://example.com"
},
"links": { "self": "http://example.com" }
} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/vnd.api+json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/vnd.api+json'},
body: JSON.stringify({
data: {
id: 'string',
type: 'resources',
attributes: {
slug: 'string',
name: 'string',
description: 'string',
plain_description: 'string',
availabilityMode: 'string',
continuous: true,
color: 'string',
auto_accept_bookings: true,
timezone: 'string',
quantity: 1,
staggered_quantity: 1,
has_children: true,
available_from: '2019-08-24',
available_to: '2019-08-24',
created_at: '2019-08-24T14:15:22Z',
seo: true,
live: true,
public_listing: true,
display_public_description: true,
hidden: true,
settings: [
{
'checkIn.autoExpiry': true,
'checkIn.autoExpiresAfter': 0,
'checkIn.allowedAdvancePeriod': 1,
'checkIn.allowedDelayPeriod': 1
}
],
preview_token: 'string',
email_info: 'string'
},
relationships: {
parent: {id: 'string'},
children: {id: 'string'},
cover_image: {id: 'string'},
gallery_images: {id: 'string'},
organization: {id: 'string'},
group: {id: 'string'},
category: {id: 'string'},
resource_properties: {id: 'string'},
featured_properties: {id: 'string'},
schedules: {id: 'string'},
external_calendars: {id: 'string'},
services: {id: 'string'},
custom_address: {id: 'string'},
location: {id: 'string'}
},
meta: {
is_available: true,
booking_count: 0,
number_available: true,
minimal_service: 'string',
service_list: 'string',
services_count: 0,
settings: 'string',
meta_settings: 'string',
zoom: 'string',
client_url: 'http://example.com',
preview_url: 'http://example.com'
},
links: {self: 'http://example.com'}
}
})
};
fetch('https://b.anny.co/api/v1/resources/{resource_id}', 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/resources/{resource_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
'id' => 'string',
'type' => 'resources',
'attributes' => [
'slug' => 'string',
'name' => 'string',
'description' => 'string',
'plain_description' => 'string',
'availabilityMode' => 'string',
'continuous' => true,
'color' => 'string',
'auto_accept_bookings' => true,
'timezone' => 'string',
'quantity' => 1,
'staggered_quantity' => 1,
'has_children' => true,
'available_from' => '2019-08-24',
'available_to' => '2019-08-24',
'created_at' => '2019-08-24T14:15:22Z',
'seo' => true,
'live' => true,
'public_listing' => true,
'display_public_description' => true,
'hidden' => true,
'settings' => [
[
'checkIn.autoExpiry' => true,
'checkIn.autoExpiresAfter' => 0,
'checkIn.allowedAdvancePeriod' => 1,
'checkIn.allowedDelayPeriod' => 1
]
],
'preview_token' => 'string',
'email_info' => 'string'
],
'relationships' => [
'parent' => [
'id' => 'string'
],
'children' => [
'id' => 'string'
],
'cover_image' => [
'id' => 'string'
],
'gallery_images' => [
'id' => 'string'
],
'organization' => [
'id' => 'string'
],
'group' => [
'id' => 'string'
],
'category' => [
'id' => 'string'
],
'resource_properties' => [
'id' => 'string'
],
'featured_properties' => [
'id' => 'string'
],
'schedules' => [
'id' => 'string'
],
'external_calendars' => [
'id' => 'string'
],
'services' => [
'id' => 'string'
],
'custom_address' => [
'id' => 'string'
],
'location' => [
'id' => 'string'
]
],
'meta' => [
'is_available' => true,
'booking_count' => 0,
'number_available' => true,
'minimal_service' => 'string',
'service_list' => 'string',
'services_count' => 0,
'settings' => 'string',
'meta_settings' => 'string',
'zoom' => 'string',
'client_url' => 'http://example.com',
'preview_url' => 'http://example.com'
],
'links' => [
'self' => 'http://example.com'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/vnd.api+json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://b.anny.co/api/v1/resources/{resource_id}"
payload := strings.NewReader("{\n \"data\": {\n \"id\": \"string\",\n \"type\": \"resources\",\n \"attributes\": {\n \"slug\": \"string\",\n \"name\": \"string\",\n \"description\": \"string\",\n \"plain_description\": \"string\",\n \"availabilityMode\": \"string\",\n \"continuous\": true,\n \"color\": \"string\",\n \"auto_accept_bookings\": true,\n \"timezone\": \"string\",\n \"quantity\": 1,\n \"staggered_quantity\": 1,\n \"has_children\": true,\n \"available_from\": \"2019-08-24\",\n \"available_to\": \"2019-08-24\",\n \"created_at\": \"2019-08-24T14:15:22Z\",\n \"seo\": true,\n \"live\": true,\n \"public_listing\": true,\n \"display_public_description\": true,\n \"hidden\": true,\n \"settings\": [\n {\n \"checkIn.autoExpiry\": true,\n \"checkIn.autoExpiresAfter\": 0,\n \"checkIn.allowedAdvancePeriod\": 1,\n \"checkIn.allowedDelayPeriod\": 1\n }\n ],\n \"preview_token\": \"string\",\n \"email_info\": \"string\"\n },\n \"relationships\": {\n \"parent\": {\n \"id\": \"string\"\n },\n \"children\": {\n \"id\": \"string\"\n },\n \"cover_image\": {\n \"id\": \"string\"\n },\n \"gallery_images\": {\n \"id\": \"string\"\n },\n \"organization\": {\n \"id\": \"string\"\n },\n \"group\": {\n \"id\": \"string\"\n },\n \"category\": {\n \"id\": \"string\"\n },\n \"resource_properties\": {\n \"id\": \"string\"\n },\n \"featured_properties\": {\n \"id\": \"string\"\n },\n \"schedules\": {\n \"id\": \"string\"\n },\n \"external_calendars\": {\n \"id\": \"string\"\n },\n \"services\": {\n \"id\": \"string\"\n },\n \"custom_address\": {\n \"id\": \"string\"\n },\n \"location\": {\n \"id\": \"string\"\n }\n },\n \"meta\": {\n \"is_available\": true,\n \"booking_count\": 0,\n \"number_available\": true,\n \"minimal_service\": \"string\",\n \"service_list\": \"string\",\n \"services_count\": 0,\n \"settings\": \"string\",\n \"meta_settings\": \"string\",\n \"zoom\": \"string\",\n \"client_url\": \"http://example.com\",\n \"preview_url\": \"http://example.com\"\n },\n \"links\": {\n \"self\": \"http://example.com\"\n }\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/vnd.api+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://b.anny.co/api/v1/resources/{resource_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/vnd.api+json")
.body("{\n \"data\": {\n \"id\": \"string\",\n \"type\": \"resources\",\n \"attributes\": {\n \"slug\": \"string\",\n \"name\": \"string\",\n \"description\": \"string\",\n \"plain_description\": \"string\",\n \"availabilityMode\": \"string\",\n \"continuous\": true,\n \"color\": \"string\",\n \"auto_accept_bookings\": true,\n \"timezone\": \"string\",\n \"quantity\": 1,\n \"staggered_quantity\": 1,\n \"has_children\": true,\n \"available_from\": \"2019-08-24\",\n \"available_to\": \"2019-08-24\",\n \"created_at\": \"2019-08-24T14:15:22Z\",\n \"seo\": true,\n \"live\": true,\n \"public_listing\": true,\n \"display_public_description\": true,\n \"hidden\": true,\n \"settings\": [\n {\n \"checkIn.autoExpiry\": true,\n \"checkIn.autoExpiresAfter\": 0,\n \"checkIn.allowedAdvancePeriod\": 1,\n \"checkIn.allowedDelayPeriod\": 1\n }\n ],\n \"preview_token\": \"string\",\n \"email_info\": \"string\"\n },\n \"relationships\": {\n \"parent\": {\n \"id\": \"string\"\n },\n \"children\": {\n \"id\": \"string\"\n },\n \"cover_image\": {\n \"id\": \"string\"\n },\n \"gallery_images\": {\n \"id\": \"string\"\n },\n \"organization\": {\n \"id\": \"string\"\n },\n \"group\": {\n \"id\": \"string\"\n },\n \"category\": {\n \"id\": \"string\"\n },\n \"resource_properties\": {\n \"id\": \"string\"\n },\n \"featured_properties\": {\n \"id\": \"string\"\n },\n \"schedules\": {\n \"id\": \"string\"\n },\n \"external_calendars\": {\n \"id\": \"string\"\n },\n \"services\": {\n \"id\": \"string\"\n },\n \"custom_address\": {\n \"id\": \"string\"\n },\n \"location\": {\n \"id\": \"string\"\n }\n },\n \"meta\": {\n \"is_available\": true,\n \"booking_count\": 0,\n \"number_available\": true,\n \"minimal_service\": \"string\",\n \"service_list\": \"string\",\n \"services_count\": 0,\n \"settings\": \"string\",\n \"meta_settings\": \"string\",\n \"zoom\": \"string\",\n \"client_url\": \"http://example.com\",\n \"preview_url\": \"http://example.com\"\n },\n \"links\": {\n \"self\": \"http://example.com\"\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://b.anny.co/api/v1/resources/{resource_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/vnd.api+json'
request.body = "{\n \"data\": {\n \"id\": \"string\",\n \"type\": \"resources\",\n \"attributes\": {\n \"slug\": \"string\",\n \"name\": \"string\",\n \"description\": \"string\",\n \"plain_description\": \"string\",\n \"availabilityMode\": \"string\",\n \"continuous\": true,\n \"color\": \"string\",\n \"auto_accept_bookings\": true,\n \"timezone\": \"string\",\n \"quantity\": 1,\n \"staggered_quantity\": 1,\n \"has_children\": true,\n \"available_from\": \"2019-08-24\",\n \"available_to\": \"2019-08-24\",\n \"created_at\": \"2019-08-24T14:15:22Z\",\n \"seo\": true,\n \"live\": true,\n \"public_listing\": true,\n \"display_public_description\": true,\n \"hidden\": true,\n \"settings\": [\n {\n \"checkIn.autoExpiry\": true,\n \"checkIn.autoExpiresAfter\": 0,\n \"checkIn.allowedAdvancePeriod\": 1,\n \"checkIn.allowedDelayPeriod\": 1\n }\n ],\n \"preview_token\": \"string\",\n \"email_info\": \"string\"\n },\n \"relationships\": {\n \"parent\": {\n \"id\": \"string\"\n },\n \"children\": {\n \"id\": \"string\"\n },\n \"cover_image\": {\n \"id\": \"string\"\n },\n \"gallery_images\": {\n \"id\": \"string\"\n },\n \"organization\": {\n \"id\": \"string\"\n },\n \"group\": {\n \"id\": \"string\"\n },\n \"category\": {\n \"id\": \"string\"\n },\n \"resource_properties\": {\n \"id\": \"string\"\n },\n \"featured_properties\": {\n \"id\": \"string\"\n },\n \"schedules\": {\n \"id\": \"string\"\n },\n \"external_calendars\": {\n \"id\": \"string\"\n },\n \"services\": {\n \"id\": \"string\"\n },\n \"custom_address\": {\n \"id\": \"string\"\n },\n \"location\": {\n \"id\": \"string\"\n }\n },\n \"meta\": {\n \"is_available\": true,\n \"booking_count\": 0,\n \"number_available\": true,\n \"minimal_service\": \"string\",\n \"service_list\": \"string\",\n \"services_count\": 0,\n \"settings\": \"string\",\n \"meta_settings\": \"string\",\n \"zoom\": \"string\",\n \"client_url\": \"http://example.com\",\n \"preview_url\": \"http://example.com\"\n },\n \"links\": {\n \"self\": \"http://example.com\"\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "<string>",
"type": "resources",
"attributes": {
"name": "<string>",
"local_name": "<string>",
"slug": "<string>",
"description": "<string>",
"plain_description": "<string>",
"email_info": "<string>",
"color": "<string>",
"color_map": {},
"icon": "<string>",
"quantity": 123,
"max_booking_quantity": 123,
"max_sequence_quantity": 123,
"exclusive_slots": true,
"timezone": "<string>",
"latitude": 123,
"longitude": 123,
"availability_mode": "<string>",
"online_resource": true,
"bookings_enabled": true,
"requires_quota": true,
"level": 123,
"archived": true,
"live": true,
"public_listing": true,
"hidden": true,
"display_public_description": true,
"email": "<string>",
"preview_token": "<string>",
"settings": {},
"created_at": "<string>"
},
"links": {
"self": "<string>"
},
"relationships": {
"organization": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"parent": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"children": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"category": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"location": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"cover_image": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"logo_image": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"gallery_images": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"services": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"schedules": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"resource_groups": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"resource_properties": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"featured_properties": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"external_calendars": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"communities": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"files": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"resource_maps": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
}
},
"meta": {
"minimal_service": {}
}
}
}Resource Management
Update a specific resource
PATCH
/
api
/
v1
/
resources
/
{resource_id}
Update a specific resource
curl --request PATCH \
--url https://b.anny.co/api/v1/resources/{resource_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/vnd.api+json' \
--data '
{
"data": {
"id": "string",
"type": "resources",
"attributes": {
"slug": "string",
"name": "string",
"description": "string",
"plain_description": "string",
"availabilityMode": "string",
"continuous": true,
"color": "string",
"auto_accept_bookings": true,
"timezone": "string",
"quantity": 1,
"staggered_quantity": 1,
"has_children": true,
"available_from": "2019-08-24",
"available_to": "2019-08-24",
"created_at": "2019-08-24T14:15:22Z",
"seo": true,
"live": true,
"public_listing": true,
"display_public_description": true,
"hidden": true,
"settings": [
{
"checkIn.autoExpiry": true,
"checkIn.autoExpiresAfter": 0,
"checkIn.allowedAdvancePeriod": 1,
"checkIn.allowedDelayPeriod": 1
}
],
"preview_token": "string",
"email_info": "string"
},
"relationships": {
"parent": {
"id": "string"
},
"children": {
"id": "string"
},
"cover_image": {
"id": "string"
},
"gallery_images": {
"id": "string"
},
"organization": {
"id": "string"
},
"group": {
"id": "string"
},
"category": {
"id": "string"
},
"resource_properties": {
"id": "string"
},
"featured_properties": {
"id": "string"
},
"schedules": {
"id": "string"
},
"external_calendars": {
"id": "string"
},
"services": {
"id": "string"
},
"custom_address": {
"id": "string"
},
"location": {
"id": "string"
}
},
"meta": {
"is_available": true,
"booking_count": 0,
"number_available": true,
"minimal_service": "string",
"service_list": "string",
"services_count": 0,
"settings": "string",
"meta_settings": "string",
"zoom": "string",
"client_url": "http://example.com",
"preview_url": "http://example.com"
},
"links": {
"self": "http://example.com"
}
}
}
'import requests
url = "https://b.anny.co/api/v1/resources/{resource_id}"
payload = { "data": {
"id": "string",
"type": "resources",
"attributes": {
"slug": "string",
"name": "string",
"description": "string",
"plain_description": "string",
"availabilityMode": "string",
"continuous": True,
"color": "string",
"auto_accept_bookings": True,
"timezone": "string",
"quantity": 1,
"staggered_quantity": 1,
"has_children": True,
"available_from": "2019-08-24",
"available_to": "2019-08-24",
"created_at": "2019-08-24T14:15:22Z",
"seo": True,
"live": True,
"public_listing": True,
"display_public_description": True,
"hidden": True,
"settings": [
{
"checkIn.autoExpiry": True,
"checkIn.autoExpiresAfter": 0,
"checkIn.allowedAdvancePeriod": 1,
"checkIn.allowedDelayPeriod": 1
}
],
"preview_token": "string",
"email_info": "string"
},
"relationships": {
"parent": { "id": "string" },
"children": { "id": "string" },
"cover_image": { "id": "string" },
"gallery_images": { "id": "string" },
"organization": { "id": "string" },
"group": { "id": "string" },
"category": { "id": "string" },
"resource_properties": { "id": "string" },
"featured_properties": { "id": "string" },
"schedules": { "id": "string" },
"external_calendars": { "id": "string" },
"services": { "id": "string" },
"custom_address": { "id": "string" },
"location": { "id": "string" }
},
"meta": {
"is_available": True,
"booking_count": 0,
"number_available": True,
"minimal_service": "string",
"service_list": "string",
"services_count": 0,
"settings": "string",
"meta_settings": "string",
"zoom": "string",
"client_url": "http://example.com",
"preview_url": "http://example.com"
},
"links": { "self": "http://example.com" }
} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/vnd.api+json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/vnd.api+json'},
body: JSON.stringify({
data: {
id: 'string',
type: 'resources',
attributes: {
slug: 'string',
name: 'string',
description: 'string',
plain_description: 'string',
availabilityMode: 'string',
continuous: true,
color: 'string',
auto_accept_bookings: true,
timezone: 'string',
quantity: 1,
staggered_quantity: 1,
has_children: true,
available_from: '2019-08-24',
available_to: '2019-08-24',
created_at: '2019-08-24T14:15:22Z',
seo: true,
live: true,
public_listing: true,
display_public_description: true,
hidden: true,
settings: [
{
'checkIn.autoExpiry': true,
'checkIn.autoExpiresAfter': 0,
'checkIn.allowedAdvancePeriod': 1,
'checkIn.allowedDelayPeriod': 1
}
],
preview_token: 'string',
email_info: 'string'
},
relationships: {
parent: {id: 'string'},
children: {id: 'string'},
cover_image: {id: 'string'},
gallery_images: {id: 'string'},
organization: {id: 'string'},
group: {id: 'string'},
category: {id: 'string'},
resource_properties: {id: 'string'},
featured_properties: {id: 'string'},
schedules: {id: 'string'},
external_calendars: {id: 'string'},
services: {id: 'string'},
custom_address: {id: 'string'},
location: {id: 'string'}
},
meta: {
is_available: true,
booking_count: 0,
number_available: true,
minimal_service: 'string',
service_list: 'string',
services_count: 0,
settings: 'string',
meta_settings: 'string',
zoom: 'string',
client_url: 'http://example.com',
preview_url: 'http://example.com'
},
links: {self: 'http://example.com'}
}
})
};
fetch('https://b.anny.co/api/v1/resources/{resource_id}', 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/resources/{resource_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
'id' => 'string',
'type' => 'resources',
'attributes' => [
'slug' => 'string',
'name' => 'string',
'description' => 'string',
'plain_description' => 'string',
'availabilityMode' => 'string',
'continuous' => true,
'color' => 'string',
'auto_accept_bookings' => true,
'timezone' => 'string',
'quantity' => 1,
'staggered_quantity' => 1,
'has_children' => true,
'available_from' => '2019-08-24',
'available_to' => '2019-08-24',
'created_at' => '2019-08-24T14:15:22Z',
'seo' => true,
'live' => true,
'public_listing' => true,
'display_public_description' => true,
'hidden' => true,
'settings' => [
[
'checkIn.autoExpiry' => true,
'checkIn.autoExpiresAfter' => 0,
'checkIn.allowedAdvancePeriod' => 1,
'checkIn.allowedDelayPeriod' => 1
]
],
'preview_token' => 'string',
'email_info' => 'string'
],
'relationships' => [
'parent' => [
'id' => 'string'
],
'children' => [
'id' => 'string'
],
'cover_image' => [
'id' => 'string'
],
'gallery_images' => [
'id' => 'string'
],
'organization' => [
'id' => 'string'
],
'group' => [
'id' => 'string'
],
'category' => [
'id' => 'string'
],
'resource_properties' => [
'id' => 'string'
],
'featured_properties' => [
'id' => 'string'
],
'schedules' => [
'id' => 'string'
],
'external_calendars' => [
'id' => 'string'
],
'services' => [
'id' => 'string'
],
'custom_address' => [
'id' => 'string'
],
'location' => [
'id' => 'string'
]
],
'meta' => [
'is_available' => true,
'booking_count' => 0,
'number_available' => true,
'minimal_service' => 'string',
'service_list' => 'string',
'services_count' => 0,
'settings' => 'string',
'meta_settings' => 'string',
'zoom' => 'string',
'client_url' => 'http://example.com',
'preview_url' => 'http://example.com'
],
'links' => [
'self' => 'http://example.com'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/vnd.api+json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://b.anny.co/api/v1/resources/{resource_id}"
payload := strings.NewReader("{\n \"data\": {\n \"id\": \"string\",\n \"type\": \"resources\",\n \"attributes\": {\n \"slug\": \"string\",\n \"name\": \"string\",\n \"description\": \"string\",\n \"plain_description\": \"string\",\n \"availabilityMode\": \"string\",\n \"continuous\": true,\n \"color\": \"string\",\n \"auto_accept_bookings\": true,\n \"timezone\": \"string\",\n \"quantity\": 1,\n \"staggered_quantity\": 1,\n \"has_children\": true,\n \"available_from\": \"2019-08-24\",\n \"available_to\": \"2019-08-24\",\n \"created_at\": \"2019-08-24T14:15:22Z\",\n \"seo\": true,\n \"live\": true,\n \"public_listing\": true,\n \"display_public_description\": true,\n \"hidden\": true,\n \"settings\": [\n {\n \"checkIn.autoExpiry\": true,\n \"checkIn.autoExpiresAfter\": 0,\n \"checkIn.allowedAdvancePeriod\": 1,\n \"checkIn.allowedDelayPeriod\": 1\n }\n ],\n \"preview_token\": \"string\",\n \"email_info\": \"string\"\n },\n \"relationships\": {\n \"parent\": {\n \"id\": \"string\"\n },\n \"children\": {\n \"id\": \"string\"\n },\n \"cover_image\": {\n \"id\": \"string\"\n },\n \"gallery_images\": {\n \"id\": \"string\"\n },\n \"organization\": {\n \"id\": \"string\"\n },\n \"group\": {\n \"id\": \"string\"\n },\n \"category\": {\n \"id\": \"string\"\n },\n \"resource_properties\": {\n \"id\": \"string\"\n },\n \"featured_properties\": {\n \"id\": \"string\"\n },\n \"schedules\": {\n \"id\": \"string\"\n },\n \"external_calendars\": {\n \"id\": \"string\"\n },\n \"services\": {\n \"id\": \"string\"\n },\n \"custom_address\": {\n \"id\": \"string\"\n },\n \"location\": {\n \"id\": \"string\"\n }\n },\n \"meta\": {\n \"is_available\": true,\n \"booking_count\": 0,\n \"number_available\": true,\n \"minimal_service\": \"string\",\n \"service_list\": \"string\",\n \"services_count\": 0,\n \"settings\": \"string\",\n \"meta_settings\": \"string\",\n \"zoom\": \"string\",\n \"client_url\": \"http://example.com\",\n \"preview_url\": \"http://example.com\"\n },\n \"links\": {\n \"self\": \"http://example.com\"\n }\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/vnd.api+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://b.anny.co/api/v1/resources/{resource_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/vnd.api+json")
.body("{\n \"data\": {\n \"id\": \"string\",\n \"type\": \"resources\",\n \"attributes\": {\n \"slug\": \"string\",\n \"name\": \"string\",\n \"description\": \"string\",\n \"plain_description\": \"string\",\n \"availabilityMode\": \"string\",\n \"continuous\": true,\n \"color\": \"string\",\n \"auto_accept_bookings\": true,\n \"timezone\": \"string\",\n \"quantity\": 1,\n \"staggered_quantity\": 1,\n \"has_children\": true,\n \"available_from\": \"2019-08-24\",\n \"available_to\": \"2019-08-24\",\n \"created_at\": \"2019-08-24T14:15:22Z\",\n \"seo\": true,\n \"live\": true,\n \"public_listing\": true,\n \"display_public_description\": true,\n \"hidden\": true,\n \"settings\": [\n {\n \"checkIn.autoExpiry\": true,\n \"checkIn.autoExpiresAfter\": 0,\n \"checkIn.allowedAdvancePeriod\": 1,\n \"checkIn.allowedDelayPeriod\": 1\n }\n ],\n \"preview_token\": \"string\",\n \"email_info\": \"string\"\n },\n \"relationships\": {\n \"parent\": {\n \"id\": \"string\"\n },\n \"children\": {\n \"id\": \"string\"\n },\n \"cover_image\": {\n \"id\": \"string\"\n },\n \"gallery_images\": {\n \"id\": \"string\"\n },\n \"organization\": {\n \"id\": \"string\"\n },\n \"group\": {\n \"id\": \"string\"\n },\n \"category\": {\n \"id\": \"string\"\n },\n \"resource_properties\": {\n \"id\": \"string\"\n },\n \"featured_properties\": {\n \"id\": \"string\"\n },\n \"schedules\": {\n \"id\": \"string\"\n },\n \"external_calendars\": {\n \"id\": \"string\"\n },\n \"services\": {\n \"id\": \"string\"\n },\n \"custom_address\": {\n \"id\": \"string\"\n },\n \"location\": {\n \"id\": \"string\"\n }\n },\n \"meta\": {\n \"is_available\": true,\n \"booking_count\": 0,\n \"number_available\": true,\n \"minimal_service\": \"string\",\n \"service_list\": \"string\",\n \"services_count\": 0,\n \"settings\": \"string\",\n \"meta_settings\": \"string\",\n \"zoom\": \"string\",\n \"client_url\": \"http://example.com\",\n \"preview_url\": \"http://example.com\"\n },\n \"links\": {\n \"self\": \"http://example.com\"\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://b.anny.co/api/v1/resources/{resource_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/vnd.api+json'
request.body = "{\n \"data\": {\n \"id\": \"string\",\n \"type\": \"resources\",\n \"attributes\": {\n \"slug\": \"string\",\n \"name\": \"string\",\n \"description\": \"string\",\n \"plain_description\": \"string\",\n \"availabilityMode\": \"string\",\n \"continuous\": true,\n \"color\": \"string\",\n \"auto_accept_bookings\": true,\n \"timezone\": \"string\",\n \"quantity\": 1,\n \"staggered_quantity\": 1,\n \"has_children\": true,\n \"available_from\": \"2019-08-24\",\n \"available_to\": \"2019-08-24\",\n \"created_at\": \"2019-08-24T14:15:22Z\",\n \"seo\": true,\n \"live\": true,\n \"public_listing\": true,\n \"display_public_description\": true,\n \"hidden\": true,\n \"settings\": [\n {\n \"checkIn.autoExpiry\": true,\n \"checkIn.autoExpiresAfter\": 0,\n \"checkIn.allowedAdvancePeriod\": 1,\n \"checkIn.allowedDelayPeriod\": 1\n }\n ],\n \"preview_token\": \"string\",\n \"email_info\": \"string\"\n },\n \"relationships\": {\n \"parent\": {\n \"id\": \"string\"\n },\n \"children\": {\n \"id\": \"string\"\n },\n \"cover_image\": {\n \"id\": \"string\"\n },\n \"gallery_images\": {\n \"id\": \"string\"\n },\n \"organization\": {\n \"id\": \"string\"\n },\n \"group\": {\n \"id\": \"string\"\n },\n \"category\": {\n \"id\": \"string\"\n },\n \"resource_properties\": {\n \"id\": \"string\"\n },\n \"featured_properties\": {\n \"id\": \"string\"\n },\n \"schedules\": {\n \"id\": \"string\"\n },\n \"external_calendars\": {\n \"id\": \"string\"\n },\n \"services\": {\n \"id\": \"string\"\n },\n \"custom_address\": {\n \"id\": \"string\"\n },\n \"location\": {\n \"id\": \"string\"\n }\n },\n \"meta\": {\n \"is_available\": true,\n \"booking_count\": 0,\n \"number_available\": true,\n \"minimal_service\": \"string\",\n \"service_list\": \"string\",\n \"services_count\": 0,\n \"settings\": \"string\",\n \"meta_settings\": \"string\",\n \"zoom\": \"string\",\n \"client_url\": \"http://example.com\",\n \"preview_url\": \"http://example.com\"\n },\n \"links\": {\n \"self\": \"http://example.com\"\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "<string>",
"type": "resources",
"attributes": {
"name": "<string>",
"local_name": "<string>",
"slug": "<string>",
"description": "<string>",
"plain_description": "<string>",
"email_info": "<string>",
"color": "<string>",
"color_map": {},
"icon": "<string>",
"quantity": 123,
"max_booking_quantity": 123,
"max_sequence_quantity": 123,
"exclusive_slots": true,
"timezone": "<string>",
"latitude": 123,
"longitude": 123,
"availability_mode": "<string>",
"online_resource": true,
"bookings_enabled": true,
"requires_quota": true,
"level": 123,
"archived": true,
"live": true,
"public_listing": true,
"hidden": true,
"display_public_description": true,
"email": "<string>",
"preview_token": "<string>",
"settings": {},
"created_at": "<string>"
},
"links": {
"self": "<string>"
},
"relationships": {
"organization": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"parent": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"children": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"category": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"location": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"cover_image": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"logo_image": {
"data": {
"type": "<string>",
"id": "<string>"
},
"links": {
"self": "<string>"
}
},
"gallery_images": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"services": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"schedules": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"resource_groups": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"resource_properties": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"featured_properties": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"external_calendars": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"communities": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"files": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
},
"resource_maps": {
"data": [
{
"type": "<string>",
"id": "<string>"
}
],
"links": {
"self": "<string>"
}
}
},
"meta": {
"minimal_service": {}
}
}
}Autorisierungen
The access token received from the authorization server in the OAuth 2.0 flow.
Pfadparameter
Body
application/vnd.api+json
A bookable resource (room, person, equipment, etc.) organized in a nested tree structure.
Show child attributes
Show child attributes
Antwort
200 - application/vnd.api+json
OK
A bookable resource (room, person, equipment, etc.) organized in a nested tree structure.
Show child attributes
Show child attributes
⌘I