API - Planyo Web Services - get_resource_info

Ti trovi qui: Planyo » Aiuto » API » get_resource_info

get_resource_info

Description:

Returns information for given resource, including photos and resource-specific properties defined in the admin panel in: Site settings / Custom resource properties

Input:

resource_id int required
ID of the resource
method string required
must be set to get_resource_info
language string optional
by specifying a 2-letter (ISO 639-1) language code (all capital letters e.g. EN, DE, FR, ES, IT) you can change the language of the text values returned
api_key string required
your API key - Click here to get your key. If your API key uses a hash key, you must also include the parameters hash_key and hash_timestamp.

Output:

name string
Resource name
translated_name string
Resource name translated to the language passed in the language parameter
quantity int
Number of units available
site_id int
Planyo site ID
confirmation_type ConfirmationType
Reservation approval mode
category int
Category of the resource
sharing_mode SharingMode
Resource's sharing mode
start_hour int
Resource is available on working days from this time (ignore for day-based resources)
end_hour int
Resource is available on working days until this time (ignore for day-based resources)
start_quarters Quarters
Allowed start quarters (ignore for day-based resources)
time_unit TimeUnit
Base time unit of the resource (day-based, hour-based or quarter-based)
unit_price string
Price of one unit (returned as float) or URL for custom pricing
unit_names string
Comma-seprated unit names, in case the resource has quantity greater than 1 and units have defined names
predefined_durations array
If the resource has a limited choice of durations, they will be listed in this array. The keys are duration labels and the values are durations in hours
currency string
Currency in which prices are expressed (3-letter ISO 4217 code)
is_overnight_stay bool
True for over-night rentals (e.g. hotels, vacation homes)
is_published bool
True if the resource is marked as published, false if it's unpublished.
max_quantity_per_rental int
Max. quantity allowed for a single reservation
prepayment_amount string
This is the pre-payment (deposit) amount set in resource settings / reservation process. Value is returned as percentage (e.g. 100%) or as a numeric value (if fixed amount).
prepayment_amount_valid_until int
The max. number of hours before rental when the customer can pay the partial pre-payment (deposit) amount. After this time point, the full amount must be payed.
properties array
Array whose items are resource-specific properties (name => value) defined in the admin panel in: Site settings / Custom resource properties
min_rental_time float
Minimum rental time expressed in hours
max_rental_time float
Maximum rental time expressed in hours
start_times string
Resource setting Restrict starting times. This only applies to hour-based resources. The different times should be comma-separated.
min_hours_to_rental int
Resource setting Min. time between reservation and rental. This is an integer, time is expressed in hours
max_days_to_rental int
Resource setting Max. time between reservation and rental. This is an integer, time is expressed in days.
min_time_between_rentals float
Minimum time between consecutive rentals, expressed in hours
event_dates string
For event-type resources, you can specify comma-separated start dates or start dates and times (in the same way as in resource settings).
photos array
Array whose items are named arrays with following keys: id (unique photo ID), path (URL of the photo), title (optional title)
resource_admin_id int
ID of the resource admin (NULL if not set)
resource_admin_name string
Name of the resource admin
resource_admin_email string
Email address of the resource admin

API playground:

Click here to test this function in the API playground.