Changes

From SimplyBook.me
no edit summary
Line 93: Line 93:  
should pass it as additional field. For example: <code>{"name": "promocode", "value": "some code", "type": "text"}</code>See [[#book response|example]] of <code>book</code> API method response.
 
should pass it as additional field. For example: <code>{"name": "promocode", "value": "some code", "type": "text"}</code>See [[#book response|example]] of <code>book</code> API method response.
    +
See also:
 +
 +
* [http://wiki.simplybook.me/index.php/Settings#Timeframe Timeframe information]
    
----
 
----
Line 119: Line 122:  
Parameters:
 
Parameters:
   −
* '''$id''' Integer  
+
* '''$id''' Integer identifier of batch. See <code>[[#createBatch|createBatch]]</code> API method.
* '''$bookingIds''' Array  
+
* '''$bookingIds''' Array ids of bookings included to batch.
    
Returns boolean.
 
Returns boolean.
   −
Cancel batch of bookings. Signature is NOT required.First id is used for information in notifications
+
Cancel batch of bookings. Returns true on success. Returns an error with code -32080 (Appointment couldn't be found)
 +
if no booking with specified id were found. A booking with first id in <code>$bookingIds</code> list is used for
 +
information in notifications.
      Line 139: Line 144:  
Returns Boolean.
 
Returns Boolean.
   −
Cancel booking. Signature is NOT required
+
Cancels booking. Returns true on success. Returns an error with code -32080 (Appointment couldn't be found) if
 +
no booking with specified id were found.
      Line 192: Line 198:     
Edit existing booking record. See [[#book|book]] API method description for more details about date/time parameters,
 
Edit existing booking record. See [[#book|book]] API method description for more details about date/time parameters,
time zone handling and additional fields.
+
time zone handling and additional fields. Returns null if parameters not valid.
      Line 1,169: Line 1,175:     
Returns list of objects with information about bookings pending approval if [[Plugins#Approve booking|Approve booking]]
 
Returns list of objects with information about bookings pending approval if [[Plugins#Approve booking|Approve booking]]
plugin enabled. Returns empty list if plugin not enabled. Use <code>[[#isPluginActivated|isPluginActivated('approve_booking')]]</code>
+
plugin enabled. Returns empty list if plugin not enabled. Use <code>[[#isPluginActivated|isPluginActivated('approve_booking')]]
 
API method call to check if plugin enabled.
 
API method call to check if plugin enabled.
   Line 1,183: Line 1,189:     
Returns count of bookings pending approval if [[Plugins#Approve booking|Approve booking]] plugin enabled. Returns
 
Returns count of bookings pending approval if [[Plugins#Approve booking|Approve booking]] plugin enabled. Returns
0 if plugin not enabled. Use <code>[[#isPluginActivated|isPluginActivated('approve_booking')]]</code> API method call to
+
0 if plugin not enabled. Use <code>[[#isPluginActivated|isPluginActivated('approve_booking')]]</code> API method
check if plugin enabled.
+
call to check if plugin enabled.
      Line 1,236: Line 1,242:     
----
 
----
      
== Constants ==
 
== Constants ==