OnRamp supports Webhooks. You can request that OnRamp post a message to a URL of your choosing, whenever an event occurs.
We currently support the following events that can be subscribed to:
Event Name | event_id | Description |
---|---|---|
Add Project | add_project | This event fires whenever a new project is created. |
Edit Project | edit_project | Edit Project is fired whenever a project's settings have been edited. |
Update Sub Task | update_step | As sub tasks are marked as complete, this event fires. |
Add Sub Task | add_task_step | As new sub-tasks are added to tasks, this event will execute. |
Update Task State | update_task_state | When a task's state changes due to a sub-task being completed or the overall task is marked as completed, this event will fire. |
Project Completed | project_completed | When a project's last task is completed and/or when a project is marked as completed this task will fire. |
Project Task Completed | project_task_completed | Whenever a task and all of its required steps are completed, this event will fire. |
Add Project Note | add_project_note | When a note is added to a project, this event will fire |
Edit Project Note | edit_project_note | When a note is updated, this event will fire |
Delete Project Note | delete_project_note | When a note is deleted, this event will fire |
You can start by listing your existing webhooks if you have any
curl --request GET \
--url https://api.onramp.us/v1/admin/webhooks \
--header 'Accept: application/json' \
--header 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE2NTE0ODg1MzYsImlhdCI6MTY1MTQ4NTUzNiwic3ViIjoiZmE2ZjhhZGMtY2I2MS00MzcyLWJiMGItMjU2MWZhMTcxNTk2In0.2vxBOo37ryAAZ-dP3kx37op1hIAVPpCNEFQZm9-BtSc' \
--header 'Content-Type: text/plain'
Which may result in a response similar to
{
"webhooks": [
{
"id": 7370642953,
"address": "https://example.yourdomain.com/",
"topic": "add_project",
"created_at": "2022-02-03"
}
]
}
You can create a new webhook
curl --request POST \
--url http://api.onramp.us/v1/admin/webhook/create \
--header 'Accept: application/json' \
--header 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE2NTE0ODg1MzYsImlhdCI6MTY1MTQ4NTUzNiwic3ViIjoiZmE2ZjhhZGMtY2I2MS00MzcyLWJiMGItMjU2MWZhMTcxNTk2In0.2vxBOo37ryAAZ-dP3kx37op1hIAVPpCNEFQZm9-BtSc' \
--header 'Content-Type: application/json' \
--data '{
"webhook": {
"topic":"add_project",
"address": "https://webhooks.yourdomain.com/onramp",
}
}'