refactor: apply review suggestions
Signed-off-by: Camila Belo <camilaibs@gmail.com>
This commit is contained in:
@@ -40,6 +40,7 @@ export type ActionContext<
|
||||
value: TActionOutput[keyof TActionOutput],
|
||||
): void;
|
||||
createTemporaryDirectory(): Promise<string>;
|
||||
getInitiatorCredentials(): Promise<BackstageCredentials>;
|
||||
templateInfo?: TemplateInfo;
|
||||
isDryRun?: boolean;
|
||||
user?: {
|
||||
@@ -48,7 +49,6 @@ export type ActionContext<
|
||||
};
|
||||
signal?: AbortSignal;
|
||||
each?: JsonObject;
|
||||
getInitiatorCredentials(): Promise<BackstageCredentials>;
|
||||
};
|
||||
|
||||
// @public (undocumented)
|
||||
@@ -351,6 +351,8 @@ export interface TaskContext {
|
||||
// (undocumented)
|
||||
emitLog(message: string, logMetadata?: JsonObject): Promise<void>;
|
||||
// (undocumented)
|
||||
getInitiatorCredentials(): Promise<BackstageCredentials>;
|
||||
// (undocumented)
|
||||
getTaskState?(): Promise<
|
||||
| {
|
||||
state?: JsonObject;
|
||||
@@ -358,8 +360,6 @@ export interface TaskContext {
|
||||
| undefined
|
||||
>;
|
||||
// (undocumented)
|
||||
getInitiatorCredentials(): Promise<BackstageCredentials>;
|
||||
// (undocumented)
|
||||
getWorkspaceName(): Promise<string>;
|
||||
// (undocumented)
|
||||
isDryRun?: boolean;
|
||||
@@ -389,7 +389,6 @@ export type TaskEventType = 'completion' | 'log' | 'cancelled' | 'recovered';
|
||||
// @public
|
||||
export type TaskSecrets = Record<string, string> & {
|
||||
backstageToken?: string;
|
||||
initiatorCredentials?: string;
|
||||
};
|
||||
|
||||
// @public
|
||||
|
||||
@@ -50,6 +50,11 @@ export type ActionContext<
|
||||
*/
|
||||
createTemporaryDirectory(): Promise<string>;
|
||||
|
||||
/**
|
||||
* Get the credentials for the current request
|
||||
*/
|
||||
getInitiatorCredentials(): Promise<BackstageCredentials>;
|
||||
|
||||
templateInfo?: TemplateInfo;
|
||||
|
||||
/**
|
||||
@@ -81,11 +86,6 @@ export type ActionContext<
|
||||
* Optional value of each invocation
|
||||
*/
|
||||
each?: JsonObject;
|
||||
|
||||
/**
|
||||
* Get the credentials for the current request
|
||||
*/
|
||||
getInitiatorCredentials(): Promise<BackstageCredentials>;
|
||||
};
|
||||
|
||||
/** @public */
|
||||
|
||||
@@ -24,11 +24,7 @@ import { JsonObject, JsonValue, Observable } from '@backstage/types';
|
||||
* @public
|
||||
*/
|
||||
export type TaskSecrets = Record<string, string> & {
|
||||
/**
|
||||
* @deprecated use "initiatorCredentials" instead
|
||||
*/
|
||||
backstageToken?: string;
|
||||
initiatorCredentials?: string;
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user