- Updated references. - Added proposal `type`. - Updated `discussionsTo`. Reviewed-on: https://codeberg.org/fediverse/fep/pulls/619 Co-authored-by: silverpill <silverpill@firemail.cc> Co-committed-by: silverpill <silverpill@firemail.cc>
3.8 KiB
slug, authors, type, status, dateReceived, trackingIssue, discussionsTo
| slug | authors | type | status | dateReceived | trackingIssue | discussionsTo |
|---|---|---|---|---|---|---|
| 0ea0 | silverpill <@silverpill@mitra.social> | implementation | DRAFT | 2023-04-18 | https://codeberg.org/fediverse/fep/issues/88 | https://socialhub.activitypub.rocks/t/fep-0ea0-payment-links/3121 |
FEP-0ea0: Payment Links
Summary
This FEP describes a way to attach payment information to ActivityPub actors and objects. That information might be a link to donation page, a link for buying an artwork, or anything else that can be represented with a URI.
History
PeerTube videos may have support property, which contains a text explaining how to support the content creator.
FEP-8c3f: Web Monetization was published in 2022. The ensuing discussion on SocialHub forum led to the creation of this proposal.
Requirements
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC-2119.
Payment links
Payment link is an object with the following properties:
type(REQUIRED): the type MUST beLink.name(RECOMMENDED): thenameproperty SHOULD contain a human-readable description of the payment link.href(REQUIRED): thehrefproperty MUST contain a payment URI. This can be a URL of a website, or any other kind of URI, such as 'payto' URI.rel(REQUIRED): therelproperty MUST contain the stringpaymentor an array containing that string. Thepaymentrelation type is defined in Link Relations Registry.
Payment links MUST be added to attachment array of an actor or an object.
Examples
Payment link attached to an actor:
{
"@context": "https://www.w3.org/ns/activitystreams",
"type": "Person",
"id": "https://social.example/users/alice",
"inbox": "https://social.example/users/alice/inbox",
"outbox": "https://social.example/users/alice/outbox",
"attachment": [
{
"type": "Link",
"name": "Donate",
"href": "payto://iban/DE75512108001245126199",
"rel": "payment"
}
]
}
Payment link attached to an object:
{
"@context": "https://www.w3.org/ns/activitystreams",
"type": "Image",
"id": "https://gallery.example/photos/123",
"attributedTo": "https://gallery.example/users/alice",
"name": "Painting of a cat",
"attachment": [
{
"type": "Link",
"name": "Buy",
"href": "https://gallery.example/photos/123/order",
"rel": [
"payment",
"https://gallery.example/ns#buy"
]
}
]
}
Payment links as actor metadata
(This section is non-normative.)
Implementers may treat payment links attached to actor object in the same way as actor metadata fields. In that case, name translates into field label and href translates into field value.
References
- Christine Lemmer-Webber, Jessica Tallon, Erin Shepherd, Amy Guy, Evan Prodromou, ActivityPub, 2018
- Diogo Peralta Cordeiro, Phablulo Joel, FEP-8c3f: Web Monetization, 2022
- S. Bradner, Key words for use in RFCs to Indicate Requirement Levels, 1997
- F. Dold, C. Grothoff, The 'payto' URI Scheme for Payments, 2020
- IANA, Link Relations, 2005
Copyright
CC0 1.0 Universal (CC0 1.0) Public Domain Dedication
To the extent possible under law, the authors of this Fediverse Enhancement Proposal have waived all copyright and related or neighboring rights to this work.