chore: update documentation for sso commands · devhkr/cli@2630c0b · GitHub
Skip to content

Commit 2630c0b

Browse files
committed
chore: update documentation for sso commands
1 parent 42e5cfe commit 2630c0b

4 files changed

Lines changed: 93 additions & 3 deletions

File tree

‎cmd/sso.go‎

Lines changed: 6 additions & 0 deletions

‎docs/supabase/login.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
## supabase-login
22

3-
Connect the Supabase CLI to your Supabase account by logging in with your [personal access token](https://app.supabase.com/account/tokens).
3+
Connect the Supabase CLI to your Supabase account by logging in with your [personal access token](https://supabase.com/dashboard/account/tokens).
44

55
Your access token is stored securely in [native credentials storage](https://github.com/zalando/go-keyring#dependencies). If native credentials storage is unavailable, it will be written to a plain text file at `~/.supabase/access-token`.
66

‎docs/templates/examples.yaml‎

Lines changed: 85 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ supabase-login:
1212
name: Basic usage
1313
code: supabase login
1414
response: |
15-
You can generate an access token from https://app.supabase.com/account/tokens
15+
You can generate an access token from https://supabase.com/dashboard/account/tokens
1616
Enter your access token: sbp_****************************************
1717
Finished supabase login.
1818
supabase-link:
@@ -263,3 +263,87 @@ supabase-test-db:
263263
All tests successful.
264264
Files=2, Tests=2, 6 wallclock secs ( 0.03 usr 0.01 sys + 0.05 cusr 0.02 csys = 0.11 CPU)
265265
Result: PASS
266+
# TODO: use actual cli response for sso commands
267+
supabase-sso-show:
268+
- id: basic-usage
269+
name: Show information
270+
code: |-
271+
supabase sso show 6df4d73f-bf21-405f-a084-b11adf19fea5 \
272+
--project-ref abcdefghijklmnopqrst
273+
response: |-
274+
Information about the identity provider in pretty output.
275+
- id: metadata-output
276+
name: Get raw SAML 2.0 Metadata XML
277+
code: |-
278+
supabase sso show 6df4d73f-bf21-405f-a084-b11adf19fea5 \
279+
--project-ref abcdefghijklmnopqrst \
280+
--metadata
281+
response: |-
282+
Raw SAML 2.0 XML assigned to this identity provider. This is the
283+
version used in the authentication project, and if using a SAML 2.0
284+
Metadata URL it may change depending on the caching information
285+
contained within the metadata.
286+
supabase-sso-update:
287+
- id: basic-usage
288+
name: Replace domains
289+
code: |-
290+
supabase sso update 6df4d73f-bf21-405f-a084-b11adf19fea5 \
291+
--project-ref abcdefghijklmnopqrst \
292+
--domains new-company.com,new-company.net
293+
response: |-
294+
Information about the updated provider.
295+
- id: add-domains
296+
name: Add an additional domain
297+
code: |-
298+
supabase sso update 6df4d73f-bf21-405f-a084-b11adf19fea5 \
299+
--project-ref abcdefghijklmnopqrst \
300+
--add-domains company.net
301+
response: |-
302+
Information about the updated provider.
303+
- id: remove-domains
304+
name: Remove a domain
305+
code: |-
306+
supabase sso update 6df4d73f-bf21-405f-a084-b11adf19fea5 \
307+
--project-ref abcdefghijklmnopqrst \
308+
--remove-domains company.org
309+
response: |-
310+
Information about the updated provider.
311+
supabase-sso-remove:
312+
- id: basic-usage
313+
name: Remove a provider
314+
code: |-
315+
supabase sso remove 6df4d73f-bf21-405f-a084-b11adf19fea5 \
316+
--project-ref abcdefghijklmnopqrst
317+
response: |-
318+
Information about the removed identity provider. It's a good idea to
319+
save this in case you need it later on.
320+
supabase-sso-add:
321+
- id: basic-usage
322+
name: Add with Metadata URL
323+
code: |-
324+
supabase sso add \
325+
--project-ref abcdefgijklmnopqrst \
326+
--type saml \
327+
--metadata-url 'https://...' \
328+
--domains company.com
329+
response: |-
330+
Information about the added identity provider. You can use
331+
company.com as the domain name on the frontend side to initiate a SSO
332+
request to the identity provider.
333+
- id: with-xml
334+
name: Add with Metadata File
335+
code: |-
336+
supabase sso add \
337+
--project-ref abcdefgijklmnopqrst \
338+
--type saml \
339+
--metadata-file /path/to/metadata/file.xml \
340+
--domains company.com
341+
response: |-
342+
Information about the added identity provider. You can use
343+
company.com as the domain name on the frontend side to initiate a SSO
344+
request to the identity provider.
345+
supabase-sso-info:
346+
- id: basic-usage
347+
name: Show project information
348+
code: supabase sso info --project-ref abcdefghijklmnopqrst
349+
response: Information about your project's SAML 2.0 configuration.

‎internal/utils/api.go‎

Lines changed: 1 addition & 1 deletion

0 commit comments

Comments
 (0)