@sponson/adapters 0.4.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/algolia.d.ts +6 -0
- package/dist/algolia.js +151 -0
- package/dist/algolia.js.map +1 -0
- package/dist/clerk.js +1 -1
- package/dist/clerk.js.map +1 -1
- package/dist/cloudflare.d.ts +25 -0
- package/dist/cloudflare.js +310 -0
- package/dist/cloudflare.js.map +1 -0
- package/dist/common.d.ts +2 -6
- package/dist/common.js.map +1 -1
- package/dist/digest.d.ts +46 -0
- package/dist/digest.js +129 -0
- package/dist/digest.js.map +1 -0
- package/dist/digitalocean.d.ts +5 -0
- package/dist/digitalocean.js +243 -0
- package/dist/digitalocean.js.map +1 -0
- package/dist/http-adapter-action.d.ts +63 -0
- package/dist/http-adapter-action.js +369 -0
- package/dist/http-adapter-action.js.map +1 -0
- package/dist/http-adapter-auth.d.ts +88 -0
- package/dist/http-adapter-auth.js +437 -0
- package/dist/http-adapter-auth.js.map +1 -0
- package/dist/http-adapter-client.d.ts +51 -0
- package/dist/http-adapter-client.js +156 -0
- package/dist/http-adapter-client.js.map +1 -0
- package/dist/http-adapter-graphql.d.ts +39 -0
- package/dist/http-adapter-graphql.js +157 -0
- package/dist/http-adapter-graphql.js.map +1 -0
- package/dist/http-adapter-list.d.ts +33 -0
- package/dist/http-adapter-list.js +421 -0
- package/dist/http-adapter-list.js.map +1 -0
- package/dist/http-adapter-resource.d.ts +29 -0
- package/dist/http-adapter-resource.js +462 -0
- package/dist/http-adapter-resource.js.map +1 -0
- package/dist/http-adapter-spec.d.ts +216 -0
- package/dist/http-adapter-spec.js +660 -0
- package/dist/http-adapter-spec.js.map +1 -0
- package/dist/http-adapter.d.ts +16 -0
- package/dist/http-adapter.js +28 -0
- package/dist/http-adapter.js.map +1 -0
- package/dist/http.d.ts +61 -2
- package/dist/http.js +79 -18
- package/dist/http.js.map +1 -1
- package/dist/index.d.ts +12 -0
- package/dist/index.js +24 -2
- package/dist/index.js.map +1 -1
- package/dist/launchdarkly.d.ts +15 -0
- package/dist/launchdarkly.js +337 -0
- package/dist/launchdarkly.js.map +1 -0
- package/dist/manual.d.ts +13 -0
- package/dist/manual.js +201 -0
- package/dist/manual.js.map +1 -0
- package/dist/neon.js +1 -1
- package/dist/neon.js.map +1 -1
- package/dist/netlify.d.ts +18 -0
- package/dist/netlify.js +436 -0
- package/dist/netlify.js.map +1 -0
- package/dist/planetscale.d.ts +10 -0
- package/dist/planetscale.js +311 -0
- package/dist/planetscale.js.map +1 -0
- package/dist/providers.d.ts +26 -0
- package/dist/providers.js +36 -0
- package/dist/providers.js.map +1 -0
- package/dist/recipes.d.ts +167 -0
- package/dist/recipes.js +246 -0
- package/dist/recipes.js.map +1 -0
- package/dist/secrets.d.ts +44 -0
- package/dist/secrets.js +279 -0
- package/dist/secrets.js.map +1 -1
- package/dist/sigv4.d.ts +56 -0
- package/dist/sigv4.js +118 -0
- package/dist/sigv4.js.map +1 -0
- package/dist/supabase.d.ts +9 -0
- package/dist/supabase.js +385 -0
- package/dist/supabase.js.map +1 -0
- package/dist/vercel.js +1 -1
- package/dist/vercel.js.map +1 -1
- package/dist/xata.d.ts +8 -0
- package/dist/xata.js +142 -0
- package/dist/xata.js.map +1 -0
- package/dist/xml.d.ts +25 -0
- package/dist/xml.js +211 -0
- package/dist/xml.js.map +1 -0
- package/package.json +11 -4
- package/recipes/amplify.yaml +147 -0
- package/recipes/auth0.yaml +178 -0
- package/recipes/azure_swa.yaml +116 -0
- package/recipes/cloud_run.yaml +97 -0
- package/recipes/cloudflare.yaml +108 -0
- package/recipes/cockroachdb.yaml +132 -0
- package/recipes/configcat.yaml +123 -0
- package/recipes/datadog.yaml +136 -0
- package/recipes/firebase.yaml +84 -0
- package/recipes/flagsmith.yaml +98 -0
- package/recipes/fly.yaml +97 -0
- package/recipes/fly_machines.yaml +67 -0
- package/recipes/gcs.yaml +102 -0
- package/recipes/github.yaml +123 -0
- package/recipes/growthbook.yaml +124 -0
- package/recipes/heroku.yaml +98 -0
- package/recipes/honeycomb.yaml +89 -0
- package/recipes/inngest.yaml +97 -0
- package/recipes/kinde.yaml +120 -0
- package/recipes/mongodb_atlas.yaml +119 -0
- package/recipes/okta.yaml +177 -0
- package/recipes/posthog.yaml +127 -0
- package/recipes/postmark.yaml +105 -0
- package/recipes/postmark_server.yaml +93 -0
- package/recipes/prisma.yaml +150 -0
- package/recipes/qstash.yaml +134 -0
- package/recipes/railway.yaml +130 -0
- package/recipes/render.yaml +103 -0
- package/recipes/resend.yaml +130 -0
- package/recipes/s3.yaml +108 -0
- package/recipes/sendgrid.yaml +165 -0
- package/recipes/sentry.yaml +158 -0
- package/recipes/split.yaml +121 -0
- package/recipes/statsig.yaml +124 -0
- package/recipes/stripe.yaml +310 -0
- package/recipes/stytch.yaml +113 -0
- package/recipes/svix.yaml +109 -0
- package/recipes/turso.yaml +98 -0
- package/recipes/unleash.yaml +149 -0
- package/recipes/upstash.yaml +130 -0
- package/recipes/vercel.yaml +116 -0
- package/recipes/workos.yaml +70 -0
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
# yaml-language-server: $schema=../../../schema/recipe.schema.json
|
|
2
|
+
# Heroku Platform API recipes. Format and checklist: docs/adr/0020-recipes.md, CONTRIBUTING.md "Adding a recipe".
|
|
3
|
+
provider: heroku
|
|
4
|
+
title: Heroku
|
|
5
|
+
category: deploy
|
|
6
|
+
verified_on: "2026-10-11"
|
|
7
|
+
docs:
|
|
8
|
+
- title: Platform API reference (clients, Config Vars, Review App)
|
|
9
|
+
url: https://devcenter.heroku.com/articles/platform-api-reference
|
|
10
|
+
- title: Platform API JSON schema (config-var)
|
|
11
|
+
url: https://api.heroku.com/schema
|
|
12
|
+
- title: Configuration and config vars
|
|
13
|
+
url: https://devcenter.heroku.com/articles/config-vars
|
|
14
|
+
- title: CLI authentication (HEROKU_API_KEY)
|
|
15
|
+
url: https://devcenter.heroku.com/articles/authentication
|
|
16
|
+
api:
|
|
17
|
+
base_url: https://api.heroku.com
|
|
18
|
+
base_url_env: HEROKU_API_URL
|
|
19
|
+
auth: { bearer_env: HEROKU_API_KEY }
|
|
20
|
+
media_type: "application/vnd.heroku+json; version=3"
|
|
21
|
+
detect:
|
|
22
|
+
env: ["HEROKU_*"]
|
|
23
|
+
files: [heroku.yml]
|
|
24
|
+
starter:
|
|
25
|
+
- op: config_var
|
|
26
|
+
where:
|
|
27
|
+
app: "the review app's name (`heroku apps`; by default `<pipeline>-pr-<n>`)"
|
|
28
|
+
assumptions:
|
|
29
|
+
- id: HK1
|
|
30
|
+
verified: true
|
|
31
|
+
text: "Requests authenticate as `Authorization: Bearer <token>`; the Heroku CLI reads the token from `HEROKU_API_KEY`."
|
|
32
|
+
source: https://devcenter.heroku.com/articles/authentication
|
|
33
|
+
- id: HK2
|
|
34
|
+
verified: true
|
|
35
|
+
text: "Every request must send `Accept: application/vnd.heroku+json; version=3`; without it the API refuses the request (documented as 406 `not_acceptable`; a request without it was answered 400 `missing_version` when checked)."
|
|
36
|
+
source: https://devcenter.heroku.com/articles/platform-api-reference
|
|
37
|
+
- id: HK3
|
|
38
|
+
verified: true
|
|
39
|
+
text: "`GET /apps/{app_id_or_name}/config-vars` answers the app's config vars as one flat map of name to string value."
|
|
40
|
+
source: https://devcenter.heroku.com/articles/platform-api-reference
|
|
41
|
+
- id: HK4
|
|
42
|
+
verified: true
|
|
43
|
+
text: "`PATCH /apps/{app_id_or_name}/config-vars` with a map sets the named vars and removes those set to `null`, leaving every other var as it is: one var is written without reading or rewriting the others, so concurrent writers of other vars cannot lose them (no lock needed)."
|
|
44
|
+
source: https://devcenter.heroku.com/articles/platform-api-reference
|
|
45
|
+
- id: HK5
|
|
46
|
+
verified: true
|
|
47
|
+
text: "Config var names match `^\\w+$` and values are strings (`null` only as a delete in a PATCH)."
|
|
48
|
+
source: https://api.heroku.com/schema
|
|
49
|
+
- id: HK6
|
|
50
|
+
verified: true
|
|
51
|
+
text: "Every change to config vars creates a new release and restarts the app, so a write takes effect without a separate deploy."
|
|
52
|
+
source: https://devcenter.heroku.com/articles/config-vars
|
|
53
|
+
- id: HK7
|
|
54
|
+
verified: true
|
|
55
|
+
text: "Review apps are created asynchronously (`POST /review-apps` answers `pending` with a nullable `app`), by Heroku itself when the pipeline has automatic review apps; this recipe does not create them, it writes vars on an app that exists (the review app's name or id)."
|
|
56
|
+
source: https://devcenter.heroku.com/articles/platform-api-reference
|
|
57
|
+
- id: HK9
|
|
58
|
+
verified: false
|
|
59
|
+
text: "A PATCH whose `Content-Type` is the same vendor media type (`media_type` sends it as both `Accept` and `Content-Type`) is accepted like `application/json`; the reference's examples send `application/json`."
|
|
60
|
+
source: https://devcenter.heroku.com/articles/platform-api-reference
|
|
61
|
+
- id: HK8
|
|
62
|
+
verified: false
|
|
63
|
+
text: "A missing app answers 404 `not_found` on GET and PATCH, which destroy treats as the var being gone."
|
|
64
|
+
source: https://devcenter.heroku.com/articles/platform-api-reference
|
|
65
|
+
ops:
|
|
66
|
+
config_var:
|
|
67
|
+
kind: list_item
|
|
68
|
+
title: App config var
|
|
69
|
+
summary: "One config var on a Heroku app, such as a review app's `API_URL`. Written as a merge patch of that one var (`null` deletes it), so other vars, including other scopes', are never rewritten. A console edit of its value is drift; destroy removes only this var. Heroku restarts the app on every change (HK6)."
|
|
70
|
+
covers: [heroku-config-vars]
|
|
71
|
+
params:
|
|
72
|
+
app:
|
|
73
|
+
type: string
|
|
74
|
+
required: true
|
|
75
|
+
description: The app's name or id (a review app's, such as `myapp-pr-42`).
|
|
76
|
+
example: "myapp-${ctx.scope}"
|
|
77
|
+
key:
|
|
78
|
+
type: string
|
|
79
|
+
required: true
|
|
80
|
+
pattern: "^\\w+$"
|
|
81
|
+
description: The config var's name.
|
|
82
|
+
example: API_URL
|
|
83
|
+
value:
|
|
84
|
+
type: string
|
|
85
|
+
required: true
|
|
86
|
+
description: "The value: a literal, `{ from }` or `{ secret }`."
|
|
87
|
+
example: "https://api-${ctx.scope}.example.com"
|
|
88
|
+
http:
|
|
89
|
+
parent: { path: "/apps/{app}/config-vars" }
|
|
90
|
+
list_path: ""
|
|
91
|
+
shape: map
|
|
92
|
+
item: { param: key }
|
|
93
|
+
value: { param: value }
|
|
94
|
+
sim:
|
|
95
|
+
objects:
|
|
96
|
+
"/apps/{app}/config-vars": { DATABASE_URL: "postgres://seeded", LOG_LEVEL: info }
|
|
97
|
+
live:
|
|
98
|
+
params: { app: SPONSON_LIVE_HEROKU_APP }
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# yaml-language-server: $schema=../../../schema/recipe.schema.json
|
|
2
|
+
# Honeycomb API recipes. Format and checklist: docs/adr/0020-recipes.md, CONTRIBUTING.md "Adding a recipe".
|
|
3
|
+
provider: honeycomb
|
|
4
|
+
title: Honeycomb
|
|
5
|
+
category: observability
|
|
6
|
+
verified_on: "2026-10-11"
|
|
7
|
+
docs:
|
|
8
|
+
- title: Create a Marker
|
|
9
|
+
url: https://docs.honeycomb.io/api/markers/create-a-marker
|
|
10
|
+
- title: List All Markers
|
|
11
|
+
url: https://docs.honeycomb.io/api/markers
|
|
12
|
+
- title: Update a Marker
|
|
13
|
+
url: https://docs.honeycomb.io/api/markers/update-a-marker
|
|
14
|
+
- title: Delete a Marker
|
|
15
|
+
url: https://docs.honeycomb.io/api/markers/delete-a-marker
|
|
16
|
+
api:
|
|
17
|
+
base_url: https://api.honeycomb.io
|
|
18
|
+
base_url_env: HONEYCOMB_API_URL
|
|
19
|
+
auth: { header: X-Honeycomb-Team, value_env: HONEYCOMB_API_KEY }
|
|
20
|
+
detect:
|
|
21
|
+
deps: ["@honeycombio/"]
|
|
22
|
+
env: ["HONEYCOMB_*"]
|
|
23
|
+
starter:
|
|
24
|
+
- op: marker
|
|
25
|
+
values: { dataset: __all__, message: "deploy ${ctx.scope} ${ctx.git.sha}" }
|
|
26
|
+
assumptions:
|
|
27
|
+
- id: HC1
|
|
28
|
+
verified: true
|
|
29
|
+
text: "`POST /1/markers/{datasetSlug}` creates a marker from `start_time`, `end_time` (Unix seconds), `message`, `type` and `url` (all optional; `start_time` defaults to the request's arrival), answering 201 with the marker and its `id`; `__all__` as the dataset slug makes an environment-wide marker. Requests carry a Configuration Key with the Manage Markers permission in `X-Honeycomb-Team`."
|
|
30
|
+
source: https://docs.honeycomb.io/api/markers/create-a-marker
|
|
31
|
+
- id: HC2
|
|
32
|
+
verified: true
|
|
33
|
+
text: "`GET /1/markers/{datasetSlug}` answers a bare array of the dataset's markers (`id`, `message`, `type`, `url`, `start_time`, `end_time`, `created_at`, `updated_at`, `color`)."
|
|
34
|
+
source: https://docs.honeycomb.io/api/markers
|
|
35
|
+
- id: HC3
|
|
36
|
+
verified: true
|
|
37
|
+
text: "`PUT /1/markers/{datasetSlug}/{markerId}` replaces the marker: a field left out of the body is erased."
|
|
38
|
+
source: https://docs.honeycomb.io/api/markers/update-a-marker
|
|
39
|
+
- id: HC4
|
|
40
|
+
verified: true
|
|
41
|
+
text: "`DELETE /1/markers/{datasetSlug}/{markerId}` removes the marker and answers it (200)."
|
|
42
|
+
source: https://docs.honeycomb.io/api/markers/delete-a-marker
|
|
43
|
+
- id: HC5
|
|
44
|
+
verified: true
|
|
45
|
+
text: "The API is served from `api.honeycomb.io` (US) and `api.eu1.honeycomb.io` (EU); EU teams set `base_url` in the provider block."
|
|
46
|
+
source: https://docs.honeycomb.io/api/markers/create-a-marker
|
|
47
|
+
- id: HC6
|
|
48
|
+
verified: false
|
|
49
|
+
text: "Message and type identify the marker this recipe created among the dataset's markers (Honeycomb does not require them to be unique: two equal ones make `find` refuse with PARAM_INVALID), and the list holds every marker of the dataset in one answer."
|
|
50
|
+
- id: HC7
|
|
51
|
+
verified: false
|
|
52
|
+
text: "An update (a changed `url`) re-sends message, type and url but not `start_time`, which Honeycomb then sets to the time of the update (HC3), moving the marker; markers are rarely edited."
|
|
53
|
+
- id: HC8
|
|
54
|
+
verified: false
|
|
55
|
+
text: "A deleted marker answers 404 to DELETE, which destroy treats as already gone."
|
|
56
|
+
ops:
|
|
57
|
+
marker:
|
|
58
|
+
kind: resource
|
|
59
|
+
title: Deploy marker
|
|
60
|
+
summary: "A marker on an environment's dataset (or on every dataset of the environment with `__all__`) for a deploy, such as `deploy pr-42 0123abc`. Located by its message and type; a console edit of its URL is drift. Destroying the scope removes it; write `destroy: keep` to keep the deploy history."
|
|
61
|
+
covers: [honeycomb-marker]
|
|
62
|
+
params:
|
|
63
|
+
dataset:
|
|
64
|
+
type: string
|
|
65
|
+
required: true
|
|
66
|
+
description: The dataset's slug, or `__all__` for an environment-wide marker.
|
|
67
|
+
example: __all__
|
|
68
|
+
message:
|
|
69
|
+
type: string
|
|
70
|
+
required: true
|
|
71
|
+
description: The marker's text; with its type, its identity (HC6).
|
|
72
|
+
example: "deploy ${ctx.scope} ${ctx.git.sha}"
|
|
73
|
+
type:
|
|
74
|
+
type: string
|
|
75
|
+
default: deploy
|
|
76
|
+
description: The marker's type, which groups markers (and their color).
|
|
77
|
+
url:
|
|
78
|
+
type: string
|
|
79
|
+
description: The link opened from the marker (the preview or the build).
|
|
80
|
+
example: "https://${ctx.scope}.preview.example.com"
|
|
81
|
+
http:
|
|
82
|
+
find:
|
|
83
|
+
path: "/1/markers/{dataset}"
|
|
84
|
+
match: { message: { param: message }, type: { param: type } }
|
|
85
|
+
create: { path: "/1/markers/{dataset}" }
|
|
86
|
+
update: { method: PUT, path: "/1/markers/{dataset}/{id}" }
|
|
87
|
+
delete: { path: "/1/markers/{dataset}/{id}" }
|
|
88
|
+
fields:
|
|
89
|
+
url: { param: url }
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
# yaml-language-server: $schema=../../../schema/recipe.schema.json
|
|
2
|
+
# Inngest recipes. Format and checklist: docs/adr/0020-recipes.md, docs/adr/0022-one-off-actions.md, CONTRIBUTING.md
|
|
3
|
+
# "Adding a recipe". No API block: the sync is a request to the app's own serve endpoint, which registers itself
|
|
4
|
+
# with Inngest using its own signing key, so Sponson sends no Inngest credential at all.
|
|
5
|
+
provider: inngest
|
|
6
|
+
title: Inngest
|
|
7
|
+
category: queues
|
|
8
|
+
verified_on: "2026-10-11"
|
|
9
|
+
docs:
|
|
10
|
+
- title: Syncing an Inngest app (curl -X PUT on the serve endpoint), Inngest's integration guide
|
|
11
|
+
url: https://www.inngest.com/llm-context.md
|
|
12
|
+
- title: Apps in Inngest Cloud (sync methods, when to sync)
|
|
13
|
+
url: https://www.inngest.com/docs/apps/cloud
|
|
14
|
+
- title: Environments and branch environments
|
|
15
|
+
url: https://www.inngest.com/docs/platform/environments
|
|
16
|
+
- title: The TypeScript SDK's serve handler (InngestCommHandler, PUT = register)
|
|
17
|
+
url: https://github.com/inngest/inngest-js/blob/main/packages/inngest/src/components/InngestCommHandler.ts
|
|
18
|
+
- title: REST API v2 OpenAPI document (V2_SyncApp)
|
|
19
|
+
url: https://api-docs.inngest.com/api-specs/v2.json
|
|
20
|
+
detect:
|
|
21
|
+
deps: [inngest]
|
|
22
|
+
env: ["INNGEST_*"]
|
|
23
|
+
starter:
|
|
24
|
+
- op: sync
|
|
25
|
+
preview_url: url
|
|
26
|
+
values: { revision: "${ctx.git.sha}" }
|
|
27
|
+
assumptions:
|
|
28
|
+
- id: IN1
|
|
29
|
+
verified: true
|
|
30
|
+
text: "A `PUT` to the app's serve endpoint (by convention `/api/inngest`, `curl -X PUT https://your-app.com/api/inngest --fail-with-body`) makes the app's SDK register its functions with Inngest; the SDK authenticates that registration with the app's own `INNGEST_SIGNING_KEY`, so the caller sends no credential."
|
|
31
|
+
source: https://www.inngest.com/llm-context.md
|
|
32
|
+
- id: IN2
|
|
33
|
+
verified: true
|
|
34
|
+
text: "The app registers into the environment its SDK is configured for: `INNGEST_ENV` (or the client's `env` option) names the branch environment and always wins; Vercel's `VERCEL_GIT_COMMIT_REF` is detected automatically, while Netlify, Cloudflare Pages, Railway and Render must pass their branch variable. Sponson does not choose the environment: the app must be configured so."
|
|
35
|
+
source: https://www.inngest.com/docs/platform/environments
|
|
36
|
+
- id: IN3
|
|
37
|
+
verified: true
|
|
38
|
+
text: "A branch environment is created on demand the first time an app syncs with it (or events are sent to it), and every branch environment shares one signing key and one event key, so a preview needs no per-branch key."
|
|
39
|
+
source: https://www.inngest.com/docs/platform/environments
|
|
40
|
+
- id: IN4
|
|
41
|
+
verified: true
|
|
42
|
+
text: "Without `x-inngest-sync-kind: in-band` (which this recipe never sends) the serve handler syncs out of band: it calls Inngest's register endpoint itself and answers with that call's status and a JSON body `{ message, modified }`; a failed registration answers 500 (`Failed to register`)."
|
|
43
|
+
source: https://github.com/inngest/inngest-js/blob/main/packages/inngest/src/components/InngestCommHandler.ts
|
|
44
|
+
- id: IN5
|
|
45
|
+
verified: true
|
|
46
|
+
text: "Sync only once the new version of the code is live: some hosts roll a deploy out over seconds or minutes and an early sync registers the old functions. The recipe's trigger is the deployment's URL (a deploy line's external output, so the line waits for the deploy) and a revision."
|
|
47
|
+
source: https://www.inngest.com/docs/apps/cloud
|
|
48
|
+
- id: IN6
|
|
49
|
+
verified: true
|
|
50
|
+
text: "Branch environments are archived automatically three days after their latest deployment (archiving stops functions from triggering and keeps the data), and archiving cannot be undone per app; there is no request to undo a sync, so destroy sends nothing and forgets the record."
|
|
51
|
+
source: https://www.inngest.com/docs/platform/environments
|
|
52
|
+
- id: IN7
|
|
53
|
+
verified: true
|
|
54
|
+
text: "The REST API's `POST /v2/apps/{appId}/syncs` (marked beta, `x-beta: true`) takes `{ url }` and answers a sync with `status` pending, success, error or duplicate, but the operation declares no header or parameter that selects a branch environment; this recipe does not use it."
|
|
55
|
+
source: https://api-docs.inngest.com/api-specs/v2.json
|
|
56
|
+
- id: IN8
|
|
57
|
+
verified: false
|
|
58
|
+
text: "Syncing the same deployment again is harmless (the same functions registered again, `modified: false`), so the at-least-once delivery of an action (sent again after a crash before it was recorded) needs no idempotency key."
|
|
59
|
+
- id: IN9
|
|
60
|
+
verified: false
|
|
61
|
+
text: "A preview behind Vercel Deployment Protection answers the `PUT` with 401 unless it carries `x-vercel-protection-bypass` with the project's automation bypass secret; pass it with `headers`, as a `{ secret }`."
|
|
62
|
+
ops:
|
|
63
|
+
sync:
|
|
64
|
+
kind: action
|
|
65
|
+
title: App sync into its branch environment
|
|
66
|
+
summary: Registers a preview deployment's Inngest functions by sending `PUT` to its serve endpoint, once per deployment URL and revision; the app's SDK picks the branch environment (`INNGEST_ENV`, IN2) and signs the registration with its own key (IN1), so no Inngest credential is needed.
|
|
67
|
+
covers: [inngest-sync]
|
|
68
|
+
params:
|
|
69
|
+
url:
|
|
70
|
+
type: string
|
|
71
|
+
description: "The deployment's base URL, without a trailing slash: usually `{ from: <deploy line>.preview_url }`, so the sync waits for the deploy (IN5)."
|
|
72
|
+
required: true
|
|
73
|
+
pattern: "^https?://\\S+[^/]$"
|
|
74
|
+
example: https://acme-git-feat-x-acme.vercel.app
|
|
75
|
+
path:
|
|
76
|
+
type: string
|
|
77
|
+
description: Where the app serves Inngest's `serve()` handler, appended to `url`.
|
|
78
|
+
default: /api/inngest
|
|
79
|
+
pattern: "^/\\S*$"
|
|
80
|
+
revision:
|
|
81
|
+
type: string
|
|
82
|
+
description: "What else makes it sync again when it changes, usually the commit: `\"${ctx.git.sha}\"`."
|
|
83
|
+
required: true
|
|
84
|
+
example: "${ctx.git.sha}"
|
|
85
|
+
headers:
|
|
86
|
+
type: map
|
|
87
|
+
description: "Extra request headers, such as `x-vercel-protection-bypass: { secret: env://VERCEL_AUTOMATION_BYPASS_SECRET }` for a protected preview (IN9)."
|
|
88
|
+
http:
|
|
89
|
+
trigger: { url: { param: url }, path: { param: path }, revision: { param: revision } }
|
|
90
|
+
request:
|
|
91
|
+
method: PUT
|
|
92
|
+
url: { join: [{ param: url }, { param: path }] }
|
|
93
|
+
headers: { param: headers }
|
|
94
|
+
outputs: { modified: /modified }
|
|
95
|
+
live:
|
|
96
|
+
# A deployed app with Inngest's serve handler and INNGEST_ENV set to a throwaway branch environment.
|
|
97
|
+
params: { url: SPONSON_LIVE_INNGEST_APP_URL }
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
# yaml-language-server: $schema=../../../schema/recipe.schema.json
|
|
2
|
+
# Kinde Management API recipes. Format and checklist: docs/adr/0020-recipes.md, CONTRIBUTING.md "Adding a recipe".
|
|
3
|
+
provider: kinde
|
|
4
|
+
title: Kinde
|
|
5
|
+
category: auth
|
|
6
|
+
verified_on: "2026-10-11"
|
|
7
|
+
docs:
|
|
8
|
+
- title: Kinde Management API (OpenAPI specification)
|
|
9
|
+
url: https://api-spec.kinde.com/kinde-management-api-spec.yaml
|
|
10
|
+
- title: Access the Kinde Management API
|
|
11
|
+
url: https://docs.kinde.com/developer-tools/kinde-api/connect-to-kinde-api/
|
|
12
|
+
- title: Kinde Management API JS SDK (conventional variable names)
|
|
13
|
+
url: https://github.com/kinde-oss/management-api-js
|
|
14
|
+
api:
|
|
15
|
+
base_url_env: KINDE_API_URL
|
|
16
|
+
auth:
|
|
17
|
+
oauth2_client_credentials:
|
|
18
|
+
token_url: /oauth2/token
|
|
19
|
+
token_url_env: KINDE_TOKEN_URL
|
|
20
|
+
client_id_env: KINDE_MANAGEMENT_CLIENT_ID
|
|
21
|
+
client_secret_env: KINDE_MANAGEMENT_CLIENT_SECRET
|
|
22
|
+
audience: /api
|
|
23
|
+
base_url_example: https://acme.kinde.com/api/v1
|
|
24
|
+
detect:
|
|
25
|
+
deps: ["@kinde-oss/"]
|
|
26
|
+
env: ["KINDE_*"]
|
|
27
|
+
starter:
|
|
28
|
+
- op: callback_url
|
|
29
|
+
- op: logout_url
|
|
30
|
+
preview_url: url
|
|
31
|
+
where:
|
|
32
|
+
base_url: "`https://<business>.kinde.com/api/v1`: Kinde → Settings → Details → Domain"
|
|
33
|
+
app_id: "Kinde → Settings → Applications → your application → Details → Client ID"
|
|
34
|
+
url: "the exact callback URL the SDK sends on a preview: its URL plus the callback path (a `{ from }` reference cannot carry a path)"
|
|
35
|
+
assumptions:
|
|
36
|
+
- id: KI1
|
|
37
|
+
verified: true
|
|
38
|
+
text: "A machine-to-machine application authorized for the Management API gets a token from `POST https://<business>.kinde.com/oauth2/token` (form-encoded `grant_type=client_credentials`, `client_id`, `client_secret`, `audience=https://<business>.kinde.com/api`); API calls go to `https://<business>.kinde.com/api/v1/…`. The recipe writes the token URL and audience as paths, so a plan's `base_url: https://<business>.kinde.com/api/v1` names the business once."
|
|
39
|
+
source: https://docs.kinde.com/developer-tools/kinde-api/connect-to-kinde-api/
|
|
40
|
+
- id: KI2
|
|
41
|
+
verified: true
|
|
42
|
+
text: "`GET /api/v1/applications/{app_id}/auth_redirect_urls` (scope `read:applications_redirect_uris`) answers `{ redirect_urls: [...] }`; `PUT` on the same path (scope `update:applications_redirect_uris`) replaces all of an application's callback URLs with the body's `urls` array. (`POST` adds and `DELETE ?urls=` removes; the recipe replaces the list it read, under a lock, so that one apply is one idempotent write.)"
|
|
43
|
+
source: https://api-spec.kinde.com/kinde-management-api-spec.yaml
|
|
44
|
+
- id: KI3
|
|
45
|
+
verified: true
|
|
46
|
+
text: "`GET /api/v1/applications/{app_id}/auth_logout_urls` answers `{ logout_urls: [...] }` and `PUT` replaces them with the body's `urls` array, as for callback URLs."
|
|
47
|
+
source: https://api-spec.kinde.com/kinde-management-api-spec.yaml
|
|
48
|
+
- id: KI4
|
|
49
|
+
verified: true
|
|
50
|
+
text: "The audience is always the business's kinde.com subdomain (`https://<business>.kinde.com/api`), even when a custom domain serves sign-in, so `base_url` names the kinde.com subdomain."
|
|
51
|
+
source: https://docs.kinde.com/developer-tools/kinde-api/connect-to-kinde-api/
|
|
52
|
+
- id: KI5
|
|
53
|
+
verified: true
|
|
54
|
+
text: "`KINDE_MANAGEMENT_CLIENT_ID` and `KINDE_MANAGEMENT_CLIENT_SECRET` are the variables Kinde's Management API SDK reads for the machine-to-machine client."
|
|
55
|
+
source: https://github.com/kinde-oss/management-api-js
|
|
56
|
+
- id: KI6
|
|
57
|
+
verified: false
|
|
58
|
+
text: "A `PUT` with an empty `urls` list is accepted and leaves the application with no URLs of that kind (destroying the last preview URL of an application that has no others)."
|
|
59
|
+
- id: KI7
|
|
60
|
+
verified: false
|
|
61
|
+
text: "URLs are read back exactly as written (no normalisation), and the replace has no precondition: the line locks the list (`lockOn`) against other Sponson runs; a console edit made between the read and the write can still be lost."
|
|
62
|
+
ops:
|
|
63
|
+
callback_url:
|
|
64
|
+
kind: list_item
|
|
65
|
+
title: Application callback URL
|
|
66
|
+
summary: "One URL in a Kinde application's Allowed callback URLs, such as the preview's `/api/auth/kinde_callback`. Read-modify-write: the list is read (`redirect_urls`) and replaced (`urls`) with the URL added, under a lock on the list; removed on destroy; every other URL is left as it is."
|
|
67
|
+
covers: [kinde-callbacks]
|
|
68
|
+
params:
|
|
69
|
+
app_id:
|
|
70
|
+
type: string
|
|
71
|
+
required: true
|
|
72
|
+
description: The application's id (its Client ID in the Kinde dashboard).
|
|
73
|
+
example: 3b0b5c6c8fcc464fab397f4969b5f482
|
|
74
|
+
url:
|
|
75
|
+
type: string
|
|
76
|
+
required: true
|
|
77
|
+
pattern: "^https?://\\S+$"
|
|
78
|
+
description: "The callback URL, exactly as the SDK sends it (`KINDE_REDIRECT_URL` / `KINDE_SITE_URL` + the callback path)."
|
|
79
|
+
example: "https://${ctx.scope}.preview.example.app/api/auth/kinde_callback"
|
|
80
|
+
http:
|
|
81
|
+
parent:
|
|
82
|
+
path: "/applications/{app_id}/auth_redirect_urls"
|
|
83
|
+
method: PUT
|
|
84
|
+
write_list_path: /urls
|
|
85
|
+
list_path: /redirect_urls
|
|
86
|
+
item: { param: url }
|
|
87
|
+
sim:
|
|
88
|
+
objects:
|
|
89
|
+
"/applications/{app_id}/auth_redirect_urls": { redirect_urls: [https://app.example.com/api/auth/kinde_callback] }
|
|
90
|
+
live:
|
|
91
|
+
params: { app_id: SPONSON_LIVE_KINDE_APP_ID }
|
|
92
|
+
logout_url:
|
|
93
|
+
kind: list_item
|
|
94
|
+
title: Application allowed logout redirect URL
|
|
95
|
+
summary: "One URL in a Kinde application's Allowed logout redirect URLs, such as the preview's home page. Read (`logout_urls`) and replaced (`urls`) with the URL added, under a lock on the list; removed on destroy; every other URL is left as it is."
|
|
96
|
+
covers: [kinde-callbacks]
|
|
97
|
+
params:
|
|
98
|
+
app_id:
|
|
99
|
+
type: string
|
|
100
|
+
required: true
|
|
101
|
+
description: The application's id (its Client ID in the Kinde dashboard).
|
|
102
|
+
example: 3b0b5c6c8fcc464fab397f4969b5f482
|
|
103
|
+
url:
|
|
104
|
+
type: string
|
|
105
|
+
required: true
|
|
106
|
+
pattern: "^https?://\\S+$"
|
|
107
|
+
description: "The URL the SDK redirects to after logout (`KINDE_POST_LOGOUT_REDIRECT_URL`)."
|
|
108
|
+
example: "https://${ctx.scope}.preview.example.app"
|
|
109
|
+
http:
|
|
110
|
+
parent:
|
|
111
|
+
path: "/applications/{app_id}/auth_logout_urls"
|
|
112
|
+
method: PUT
|
|
113
|
+
write_list_path: /urls
|
|
114
|
+
list_path: /logout_urls
|
|
115
|
+
item: { param: url }
|
|
116
|
+
sim:
|
|
117
|
+
objects:
|
|
118
|
+
"/applications/{app_id}/auth_logout_urls": { logout_urls: [https://app.example.com] }
|
|
119
|
+
live:
|
|
120
|
+
params: { app_id: SPONSON_LIVE_KINDE_APP_ID }
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
# yaml-language-server: $schema=../../../schema/recipe.schema.json
|
|
2
|
+
# MongoDB Atlas Administration API v2 recipes (programmatic API keys, HTTP Digest). Format and checklist:
|
|
3
|
+
# docs/adr/0020-recipes.md, CONTRIBUTING.md "Adding a recipe".
|
|
4
|
+
provider: mongodb_atlas
|
|
5
|
+
title: MongoDB Atlas
|
|
6
|
+
category: databases
|
|
7
|
+
verified_on: "2026-10-11"
|
|
8
|
+
docs:
|
|
9
|
+
- title: Atlas Administration API v2 (OpenAPI document)
|
|
10
|
+
url: https://www.mongodb.com/docs/api/doc/atlas-admin-api-v2.json
|
|
11
|
+
- title: Create One Database User in One Project
|
|
12
|
+
url: https://www.mongodb.com/docs/api/doc/atlas-admin-api-v2/operation/operation-creategroupdatabaseuser
|
|
13
|
+
- title: Configure Atlas API access (API keys use HTTP Digest)
|
|
14
|
+
url: https://www.mongodb.com/docs/atlas/configure-api-access/
|
|
15
|
+
- title: Atlas CLI environment variables
|
|
16
|
+
url: https://www.mongodb.com/docs/atlas/cli/current/atlas-cli-env-variables/
|
|
17
|
+
api:
|
|
18
|
+
base_url: https://cloud.mongodb.com/api/atlas/v2
|
|
19
|
+
base_url_env: MONGODB_ATLAS_API_URL
|
|
20
|
+
media_type: application/vnd.atlas.2023-01-01+json
|
|
21
|
+
auth: { digest: { user_env: MONGODB_ATLAS_PUBLIC_API_KEY, password_env: MONGODB_ATLAS_PRIVATE_API_KEY } }
|
|
22
|
+
detect:
|
|
23
|
+
env: ["MONGODB_ATLAS_*"]
|
|
24
|
+
db_hosts: [.mongodb.net]
|
|
25
|
+
starter:
|
|
26
|
+
- op: database_user
|
|
27
|
+
values: { username: "app-${ctx.scope}", roles: [{ databaseName: "app_${ctx.scope}", roleName: readWrite }] }
|
|
28
|
+
where:
|
|
29
|
+
group_id: "Atlas → Project Settings → Project ID, or `atlas projects list`"
|
|
30
|
+
password: "a reference, never a value: `{ secret: \"env://PREVIEW_DB_PASSWORD\" }`"
|
|
31
|
+
assumptions:
|
|
32
|
+
- id: MA1
|
|
33
|
+
verified: true
|
|
34
|
+
text: "Programmatic API keys authenticate with HTTP Digest (the public key as the user name, the private key as the password); service accounts take an OAuth2 client-credentials token instead (`https://cloud.mongodb.com/api/oauth/token`)."
|
|
35
|
+
source: https://www.mongodb.com/docs/atlas/configure-api-access/
|
|
36
|
+
- id: MA2
|
|
37
|
+
verified: true
|
|
38
|
+
text: "The Atlas CLI keeps the key pair in `MONGODB_ATLAS_PUBLIC_API_KEY` and `MONGODB_ATLAS_PRIVATE_API_KEY`."
|
|
39
|
+
source: https://www.mongodb.com/docs/atlas/cli/current/atlas-cli-env-variables/
|
|
40
|
+
- id: MA3
|
|
41
|
+
verified: true
|
|
42
|
+
text: "Requests and answers use the versioned media type `application/vnd.atlas.2023-01-01+json` (in `Accept` and `Content-Type`); the database-user operations are published under that version."
|
|
43
|
+
source: https://www.mongodb.com/docs/api/doc/atlas-admin-api-v2.json
|
|
44
|
+
- id: MA4
|
|
45
|
+
verified: true
|
|
46
|
+
text: "`POST /groups/{groupId}/databaseUsers` creates a user from `databaseName`, `groupId`, `roles` and `username` (required), with `password` for SCRAM users (write-only, never answered), optional `scopes` (absent: every cluster of the project) and `deleteAfterDate` (Atlas deletes the user then; within one week of the request). It answers 201 with the user."
|
|
47
|
+
source: https://www.mongodb.com/docs/api/doc/atlas-admin-api-v2.json
|
|
48
|
+
- id: MA5
|
|
49
|
+
verified: true
|
|
50
|
+
text: "`GET`, `PATCH` and `DELETE /groups/{groupId}/databaseUsers/{databaseName}/{username}` read, update and delete one user; SCRAM users authenticate against `databaseName` `admin`."
|
|
51
|
+
source: https://www.mongodb.com/docs/api/doc/atlas-admin-api-v2.json
|
|
52
|
+
- id: MA6
|
|
53
|
+
verified: true
|
|
54
|
+
text: "A project supports 100 database users by default (900 at most)."
|
|
55
|
+
source: https://www.mongodb.com/docs/api/doc/atlas-admin-api-v2/operation/operation-creategroupdatabaseuser
|
|
56
|
+
- id: MA7
|
|
57
|
+
verified: false
|
|
58
|
+
text: "A GET of a user that does not exist answers 404; a second create of the same user answers 409."
|
|
59
|
+
- id: MA8
|
|
60
|
+
verified: false
|
|
61
|
+
text: "`roles` (each `{ databaseName, roleName, collectionName? }`) and `scopes` (each `{ name, type }`) are answered in the order they were sent, so they compare without drift."
|
|
62
|
+
- id: MA9
|
|
63
|
+
verified: false
|
|
64
|
+
text: "`PATCH` takes the user's identifying fields (`databaseName`, `groupId`, `username`) with the changed ones and keeps the password when none is sent."
|
|
65
|
+
ops:
|
|
66
|
+
database_user:
|
|
67
|
+
kind: resource
|
|
68
|
+
title: Database user
|
|
69
|
+
summary: "A SCRAM database user per scope on a shared Atlas cluster, such as `app-pr-42` with `readWrite` on the database `app_pr_42`, instead of a cluster per preview. The password is an input: a `{ secret: … }` reference (a value per environment in a secret manager) or a sensitive output of another line, sent on create only and never compared. Located by its user name; a console edit of its roles or scopes is drift; destroy deletes the user (not the database's data)."
|
|
70
|
+
covers: [mongodb-atlas-user]
|
|
71
|
+
params:
|
|
72
|
+
group_id:
|
|
73
|
+
type: string
|
|
74
|
+
required: true
|
|
75
|
+
pattern: "^[0-9a-f]{24}$"
|
|
76
|
+
description: The project (group) id, 24 hexadecimal digits.
|
|
77
|
+
example: 32b6e34b3d91647abb20e7b8
|
|
78
|
+
username:
|
|
79
|
+
type: string
|
|
80
|
+
required: true
|
|
81
|
+
description: The user name, unique in the project; its identity.
|
|
82
|
+
example: "app-${ctx.scope}"
|
|
83
|
+
password:
|
|
84
|
+
type: string
|
|
85
|
+
required: true
|
|
86
|
+
description: "The user's password, as a reference (`{ secret: env://… }`, or `{ from: <line>.<output> }` of a sensitive output); sent on create only (MA4)."
|
|
87
|
+
example: { secret: "env://PREVIEW_DB_PASSWORD" }
|
|
88
|
+
roles:
|
|
89
|
+
type: list
|
|
90
|
+
required: true
|
|
91
|
+
description: "The roles, each `{ databaseName, roleName }` (`readWrite`, `read`, `dbAdmin`, …)."
|
|
92
|
+
example: [{ databaseName: "app_${ctx.scope}", roleName: readWrite }]
|
|
93
|
+
scopes:
|
|
94
|
+
type: list
|
|
95
|
+
description: "The clusters it may reach, each `{ name, type: CLUSTER }`; absent: every cluster of the project (not compared then)."
|
|
96
|
+
delete_after:
|
|
97
|
+
type: string
|
|
98
|
+
description: "An ISO 8601 time, within a week, at which Atlas deletes the user by itself (sent on create only)."
|
|
99
|
+
http:
|
|
100
|
+
read: { path: "/groups/{group_id}/databaseUsers/admin/{username}" }
|
|
101
|
+
create:
|
|
102
|
+
path: "/groups/{group_id}/databaseUsers"
|
|
103
|
+
body:
|
|
104
|
+
databaseName: admin
|
|
105
|
+
groupId: { param: group_id }
|
|
106
|
+
username: { param: username }
|
|
107
|
+
password: { param: password }
|
|
108
|
+
deleteAfterDate: { param: delete_after }
|
|
109
|
+
update:
|
|
110
|
+
method: PATCH
|
|
111
|
+
body: { databaseName: admin, groupId: { param: group_id }, username: { param: username } }
|
|
112
|
+
id_path: /username
|
|
113
|
+
fields:
|
|
114
|
+
roles: { param: roles }
|
|
115
|
+
scopes: { param: scopes }
|
|
116
|
+
sim:
|
|
117
|
+
id_from: username
|
|
118
|
+
live:
|
|
119
|
+
params: { group_id: SPONSON_LIVE_ATLAS_GROUP_ID }
|