Posthook Mock Server

Posthook is a service that enables developers to automate and streamline post-receive tasks and processes in their software development workflow. It is commonly used in scenarios where actions need to be triggered automatically after a code repository receives new commits or changes.

The hosted mock server empowers you to effortlessly simulate various Posthook APIs, and doesn't need any authentication/api-key. The setup is straightforward, you can configure the base URL in your code/SDK. You can also control the base URL using environment variables or a feature flag. You don't need any additional dependencies, and you can run the same code in both sandbox and production environments.

Posthook mock server is up and running!

We have set up the mock routes to ensure a smooth adoption. Copy the URL below and set it as the API base URL in your code, and instantly harness the full potential of mocked Posthook APIs.

https://posthook-api.mock.beeceptor.com



200
POST  /v1/hooks
Schedule a Hook
N/A
N/A
{
  "Content-Type": "application/json"
}
{
  "data": {
    "id": "0525baf7-79f9-4991-bb39-6a601ead00e5",
    "path": "/webhooks/ph/event_reminder",
    "data": {
      "eventID": 25
    },
    "postAt": "2018-06-15T21:00:00Z",
    "status": "pending",
    "createdAt": "2018-04-09T20:43:24.321778Z",
    "updatedAt": "2018-04-09T20:43:24.321778Z"
  }
}
200
GET  /v1/hooks
Get Hooks
N/A
N/A
{
  "Content-Type": "application/json"
}
{
  "data": [
    {
      "id": "8e3aa909-fb84-4495-944d-a4c192defe66",
      "path": "/webhooks/ph/event_reminder",
      "domain": "posthook.io",
      "data": {
        "eventID": 25
      },
      "postAt": "2018-07-19T21:00:00Z",
      "status": "pending",
      "createdAt": "2018-04-30T17:45:20.68114Z",
      "updatedAt": "2018-04-30T17:45:20.68114Z"
    },
    {
      "id": "c1ec9560-65fc-4b88-bfe0-1bc6e56cb3db",
      "path": "/webhooks/ph/event_reminder",
      "domain": "posthook.io",
      "data": {
        "eventID": 25
      },
      "postAt": "2018-07-17T21:00:00Z",
      "status": "pending",
      "createdAt": "2018-04-30T17:45:16.097812Z",
      "updatedAt": "2018-04-30T17:45:16.097812Z"
    },
    {
      "id": "6ab4d4d5-4767-452d-b72f-6ec40562b27e",
      "path": "/webhooks/ph/event_reminder",
      "domain": "posthook.io",
      "data": {
        "eventID": 25
      },
      "postAt": "2018-07-15T21:00:00Z",
      "status": "pending",
      "createdAt": "2018-04-30T17:45:06.475047Z",
      "updatedAt": "2018-04-30T17:45:06.475047Z"
    }
  ]
}
200
GET  /v1/hooks/{hook_id}
N/A
N/A
{
  "Content-Type": "application/json"
}
{
  "data": {
    "id": "{{pathParam 'hook_id'}},
    "path": "/webhooks/ph/event_reminder",
    "domain": "posthook.io",
    "data": {
      "eventID": 25
    },
    "postAt": "2018-07-19T21:00:00Z",
    "status": "pending",
    "createdAt": "2018-04-30T17:45:20.68114Z",
    "updatedAt": "2018-04-30T17:45:20.68114Z"
  }
}
200
DELETE  /v1/hooks/{hook_id}
N/A
N/A
{
  "Content-Type": "application/json"
}
{
  "data": {}
}
200
PUT  /v1/projects/
{
  "Content-Type": "application/json"
}
{
    "name": "updated-project",
    "domain": "api.example.com",
    "headerAuthorization": "",
    "minRetries": 1,
    "retryDelaySecs": 5
}
{
  "Content-Type": "application/json"
}
{
    "name": "updated-project",
    "domain": "api.example.com",
    "headerAuthorization": "",
    "minRetries": 1,
    "retryDelaySecs": 5
}
 
scheduler