Model
Webhook model is same as API response model in PEAKAPI.CORE
ApiType
ApiType refers to the type of API in PEAKAPI.CORE, where the following ApiTypes will send data via Webhook if an action matches the specified EventTypes.
ApiType / EvenrType | Create | Edit | Void | PaidPayment | VoidPayment |
---|---|---|---|---|---|
ApiQuotation | ✔ | ✔ | ✔ | ||
ApiPurchaseOrder | ✔ | ✔ | ✔ | ||
ApiInvoice | ✔ | ✔ | ✔ | ✔ | ✔ |
ApiExpense | ✔ | ✔ | ✔ | ✔ | ✔ |
ApiReceipt | ✔ | ✔ | ✔ | ||
ApiProduct | ✔ | ✔ | |||
ApiService | ✔ | ✔ | |||
ApiContact | ✔ | ✔ | |||
ApiPaymentMethod | ✔ |
Endpoints
Each ApiType can specify one or more endpoints to which data can be sent. For each ApiType, multiple endpoints is allowed.
example
ApiType | Endpoint |
---|---|
ApiQuotation | {endpoint}/quotation |
ApiPurchaseOrder | {endpoint}/purchaseOrder |
ApiInvoice | {endpoint}/invoice |
ApiExpense | {endpoint}/expense |
ApiReceipt | {endpoint}/receipt |
ApiProduct | {endpoint}/product |
ApiService | {endpoint}/service |
ApiContact | {endpoint}/contact |
ApiPaymentMethod | {endpoint}/paymentMethod |
Header
A custom header key and value can be specified for each endpoint.
example
Key | Value |
---|---|
x-api-key | peak1234 |