Skip to content

Commit aeb2391

Browse files
authored
feat: add new is_one_time and is_custom_ammount to SponsorshipTier (#431)
1 parent 08a1a17 commit aeb2391

File tree

6 files changed

+38
-12
lines changed

6 files changed

+38
-12
lines changed

cache/webhook-events-and-payloads.html

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12447,7 +12447,9 @@ <h4 id="webhook-payload-example-when-someone-creates-a-sponsorship">
1244712447
<span class="hljs-attr">"description"</span>: <span class="hljs-string">"foo"</span>,
1244812448
<span class="hljs-attr">"monthly_price_in_cents"</span>: <span class="hljs-number">500</span>,
1244912449
<span class="hljs-attr">"monthly_price_in_dollars"</span>: <span class="hljs-number">5</span>,
12450-
<span class="hljs-attr">"name"</span>: <span class="hljs-string">"$5 a month"</span>
12450+
<span class="hljs-attr">"name"</span>: <span class="hljs-string">"$5 a month"</span>,
12451+
<span class="hljs-attr">"is_one_time"</span>: <span class="hljs-literal">false</span>,
12452+
<span class="hljs-attr">"is_custom_amount"</span>: <span class="hljs-literal">false</span>
1245112453
}
1245212454
},
1245312455
<span class="hljs-attr">"sender"</span>: {
@@ -12531,7 +12533,9 @@ <h4 id="webhook-payload-example-when-someone-downgrades-a-sponsorship">
1253112533
<span class="hljs-attr">"description"</span>: <span class="hljs-string">"foo"</span>,
1253212534
<span class="hljs-attr">"monthly_price_in_cents"</span>: <span class="hljs-number">500</span>,
1253312535
<span class="hljs-attr">"monthly_price_in_dollars"</span>: <span class="hljs-number">5</span>,
12534-
<span class="hljs-attr">"name"</span>: <span class="hljs-string">"$5 a month"</span>
12536+
<span class="hljs-attr">"name"</span>: <span class="hljs-string">"$5 a month"</span>,
12537+
<span class="hljs-attr">"is_one_time"</span>: <span class="hljs-literal">false</span>,
12538+
<span class="hljs-attr">"is_custom_amount"</span>: <span class="hljs-literal">false</span>
1253512539
}
1253612540
},
1253712541
<span class="hljs-attr">"changes"</span>: {

index.json

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -53300,7 +53300,9 @@
5330053300
"description": "foo",
5330153301
"monthly_price_in_cents": 500,
5330253302
"monthly_price_in_dollars": 5,
53303-
"name": "$5 a month"
53303+
"name": "$5 a month",
53304+
"is_one_time": false,
53305+
"is_custom_amount": false
5330453306
}
5330553307
},
5330653308
"sender": {
@@ -53376,7 +53378,9 @@
5337653378
"description": "foo",
5337753379
"monthly_price_in_cents": 500,
5337853380
"monthly_price_in_dollars": 5,
53379-
"name": "$5 a month"
53381+
"name": "$5 a month",
53382+
"is_one_time": false,
53383+
"is_custom_amount": false
5338053384
}
5338153385
},
5338253386
"changes": {
@@ -53465,7 +53469,9 @@
5346553469
"description": "foo",
5346653470
"monthly_price_in_cents": 500,
5346753471
"monthly_price_in_dollars": 5,
53468-
"name": "$5 a month"
53472+
"name": "$5 a month",
53473+
"is_one_time": false,
53474+
"is_custom_ammount": false
5346953475
}
5347053476
},
5347153477
"sender": {
@@ -53541,7 +53547,9 @@
5354153547
"description": "foo",
5354253548
"monthly_price_in_cents": 500,
5354353549
"monthly_price_in_dollars": 5,
53544-
"name": "$5 a month"
53550+
"name": "$5 a month",
53551+
"is_one_time": false,
53552+
"is_custom_ammount": false
5354553553
}
5354653554
},
5354753555
"changes": {
@@ -53552,7 +53560,9 @@
5355253560
"description": "bar",
5355353561
"monthly_price_in_cents": 1000,
5355453562
"monthly_price_in_dollars": 10,
53555-
"name": "$10 a month"
53563+
"name": "$10 a month",
53564+
"is_one_time": false,
53565+
"is_custom_ammount": false
5355653566
}
5355753567
}
5355853568
},

payload-examples/api.github.com/sponsorship/created.payload.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,9 @@
5050
"description": "foo",
5151
"monthly_price_in_cents": 500,
5252
"monthly_price_in_dollars": 5,
53-
"name": "$5 a month"
53+
"name": "$5 a month",
54+
"is_one_time": false,
55+
"is_custom_ammount": false
5456
}
5557
},
5658
"sender": {

payload-examples/api.github.com/sponsorship/downgraded.payload.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,9 @@
5050
"description": "foo",
5151
"monthly_price_in_cents": 500,
5252
"monthly_price_in_dollars": 5,
53-
"name": "$5 a month"
53+
"name": "$5 a month",
54+
"is_one_time": false,
55+
"is_custom_ammount": false
5456
}
5557
},
5658
"changes": {
@@ -61,7 +63,9 @@
6163
"description": "bar",
6264
"monthly_price_in_cents": 1000,
6365
"monthly_price_in_dollars": 10,
64-
"name": "$10 a month"
66+
"name": "$10 a month",
67+
"is_one_time": false,
68+
"is_custom_ammount": false
6569
}
6670
}
6771
},

payload-schemas/schemas/common/sponsorship-tier.schema.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,9 @@
88
"description",
99
"monthly_price_in_cents",
1010
"monthly_price_in_dollars",
11-
"name"
11+
"name",
12+
"is_one_time",
13+
"is_custom_ammount"
1214
],
1315
"type": "object",
1416
"properties": {
@@ -17,7 +19,9 @@
1719
"description": { "type": "string" },
1820
"monthly_price_in_cents": { "type": "integer" },
1921
"monthly_price_in_dollars": { "type": "integer" },
20-
"name": { "type": "string" }
22+
"name": { "type": "string" },
23+
"is_one_time": { "type": "boolean" },
24+
"is_custom_ammount": { "type": "boolean" }
2125
},
2226
"additionalProperties": false,
2327
"title": "Sponsorship Tier"

schema.d.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5526,6 +5526,8 @@ export interface SponsorshipTier {
55265526
monthly_price_in_cents: number;
55275527
monthly_price_in_dollars: number;
55285528
name: string;
5529+
is_one_time: boolean;
5530+
is_custom_ammount: boolean;
55295531
}
55305532
export interface SponsorshipCreatedEvent {
55315533
action: "created";

0 commit comments

Comments
 (0)