The paste.sr.ht API allows you to browse and create pastes on paste.sr.ht programmatically. This API follows the standard sourcehut API conventions.
The paste.sr.ht API allows you to browse and create pastes on paste.sr.ht programmatically. This API follows the standard sourcehut API conventions.
Authentication is done via the meta.sr.ht OAuth flow. The following OAuth scopes are available for paste.sr.ht:
{
"created": "timestamp",
"sha": "id of this paste (SHA-1 hash)",
"user": { short-form user resource },
"visibility": "access level",
"files": [
{
"filename": "filename" or null,
"blob_id": "id of this blob (SHA-1 hash)"
}, ...
]
}
{
"created": "timestamp",
"sha": "id of this blob (SHA-1 hash)",
"contents": "contents of this blob"
}
List of paste resources.
OAuth scope: pastes:read
Create a new paste resource.
OAuth scope: pastes:write
Request body
{
"visibility": "access level",
"files": [
{
"filename": "filename" or null, (optional)
"contents": "contents of this file"
}
]
}
Response
The new paste resource.
Retrieves a paste resource.
OAuth scope: pastes:read
Deletes a paste resource.
OAuth scope: pastes:write
Retrieves a blob resource.
OAuth scope: pastes:read
Webhook for paste events. Includes the standard webhook endpoints
Issued when a new paste is created.
OAuth scope: pastes:read
Issued when a paste is deleted.
OAuth scope: pastes:read
Request body
Affected paste resource.
commit 44d0dd122bcd3eb5217b0d6393e0bf150341b46d Author: Moritz Buhl <git@moritzbuhl.de> Date: 2021-01-16T13:10:13+01:00 update possible OpenBSD 6.8 architectures Source: https://www.openbsd.org/plat.html sgi was retired with 6.7. power64 came with 6.8