Title: API Access
Last modified: July 10, 2021

---

# API Access

 *  [pacman789](https://wordpress.org/support/users/pacman789/)
 * (@pacman789)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/api-access-4/)
 * Hi Team,
    How can I use the local API? I find the API key, but I couldn’t find
   documentationhow to use it. I would like to download all reservations through
   api. Could you send me an example?What is the api link? For example: Get request:
   [https://yourwebsite.com/pinpont/rest/get](https://yourwebsite.com/pinpont/rest/get)
   Params: Content-type: json Api-key: yourapikey What are the possibilities? Only
   get reservations? Can I delete it or set a new one?
 * Thanks for your help.
    Regards, pacman789

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Support [Pinpoint World Support](https://wordpress.org/support/users/pinpointworld/)
 * (@pinpointworld)
 * [4 years, 10 months ago](https://wordpress.org/support/topic/api-access-4/#post-14727470)
 * Hi,
 * We have updated the API and we will put the documentation online later this week.
   
   Here is an example of how to call the API, and this API only works on the server-
   side it can’t be called in the browser. By default, you get 10 reservations per
   page.
 *     ```
       <?php
   
           $post_variables = array('key' => '539houiBOVF5G0KGZM1ZxdHLGoox9ebc-1');//the key from you Pinpoint Bookin System Dashboard
           $get_variables = array('dopbsp_api' => 'true',
                                  'action' => 'get',
                                  'data' => 'reservations',
                                   // 'start_date' => 'YYYY-MM-DD',
                                   // 'end_date' => 'YYYY-MM-DD',
                                   // 'start_hour' => 'HH:MM',
                                   // 'end_hour' => 'HH:MM',
                                   'status' => 'expired',
                                   'payment_methods' => 'redsys' ,
                                   //'search' => 'email',
                                   // 'page' => '{page number}',
                                   // 'per_page' => '{the number of reservations per page}',
                                   'order' =>  'DESC',
                                   'order_by' =>  'id'
                              );
   
           $link = 'https://your-domain.com';
   
       // 'start_date' => 'YYYY-MM-DD'
       // 'end_date' => 'YYYY-MM-DD'
       // 'start_hour' => 'HH:MM'
       // 'end_hour' => 'HH:MM'
       // 'status' => 'pending' | 'approved' | 'rejected' | 'canceled' | 'expired'
       // 'payment_methods' => 'none' | 'default' | 'woocommerce' | 'paypal' | 'stripe' | ...
       // 'search' => '{search term}'
       // 'page' => '{page number}'
       // 'per_page' => '{the number of reservations per page}'
       // 'order' => 'ASC' | 'DESC'
       // 'order_by' => 'check_in' | 'check_out' | 'start_our' | 'end_hour' | 'id' | 'status' | 'date_created'
   
           $ch = curl_init();
   
           curl_setopt($ch, CURLOPT_URL, $link.'?'.implode('&', array_map(function($value, $key){return $key.'='.$value;}, $get_variables, array_keys($get_variables))));
           curl_setopt($ch, CURLOPT_POST, 1);
           curl_setopt($ch, CURLOPT_POSTFIELDS, $post_variables);
           curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
   
           $server_output = curl_exec($ch);
   
           curl_close ($ch);
   
           echo '<pre>';    
           print_r(json_decode($server_output));
           echo '</pre>';
       ```
   
 *  [Oleksandr](https://wordpress.org/support/users/firewa11/)
 * (@firewa11)
 * [4 years, 6 months ago](https://wordpress.org/support/topic/api-access-4/#post-15116663)
 * Any news on this?
    I’m interested in API access as well. We would like to create
   an Android app, which will let customers book on our site. Can you please provide
   some API documentation for this?

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘API Access’ is closed to new replies.

 * ![](https://ps.w.org/booking-system/assets/icon-256x256.png?rev=2192807)
 * [Pinpoint Booking System - Version 2](https://wordpress.org/plugins/booking-system/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/booking-system/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/booking-system/)
 * [Active Topics](https://wordpress.org/support/plugin/booking-system/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/booking-system/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/booking-system/reviews/)

## Tags

 * [api](https://wordpress.org/support/topic-tag/api/)

 * 2 replies
 * 3 participants
 * Last reply from: [Oleksandr](https://wordpress.org/support/users/firewa11/)
 * Last activity: [4 years, 6 months ago](https://wordpress.org/support/topic/api-access-4/#post-15116663)
 * Status: not resolved