/*! * @license * Copyright Squiz Australia Pty Ltd. All Rights Reserved. */ import { AttributeValue } from '@aws-sdk/client-dynamodb'; import { EntityType } from '../../constants/Repository.constants'; /** * Environment interface. * @interface Environment */ export interface Environment { [key: string]: string; } export type RuntimeJobContext = Omit; /** * JobContext interface. * @export * @interface JobContext */ export interface JobContext { /** * The name of the job context. * @type {string} * @memberof JobContext */ contextName: string; /** * The description of the job context. * @type {string} * @memberof JobContext */ description: string; /** * The environment of the job context. * @type {Environment} * @memberof JobContext */ environment: Environment; /** * The DynamoDB record type ('context'). * @type {EntityType} * @memberof JobContext */ type: EntityType; } /** * The Job Context record attributes stored in DynamoDB. * @export * @interface JobContextRecord */ export interface JobContextRecord { /** * The partition key ('context'). * @type {EntityType} * @memberof JobContextRecord */ pk: EntityType; /** * The description of the job context. * @type {string} * @memberof JobContextRecord */ description: string; /** * The sort key ('contextName'). * @type {string} * @memberof JobContextRecord */ sk: string; /** * The environment of the job context. * @type {Environment} * @memberof JobContextRecord */ environment: Environment; } export type JobContextDto = Record; /** * The request body for creating a job context (POST /job-context). * @export */ export type CreateJobContextRequest = Omit; /** * The request body for updating a job context (PATCH /job-context). * @export */ export type UpdateJobContextRequest = Partial>; export type JobContextSk = Pick;