MCPcopy Create free account
hub / github.com/triggerdotdev/trigger.dev / list

Function list

packages/trigger-sdk/src/v3/envvars.ts:76–95  ·  view source on GitHub ↗
(projectRef?: string, slug?: string)

Source from the content-addressed store, hash-verified

74export function list(projectRef: string, slug: string): ApiPromise<EnvironmentVariables>;
75export function list(): ApiPromise<EnvironmentVariables>;
76export function list(projectRef?: string, slug?: string): ApiPromise<EnvironmentVariables> {
77 const $projectRef = projectRef ?? taskContext.ctx?.project.ref;
78 const $slug = slug ?? taskContext.ctx?.environment.slug;
79
80 if (!$projectRef) {
81 throw new Error("projectRef is required");
82 }
83
84 if (!$slug) {
85 throw new Error("slug is required");
86 }
87
88 const apiClient = apiClientManager.client;
89
90 if (!apiClient) {
91 throw apiClientMissingError();
92 }
93
94 return apiClient.listEnvVars($projectRef, $slug);
95}
96
97export function create(
98 projectRef: string,

Callers

nothing calls this directly

Calls 2

apiClientMissingErrorFunction · 0.90
listEnvVarsMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…