g1t/apps/sudo/app/lib/services.server.ts

34 lines1,283 bytesCodeBlame

Pick any line to see why it is the way it is: the commit, the pull request and issue it came from, and what the agent was thinking.

Billing accounts, terms and enterprises; g1t is no longer free1import { env } from "cloudflare:workers";
2
status.g1t.sh with incident management, invites that land you in the workspace, settings as pages, usage without quotas3import {
4 type StatusAdminApi,
5 accountsAdminClient,
6 billingAdminClient,
7 billingClient,
8 eventsClient,
9 identityAdminClient,
10} from "@g1t/contracts";
Billing accounts, terms and enterprises; g1t is no longer free11
12/** Staff-only billing, on the billing service. */
13export const admin = billingAdminClient(env.BILLING);
Billing on Stripe's pages, month-end charges, warnings; sudo by workspace14
A menu shaped by how g1t works, Soon pages for every promise, and sudo for sales15/** The public price book, read-only, from the same service. */
16export const priceBook = () => billingClient(env.BILLING).prices();
17
Billing on Stripe's pages, month-end charges, warnings; sudo by workspace18/** Staff-only identity: every workspace, its owners and members. */
19export const identity = identityAdminClient(env.IDENTITY);
Invite-only launch: sign in with GitHub, repository access and lifecycle, many emails, a new look20
21/** Staff-only accounts: a person's email addresses and security log. */
22export const accountsAdmin = accountsAdminClient(env.IDENTITY);
23
24/** The workspace's plan, caps and pause, as billing gives them to every service. */
25export const entitlements = (workspace: string) => billingClient(env.BILLING).entitlements(workspace);
26
27/** The event log, read-only: sudo lists `abuse.flagged`. */
28export const events = eventsClient(env.EVENTS);
status.g1t.sh with incident management, invites that land you in the workspace, settings as pages, usage without quotas29
30/** The status page's incidents (apps/status's `StatusAdmin` entrypoint). */
31export const statusAdmin = env.STATUS as unknown as StatusAdminApi;
32
33/** STAFF_EMAILS, for suggesting staff in the incident roles. */
34export const staffEmails = (): string => env.STAFF_EMAILS ?? "";