Skip to content

Commit c9fbc27

Browse files
committed
update wordings
1 parent 822f0d0 commit c9fbc27

6 files changed

Lines changed: 27 additions & 8 deletions

File tree

content/3.api-v2/1.introduction.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,21 @@ Welcome to FreeStuff's second iteration on our api. Api v2 can do everything v1
99
- Streamlined the data obtaining process
1010
- Built on web standards. See [Standard Webhooks](https://github.com/standard-webhooks/standard-webhooks/blob/main/spec/standard-webhooks.md), [Problem JSON](https://datatracker.ietf.org/doc/html/rfc7807), and more
1111
- Introduction of compatibility dates for seamless api versioning
12-
- Introduction of a free tier. See pricing for more details
12+
- Introduction of a free tier
1313

1414

1515
## Pricing
1616

17-
FreeStuff's api comes in two tiers.
17+
FreeStuff's api comes in two basic tiers.
1818

1919
| | Free Tier | Full Tier |
2020
|-----------------------|--------------------------------------------|-------------------------------------------------|
21-
| Price | $0 | $2.99/mo |
21+
| Price | $0 | $2.99/mo¹ |
2222
| Channels | 100% Discount, Free Weekend, DLCs & More | All Channels, including Prime Gaming |
2323
| Data | Partial data, no metadata, reduced assets | Full data, see documentation for more details |
2424
| Interface | Webhooks only | Webhooks + REST Api |
25+
| Commercial use | Prohibited² | Prohibited² |
26+
27+
¹ This price is without guarantee. For the actual binding price please check your dashboard.
28+
29+
² There is an additional commercial tier for if you want to use FreeStuff's API or Data in a commercial setting. Please contact us for more information.

content/3.api-v2/2.concepts.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ Additionally a product has some basic properties like a title, assets (logos, im
1313

1414
Each product has a kind as described earlier. This value describes what kind of product it is. Usually it's a **game**, but others like **dlc** or **loot** for game pass or prime gaming are also possible. FreeStuff also has more types like **art**, **ost**, or **other** which are currently unused.
1515

16+
The Data Models below show compatibility date `2025-03-01`. Newer versions might differ in details.
17+
1618
:data-model{name="Product"}
1719
:data-model{name="PartialProduct"}
1820
:data-model{name="ProductPrice"}

content/3.api-v2/3.usage-and-auth.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Usage & Auth
22

3+
::alert{type="info"}
4+
If you are on the free tier and do not have access to the REST Api you can skip this page.
5+
::
6+
37
## Base Url
48

59
All endpoints are available on `https://api.freestuffbot.xyz/v2`

content/3.api-v2/4.endpoints.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Endpoints
22

3+
::alert{type="info"}
4+
If you are on the free tier and do not have access to the REST Api you can skip this page.
5+
::
6+
37
:endpoint{name="get-ping"}
48

59
:endpoint{name="get-products"}

content/3.api-v2/5.webhooks.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ The message payload (http body) follows the [Standard Webhooks Spec](https://git
99

1010
```jsonc
1111
{
12-
"type": "urn:fsb:event:announcement.publish",
12+
"type": "fsb:event:announcement.publish",
1313
"timestamp": "2022-11-03T20:26:10.344522Z",
1414
"data": {
1515
// ...
@@ -41,6 +41,10 @@ FreeStuff signs every webhook request as per [Standard Webhooks Spec](https://gi
4141
- Make sure to ignore requests with an old `Webhook-Timestamp` value
4242
- Make sure to use the payload body `timestamp` field as the contextual timestamp and use the header only for verification
4343

44+
::alert{type="info"}
45+
If you are not using a library to verify the request for you and you are not interested in implementing the verification yourself, we recommend you pick a long and unguessable url for your webhook to prevent abuse.
46+
::
47+
4448

4549
## Resends
4650

@@ -67,7 +71,7 @@ FreeStuff attempts to resend failed deliveries as per [Standard Webhooks Spec](h
6771

6872
## Event List
6973

70-
### urn:fsb:event:ping
74+
### fsb:event:ping
7175

7276
Fired either when the ping button was pressed on your dashboard or periodically to check if your webhook is still operational.
7377

@@ -80,7 +84,7 @@ The `data` field will contain the following object:
8084
```
8185

8286

83-
### urn:fsb:event:announcement_published
87+
### fsb:event:announcement-created
8488

8589
Fired when a new announcement is published.
8690

@@ -89,7 +93,7 @@ The `data` field will contain a single `ResolvedAnnouncement`. Check it's `resol
8993
:data-model{name="ResolvedAnnouncement"}
9094

9195

92-
### urn:fsb:event:product_updated
96+
### fsb:event:product-updated
9397

9498
Fired when a previously published product is updated.
9599

data/api-v2.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"@": {
44
"generic-error": {
55
"body": {
6-
"type": "urn:fsb:problem:name-here",
6+
"type": "fsb:problem:name-here",
77
"title": "error name",
88
"detail": "error message"
99
},

0 commit comments

Comments
 (0)