List sources
GET/v1/sourcespreview
List the sources of the app. Deleted sources are left out.
Returns
The query result.200
dataobject[] RequiredSources, newest first.
idstring RequiredA source ID, starting with src_.
namestring RequiredHuman-readable label for the source, such as the provider that sends to it.
1 to 120 characters
urlstring RequiredThe source’s URL without its token. Requests go to this URL followed by / and the token, which is shown only when the source is created or its token rotated.
tokenLast4string RequiredThe last four characters of the token.
defaultTypestring RequiredThe type of every event this source receives, for example billing.webhook.
1 to 64 characters
defaultChannelsstring[] RequiredChannels every event this source receives is addressed to. Empty: the events reach only destinations that list no channel. Stored sorted, without duplicates.
At most 10 items
signedboolean RequiredTrue when every request must carry a valid HMAC signature.
storeUnverifiedboolean RequiredTrue when a request that fails the signature check is stored as an unbuilt event instead of refused. False for a source without a signature.
lastEventAtstring | null RequiredWhen this source last received a request that became an event, to the minute. Null when there is none.
linksobject RequiredLinks for navigating a paginated collection.
nextstring | null RequiredURI reference for the next page, or null at the end.
Example
curl -X GET "https://api.payloadpuffin.com/v1/sources" \
-H "Authorization: Bearer $PAYLOADPUFFIN_API_KEY"{
"data": [
{
"id": "id",
"name": "name",
"url": "url",
"tokenLast4": "tokenLast4",
"defaultType": "defaultType",
"defaultChannels": [
"defaultChannels"
],
"signed": true,
"storeUnverified": true,
"lastEventAt": "lastEventAt"
}
],
"links": {
"next": "next"
}
}Errors
Errors use application/problem+json. The code member is stable; branch on it rather than on title or detail.
4XXapplication/problem+jsonThe request was rejected.