create a sub-resource state for a resource
Query Parameters
- Type: string
o Organization ID
- Type: string
include
Body
application/vnd.api+json
- Type: object
data
Responses
- application/vnd.api+json
401 Unauthorized
Request Example for post/api/v1/service-sub-resources
curl 'https://b.anny.co/api/v1/service-sub-resources?o=&include=' \
--request POST \
--header 'Content-Type: application/vnd.api+json' \
--data '{
"data": {
"type": "service-sub-resources",
"attributes": {
"is_required": false
},
"relationships": {
"resource": {
"data": {
"id": "21886",
"type": "resources"
}
}
},
"meta": {}
}
}'
{
"data": {
"type": "service-sub-resources",
"id": "1434",
"attributes": {
"is_required": false
},
"relationships": {
"resource": {
"data": {
"type": "resources",
"id": "21886"
}
}
},
"links": {
"self": "https://b.anny.co/api/v1/service-sub-resources/1436"
}
},
"included": [
{
"type": "resources",
"id": "21886",
"attributes": {
"slug": "m01",
"name": "M01 - Aachen",
"description": "<p>Testbeschreibung</p>",
"plain_description": "Testbeschreibung",
"availabilityMode": null,
"continuous": false,
"color": null,
"auto_accept_bookings": true,
"timezone": "Europe/Berlin",
"quantity": 1,
"staggered_quantity": null,
"max_booking_quantity": 1,
"has_children": false,
"available_from": null,
"available_to": null,
"created_at": "2021-09-15T09:48:15+00:00",
"seo": true,
"live": true,
"public_listing": true,
"display_public_description": false,
"hidden": false,
"settings": {
"showAvailabilityCalendar": true,
"showAvailabilityCount": true,
"checkIn": {
"isEnabled": false,
"autoExpiry": false,
"autoExpiresAfter": 15,
"allowedAdvancePeriod": 15,
"allowedDelayPeriod": 30,
"allowMultiple": false,
"releaseOnCheckout": false
},
"printLabels": false,
"checkout": {
"customerCanPickChildren": false,
"requiresLogin": false,
"requiresLoginReason": "",
"verifyGuestEmail": false
},
"resources": {
"maxBookings": {
"perDay": null,
"perWeek": null,
"perMonth": null
}
},
"maxBookings": {
"perSlot": null,
"perDay": null,
"perWeek": null,
"perMonth": null
},
"selfCheckIn": {
"isEnabled": false,
"disabledUntil": 15,
"geoCheckEnabled": true,
"geoCheckMaxDelta": 997,
"allowedOverrunTime": 60
}
},
"preview_token": "ktlLeS7TseEXf8ZIE6WhWhFbITep9K",
"email_info": null
},
"meta": {
"settings": {
"showAvailabilityCalendar": true,
"showAvailabilityCount": true,
"checkout": {
"customerCanPickChildren": false,
"requiresLogin": false,
"requiresLoginReason": "",
"verifyGuestEmail": false
},
"checkIn": {
"isEnabled": false
},
"selfCheckIn": {
"isEnabled": false,
"disabledUntil": 15,
"geoCheckEnabled": true,
"geoCheckMaxDelta": 997,
"allowedOverrunTime": 60
}
},
"meta_settings": {
"showAvailabilityCalendar": true,
"showAvailabilityCount": true,
"checkout": {
"customerCanPickChildren": false,
"requiresLogin": false,
"requiresLoginReason": "",
"verifyGuestEmail": false
},
"checkIn": {
"isEnabled": false
},
"selfCheckIn": {
"isEnabled": false,
"disabledUntil": 15,
"geoCheckEnabled": true,
"geoCheckMaxDelta": 997,
"allowedOverrunTime": 60
}
},
"zoom": false
}
}
]
}