Pike13 For Developers
Get Started
Authentication
Core API
Reporting API
Webhooks API
Announcements

Core API Documentation

Punches

A punch pays for a visit with a plan.

Desk Only

GET /api/v2/desk/punches/:id

Returns the details of a punch.

Show curl example

REQUEST
$ curl https://mybiz.pike13.com/api/v2/desk/punches/1 \
  -H "Authorization: Bearer XXXXXXXXXXXXXXX"

RESPONSE
{
  "punches": [
    {
      "id": 1,
      "visit_id": 1,
      "plan_id": 2,
      "created_at": "2014-09-12T23:14:13Z"
    }
  ]
}

POST /api/v2/desk/punches

Creates a punch.

Show curl example

REQUEST
$ curl -X POST https://mybiz.pike13.com/api/v2/desk/punches \
  -H "Authorization: Bearer XXXXXXXXXXXXXXX" \
  -H "Content-Type: application/json" \
  -d '{"punch": {"visit_id": 1, "plan_id": 2}}'

RESPONSE
{
  "punches": [
    {
      "id": 1,
      "visit_id": 1,
      "plan_id": 2,
      "created_at": "2014-09-12T23:14:13Z"
    }
  ]
}

Attributes

visit_idintegerThe id of the visit. Required.
plan_idintegerThe id of the plan. Optional. If omitted, we will attempt to automatically find a suitable plan.
DELETE /api/v2/desk/punches/:id

Destroys a punch. The associated visit will be become unpaid.

Show curl example

REQUEST
$ curl -X DELETE https://mybiz.pike13.com/api/v2/desk/punches/1 \
  -H "Authorization: Bearer XXXXXXXXXXXXXXX"

RESPONSE