Skip to content

Zapier Integration

PingDock works with Zapier via Code by Zapier or Webhooks by Zapier.

Code by Zapier

  1. In Zapier, add a Code action.
  2. Choose Python as code language.
  3. Prepare Input Data from previous steps.
  4. Insert code
python
import requests
url = 'https://api.pingdock.io/ping'
json_data = {
      'dock_id': '<Dock ID>', 
      'secret_key': '<Secret Key>',
      'msg': f'{inputData["<You input data name>"]}'}
response = requests.post(url, json=json_data)
return { 'result': response.status_code }
  1. Headers: Content-Type: application/json
  2. Body:
json
{
  "dock_id": "",
  "secret_key": "",
  "msg": "PingDock message from Zapier!"
}

Webhooks by Zapier

  1. In Zapier, add a Webhook action.
  2. Enter URL:
https://api.pingdock.io/ping
  1. Select Payload Type as JSON.
  2. In Data add the following key-value pairs:
dock_id: <Dock ID>
secret_key: <Secret Key>
msg: <Your message or variable from previous steps>