Generate Scaffolder OpenAPI server
Signed-off-by: solimant <solimant@users.noreply.github.com>
This commit is contained in:
@@ -21,7 +21,12 @@ import { PathTemplate, ValueOf } from './common';
|
||||
*/
|
||||
export type EndpointMap = Record<
|
||||
string,
|
||||
{ query?: object; body?: object; response?: object | void; path?: object }
|
||||
{
|
||||
query?: object;
|
||||
body?: object;
|
||||
response?: object | string | void;
|
||||
path?: object;
|
||||
}
|
||||
>;
|
||||
|
||||
// OpenAPI generator doesn't emit regular lowercase 'delete'.
|
||||
|
||||
@@ -54,6 +54,7 @@
|
||||
"build": "backstage-cli package build",
|
||||
"build:assets": "node scripts/build-nunjucks.js",
|
||||
"clean": "backstage-cli package clean",
|
||||
"generate": "backstage-repo-tools package schema openapi generate --server",
|
||||
"lint": "backstage-cli package lint",
|
||||
"prepack": "backstage-cli package prepack",
|
||||
"postpack": "backstage-cli package postpack",
|
||||
@@ -62,6 +63,7 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@backstage/backend-defaults": "workspace:^",
|
||||
"@backstage/backend-openapi-utils": "workspace:^",
|
||||
"@backstage/backend-plugin-api": "workspace:^",
|
||||
"@backstage/catalog-model": "workspace:^",
|
||||
"@backstage/config": "workspace:^",
|
||||
@@ -89,7 +91,6 @@
|
||||
"@types/luxon": "^3.0.0",
|
||||
"concat-stream": "^2.0.0",
|
||||
"express": "^4.17.1",
|
||||
"express-promise-router": "^4.1.0",
|
||||
"fs-extra": "^11.2.0",
|
||||
"globby": "^11.0.0",
|
||||
"isbinaryfile": "^5.0.0",
|
||||
|
||||
@@ -13,6 +13,14 @@ components:
|
||||
examples: {}
|
||||
headers: {}
|
||||
parameters:
|
||||
createdBy:
|
||||
name: createdBy
|
||||
in: query
|
||||
description: Created by
|
||||
required: false
|
||||
allowReserved: true
|
||||
schema:
|
||||
type: string
|
||||
eventsAfter:
|
||||
name: after
|
||||
in: query
|
||||
@@ -26,6 +34,15 @@ components:
|
||||
allowReserved: true
|
||||
schema:
|
||||
type: string
|
||||
limit:
|
||||
name: limit
|
||||
in: query
|
||||
description: Number of records to return in the response.
|
||||
required: false
|
||||
allowReserved: true
|
||||
schema:
|
||||
type: integer
|
||||
minimum: 0
|
||||
namespace:
|
||||
name: namespace
|
||||
in: path
|
||||
@@ -40,6 +57,34 @@ components:
|
||||
allowReserved: true
|
||||
schema:
|
||||
type: string
|
||||
offset:
|
||||
name: offset
|
||||
in: query
|
||||
description: Number of records to skip in the query page.
|
||||
required: false
|
||||
allowReserved: true
|
||||
schema:
|
||||
type: integer
|
||||
minimum: 0
|
||||
order:
|
||||
name: order
|
||||
in: query
|
||||
description: Order
|
||||
required: false
|
||||
allowReserved: true
|
||||
schema:
|
||||
type: string
|
||||
enum:
|
||||
- asc
|
||||
- desc
|
||||
status:
|
||||
name: status
|
||||
in: query
|
||||
description: Status
|
||||
required: false
|
||||
allowReserved: true
|
||||
schema:
|
||||
type: string
|
||||
taskId:
|
||||
name: taskId
|
||||
in: path
|
||||
@@ -55,62 +100,6 @@ components:
|
||||
application/json; charset=utf-8:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Error'
|
||||
ValidationError:
|
||||
description: Validation errors.
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
errors:
|
||||
type: array
|
||||
items:
|
||||
type: object
|
||||
properties:
|
||||
path:
|
||||
type: array
|
||||
items:
|
||||
oneOf:
|
||||
- type: string
|
||||
- type: integer
|
||||
property:
|
||||
type: string
|
||||
schema:
|
||||
$ref: '#/components/schemas/Schema'
|
||||
stack:
|
||||
type: string
|
||||
instance:
|
||||
oneOf:
|
||||
- type: string
|
||||
- type: number
|
||||
- type: boolean
|
||||
- type: array
|
||||
- type: object
|
||||
nullable: true
|
||||
argument:
|
||||
oneOf:
|
||||
- type: string
|
||||
- type: number
|
||||
- type: boolean
|
||||
- type: array
|
||||
- type: object
|
||||
nullable: true
|
||||
name:
|
||||
type: string
|
||||
message:
|
||||
type: string
|
||||
required:
|
||||
- path
|
||||
- property
|
||||
- schema
|
||||
- instance
|
||||
- name
|
||||
- message
|
||||
- argument
|
||||
- stack
|
||||
additionalProperties: {}
|
||||
required:
|
||||
- errors
|
||||
schemas:
|
||||
Action:
|
||||
type: object
|
||||
@@ -160,6 +149,143 @@ components:
|
||||
$ref: '#/components/schemas/SerializedFile'
|
||||
output:
|
||||
$ref: '#/components/schemas/JsonObject'
|
||||
required:
|
||||
- log
|
||||
- directoryContents
|
||||
- output
|
||||
EntityLink:
|
||||
type: object
|
||||
properties:
|
||||
type:
|
||||
type: string
|
||||
description: An optional value to categorize links into specific groups
|
||||
icon:
|
||||
type: string
|
||||
description: An optional semantic key that represents a visual icon.
|
||||
title:
|
||||
type: string
|
||||
description: An optional descriptive title for the link.
|
||||
url:
|
||||
type: string
|
||||
description: The url to the external site, document, etc.
|
||||
required:
|
||||
- url
|
||||
description: A link to external information that is related to the entity.
|
||||
additionalProperties: false
|
||||
EntityMeta:
|
||||
type: object
|
||||
properties:
|
||||
links:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/components/schemas/EntityLink'
|
||||
description: A list of external hyperlinks related to the entity.
|
||||
tags:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
description: |-
|
||||
A list of single-valued strings, to for example classify catalog entities in
|
||||
various ways.
|
||||
annotations:
|
||||
$ref: '#/components/schemas/MapStringString'
|
||||
labels:
|
||||
$ref: '#/components/schemas/MapStringString'
|
||||
description:
|
||||
type: string
|
||||
description: |-
|
||||
A short (typically relatively few words, on one line) description of the
|
||||
entity.
|
||||
title:
|
||||
type: string
|
||||
description: |-
|
||||
A display name of the entity, to be presented in user interfaces instead
|
||||
of the `name` property above, when available.
|
||||
This field is sometimes useful when the `name` is cumbersome or ends up
|
||||
being perceived as overly technical. The title generally does not have
|
||||
as stringent format requirements on it, so it may contain special
|
||||
characters and be more explanatory. Do keep it very short though, and
|
||||
avoid situations where a title can be confused with the name of another
|
||||
entity, or where two entities share a title.
|
||||
Note that this is only for display purposes, and may be ignored by some
|
||||
parts of the code. Entity references still always make use of the `name`
|
||||
property, not the title.
|
||||
namespace:
|
||||
type: string
|
||||
description: The namespace that the entity belongs to.
|
||||
name:
|
||||
type: string
|
||||
description: |-
|
||||
The name of the entity.
|
||||
Must be unique within the catalog at any given point in time, for any
|
||||
given namespace + kind pair. This value is part of the technical
|
||||
identifier of the entity, and as such it will appear in URLs, database
|
||||
tables, entity references, and similar. It is subject to restrictions
|
||||
regarding what characters are allowed.
|
||||
If you want to use a different, more human readable string with fewer
|
||||
restrictions on it in user interfaces, see the `title` field below.
|
||||
etag:
|
||||
type: string
|
||||
description: |-
|
||||
An opaque string that changes for each update operation to any part of
|
||||
the entity, including metadata.
|
||||
This field can not be set by the user at creation time, and the server
|
||||
will reject an attempt to do so. The field will be populated in read
|
||||
operations. The field can (optionally) be specified when performing
|
||||
update or delete operations, and the server will then reject the
|
||||
operation if it does not match the current stored value.
|
||||
uid:
|
||||
type: string
|
||||
description: |-
|
||||
A globally unique ID for the entity.
|
||||
This field can not be set by the user at creation time, and the server
|
||||
will reject an attempt to do so. The field will be populated in read
|
||||
operations. The field can (optionally) be specified when performing
|
||||
update or delete operations, but the server is free to reject requests
|
||||
that do so in such a way that it breaks semantics.
|
||||
required:
|
||||
- name
|
||||
description: Metadata fields common to all versions/kinds of entity.
|
||||
additionalProperties: {}
|
||||
EntityRelation:
|
||||
type: object
|
||||
properties:
|
||||
targetRef:
|
||||
type: string
|
||||
description: The entity ref of the target of this relation.
|
||||
type:
|
||||
type: string
|
||||
description: The type of the relation.
|
||||
required:
|
||||
- targetRef
|
||||
- type
|
||||
description: A relation of a specific type to another entity in the catalog.
|
||||
additionalProperties: false
|
||||
Entity:
|
||||
type: object
|
||||
properties:
|
||||
relations:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/components/schemas/EntityRelation'
|
||||
description: The relations that this entity has with other entities.
|
||||
spec:
|
||||
$ref: '#/components/schemas/JsonObject'
|
||||
metadata:
|
||||
$ref: '#/components/schemas/EntityMeta'
|
||||
kind:
|
||||
type: string
|
||||
description: The high level entity type being described.
|
||||
apiVersion:
|
||||
type: string
|
||||
description: |-
|
||||
The version of specification format for this particular entity that
|
||||
this is written against.
|
||||
required:
|
||||
- metadata
|
||||
- kind
|
||||
- apiVersion
|
||||
description: The parts of the format that's common to all versions/kinds of entity.
|
||||
Error:
|
||||
type: object
|
||||
properties:
|
||||
@@ -210,10 +336,10 @@ components:
|
||||
additionalProperties: {}
|
||||
JsonPrimitive:
|
||||
oneOf:
|
||||
- type: boolean
|
||||
- type: number
|
||||
- type: string
|
||||
- type: boolean
|
||||
- type: null
|
||||
- nullable: true
|
||||
description: A type representing all allowed JSON primitive values.
|
||||
JsonValue:
|
||||
oneOf:
|
||||
@@ -234,43 +360,12 @@ components:
|
||||
items:
|
||||
$ref: '#/components/schemas/SerializedTask'
|
||||
description: The response shape for the `listTasks` call to the `scaffolder-backend`
|
||||
SerializedFile:
|
||||
MapStringString:
|
||||
type: object
|
||||
properties:
|
||||
path:
|
||||
type: string
|
||||
content:
|
||||
type: string
|
||||
format: byte
|
||||
executable:
|
||||
type: boolean
|
||||
symlink:
|
||||
type: boolean
|
||||
required:
|
||||
- path
|
||||
- content
|
||||
SerializedTaskEvent:
|
||||
type: object
|
||||
properties:
|
||||
id:
|
||||
type: integer
|
||||
isTaskRecoverable:
|
||||
type: boolean
|
||||
taskId:
|
||||
type: string
|
||||
body:
|
||||
$ref: '#/components/schemas/JsonObject'
|
||||
type:
|
||||
$ref: '#/components/schemas/TaskEventType'
|
||||
createdAt:
|
||||
type: string
|
||||
required:
|
||||
- id
|
||||
- taskId
|
||||
- body
|
||||
- type
|
||||
- createdAt
|
||||
description: SerializedTaskEvent
|
||||
properties: {}
|
||||
additionalProperties:
|
||||
type: string
|
||||
description: Construct a type with a set of properties K of type T
|
||||
ScaffolderScaffoldOptions:
|
||||
type: object
|
||||
properties:
|
||||
@@ -288,17 +383,19 @@ components:
|
||||
- templateRef
|
||||
- values
|
||||
description: The input options to the `scaffold` method of the `ScaffolderClient`.
|
||||
# come back to this one - done
|
||||
# check generated - done
|
||||
Schema:
|
||||
type: object
|
||||
properties:
|
||||
$id:
|
||||
type: string
|
||||
# $id:
|
||||
# type: string
|
||||
id:
|
||||
type: string
|
||||
$schema:
|
||||
type: string
|
||||
$ref:
|
||||
type: string
|
||||
# $schema:
|
||||
# type: string
|
||||
# $ref:
|
||||
# type: string
|
||||
title:
|
||||
type: string
|
||||
description:
|
||||
@@ -322,7 +419,7 @@ components:
|
||||
minLength:
|
||||
type: integer
|
||||
pattern:
|
||||
type: string
|
||||
type: object
|
||||
additionalItems:
|
||||
oneOf:
|
||||
- type: boolean
|
||||
@@ -373,24 +470,12 @@ components:
|
||||
- type: array
|
||||
items:
|
||||
type: string
|
||||
const:
|
||||
oneOf:
|
||||
- type: string
|
||||
- type: number
|
||||
- type: boolean
|
||||
- type: array
|
||||
- type: object
|
||||
nullable: true
|
||||
enum:
|
||||
type: array
|
||||
items:
|
||||
oneOf:
|
||||
- type: string
|
||||
- type: number
|
||||
- type: boolean
|
||||
- type: array
|
||||
- type: object
|
||||
nullable: true
|
||||
# const:
|
||||
# type: object
|
||||
# enum:
|
||||
# type: array
|
||||
# items:
|
||||
# type: object
|
||||
type:
|
||||
oneOf:
|
||||
- type: string
|
||||
@@ -413,12 +498,50 @@ components:
|
||||
$ref: '#/components/schemas/Schema'
|
||||
not:
|
||||
$ref: '#/components/schemas/Schema'
|
||||
if:
|
||||
$ref: '#/components/schemas/Schema'
|
||||
# if:
|
||||
# $ref: '#/components/schemas/Schema'
|
||||
then:
|
||||
$ref: '#/components/schemas/Schema'
|
||||
else:
|
||||
$ref: '#/components/schemas/Schema'
|
||||
# else:
|
||||
# $ref: '#/components/schemas/Schema'
|
||||
additionalProperties: {}
|
||||
SerializedFile:
|
||||
type: object
|
||||
properties:
|
||||
path:
|
||||
type: string
|
||||
content:
|
||||
type: string
|
||||
format: byte
|
||||
executable:
|
||||
type: boolean
|
||||
symlink:
|
||||
type: boolean
|
||||
required:
|
||||
- path
|
||||
- content
|
||||
SerializedTaskEvent:
|
||||
type: object
|
||||
properties:
|
||||
id:
|
||||
type: integer
|
||||
isTaskRecoverable:
|
||||
type: boolean
|
||||
taskId:
|
||||
type: string
|
||||
body:
|
||||
$ref: '#/components/schemas/JsonObject'
|
||||
type:
|
||||
$ref: '#/components/schemas/TaskEventType'
|
||||
createdAt:
|
||||
type: string
|
||||
required:
|
||||
- id
|
||||
- taskId
|
||||
- body
|
||||
- type
|
||||
- createdAt
|
||||
description: SerializedTaskEvent
|
||||
SerializedTask:
|
||||
type: object
|
||||
properties:
|
||||
@@ -454,14 +577,17 @@ components:
|
||||
- recovered
|
||||
TaskRecovery:
|
||||
type: object
|
||||
properties:
|
||||
EXPERIMENTAL_strategy:
|
||||
$ref: '#/components/schemas/TaskRecoverStrategy'
|
||||
# properties:
|
||||
# come back to this one - done
|
||||
# EXPERIMENTAL_strategy:
|
||||
# $ref: '#/components/schemas/TaskRecoverStrategy'
|
||||
description: |-
|
||||
When task didn't have a chance to complete due to system restart you can define the strategy what to do with such tasks,
|
||||
by defining a strategy.
|
||||
|
||||
By default, it is none, what means to not recover but updating the status from 'processing' to 'failed'.
|
||||
additionalProperties:
|
||||
$ref: '#/components/schemas/TaskRecoverStrategy'
|
||||
TaskRecoverStrategy:
|
||||
type: string
|
||||
description: |
|
||||
@@ -475,9 +601,8 @@ components:
|
||||
properties:
|
||||
backstageToken:
|
||||
type: string
|
||||
additionalProperties:
|
||||
type: string
|
||||
description: TaskSecrets
|
||||
additionalProperties: {}
|
||||
TaskSpec:
|
||||
$ref: '#/components/schemas/TaskSpecV1beta3'
|
||||
TaskSpecV1beta3:
|
||||
@@ -522,9 +647,10 @@ components:
|
||||
type: string
|
||||
description: An entity ref for the author of the task
|
||||
description: Some decoration of the author of the task that should be available in the context
|
||||
EXPERIMENTAL_recovery:
|
||||
$ref: '#/components/schemas/TaskRecovery'
|
||||
description: How to recover the task after system restart or system crash.
|
||||
# come back to this one - done
|
||||
# EXPERIMENTAL_recovery:
|
||||
# $ref: '#/components/schemas/TaskRecovery'
|
||||
# description: How to recover the task after system restart or system crash.
|
||||
required:
|
||||
- apiVersion
|
||||
- parameters
|
||||
@@ -533,6 +659,8 @@ components:
|
||||
description: |-
|
||||
A scaffolder task as stored in the database, generated from a v1beta3
|
||||
apiVersion Template.
|
||||
additionalProperties:
|
||||
$ref: '#/components/schemas/TaskRecovery'
|
||||
TaskStatus:
|
||||
type: string
|
||||
enum:
|
||||
@@ -557,11 +685,11 @@ components:
|
||||
input:
|
||||
$ref: '#/components/schemas/JsonObject'
|
||||
description: Additional data that will be passed to the action.
|
||||
if:
|
||||
oneOf:
|
||||
- type: string
|
||||
- type: boolean
|
||||
description: When this is false, or if the templated value string evaluates to something that is falsy the step will be skipped.
|
||||
# if:
|
||||
# oneOf:
|
||||
# - type: string
|
||||
# - type: boolean
|
||||
# description: When this is false, or if the templated value string evaluates to something that is falsy the step will be skipped.
|
||||
each:
|
||||
oneOf:
|
||||
- type: string
|
||||
@@ -572,6 +700,7 @@ components:
|
||||
- name
|
||||
- action
|
||||
description: An individual step of a scaffolder task, as stored in the database.
|
||||
additionalProperties: {}
|
||||
TemplateEntityStepV1beta3:
|
||||
allOf:
|
||||
- $ref: '#/components/schemas/JsonObject'
|
||||
@@ -585,18 +714,21 @@ components:
|
||||
type: string
|
||||
input:
|
||||
$ref: '#/components/schemas/JsonObject'
|
||||
if:
|
||||
oneOf:
|
||||
- type: string
|
||||
- type: boolean
|
||||
backstage:permissions:
|
||||
$ref: '#/components/schemas/TemplatePermissionsV1beta3'
|
||||
# if:
|
||||
# oneOf:
|
||||
# - type: string
|
||||
# - type: boolean
|
||||
# come back to this one - done
|
||||
# backstage:permissions:
|
||||
# $ref: '#/components/schemas/TemplatePermissionsV1beta3'
|
||||
required:
|
||||
- action
|
||||
description: Step that is part of a Template Entity.
|
||||
additionalProperties: {}
|
||||
TemplateEntityV1beta3:
|
||||
allOf:
|
||||
- $ref: '../../../catalog-backend/src/schema/openapi.yaml#/components/schemas/Entity'
|
||||
# come back to this one - done
|
||||
- $ref: '#/components/schemas/Entity'
|
||||
- type: object
|
||||
properties:
|
||||
apiVersion:
|
||||
@@ -616,9 +748,10 @@ components:
|
||||
presentation:
|
||||
$ref: '#/components/schemas/TemplatePresentationV1beta3'
|
||||
description: Template specific configuration of the presentation layer.
|
||||
EXPERIMENTAL_recovery:
|
||||
$ref: '#/components/schemas/TemplateRecoveryV1beta3'
|
||||
description: Recovery strategy for the template
|
||||
# come back to this one - done
|
||||
# EXPERIMENTAL_recovery:
|
||||
# $ref: '#/components/schemas/TemplateRecoveryV1beta3'
|
||||
# description: Recovery strategy for the template
|
||||
parameters:
|
||||
oneOf:
|
||||
- $ref: '#/components/schemas/TemplateParametersV1beta3'
|
||||
@@ -648,6 +781,7 @@ components:
|
||||
- type
|
||||
- steps
|
||||
description: The specification of the Template Entity
|
||||
additionalProperties: {}
|
||||
required:
|
||||
- apiVersion
|
||||
- kind
|
||||
@@ -669,7 +803,8 @@ components:
|
||||
description: The Template entity.
|
||||
properties:
|
||||
metadata:
|
||||
$ref: '../../../catalog-backend/src/schema/openapi.yaml#/components/schemas/EntityMeta'
|
||||
# come back to this one - done
|
||||
$ref: '#/components/schemas/EntityMeta'
|
||||
description: The metadata of the Template.
|
||||
required:
|
||||
- entityRef
|
||||
@@ -681,37 +816,56 @@ components:
|
||||
properties:
|
||||
title:
|
||||
type: string
|
||||
description:
|
||||
type: string
|
||||
presentation:
|
||||
$ref: '#/components/schemas/TemplatePresentationV1beta3'
|
||||
description:
|
||||
type: string
|
||||
# come back to this one - done
|
||||
# 'ui:options':
|
||||
# $ref: '#/components/schemas/JsonValue'
|
||||
steps:
|
||||
type: array
|
||||
items:
|
||||
type: object
|
||||
properties:
|
||||
title:
|
||||
type: string
|
||||
$ref: '#/components/schemas/JsonValue'
|
||||
description:
|
||||
type: string
|
||||
$ref: '#/components/schemas/JsonValue'
|
||||
schema:
|
||||
$ref: '#/components/schemas/JsonObject'
|
||||
$ref: '#/components/schemas/TemplateParametersV1beta3'
|
||||
required:
|
||||
- title
|
||||
- schema
|
||||
# come back to this one - done
|
||||
# EXPERIMENTAL_formDecorators:
|
||||
# type: array
|
||||
# items:
|
||||
# - type: object
|
||||
# properties:
|
||||
# id:
|
||||
# type: string
|
||||
# input:
|
||||
# $ref: '#/components/schemas/JsonObject'
|
||||
required:
|
||||
- title
|
||||
- steps
|
||||
description: |-
|
||||
The shape of each entry of parameters which gets rendered
|
||||
as a separate step in the wizard input
|
||||
additionalProperties: {}
|
||||
# check generated
|
||||
TemplateParametersV1beta3:
|
||||
allOf:
|
||||
- $ref: '#/components/schemas/JsonObject'
|
||||
# - type: object
|
||||
# properties:
|
||||
# # come back to this one - done
|
||||
# backstage:permissions:
|
||||
# $ref: '#/components/schemas/TemplatePermissionsV1beta3'
|
||||
- type: object
|
||||
properties:
|
||||
backstage:permissions:
|
||||
$ref: '#/components/schemas/TemplatePermissionsV1beta3'
|
||||
additionalProperties:
|
||||
$ref: '#/components/schemas/TemplatePermissionsV1beta3'
|
||||
description: Parameter that is part of a Template Entity.
|
||||
TemplatePermissionsV1beta3:
|
||||
allOf:
|
||||
@@ -742,17 +896,64 @@ components:
|
||||
additionalProperties: false
|
||||
description: The presentation of the template.
|
||||
additionalProperties: {}
|
||||
# check generated
|
||||
TemplateRecoveryV1beta3:
|
||||
allOf:
|
||||
- $ref: '#/components/schemas/JsonObject'
|
||||
- type: string
|
||||
enum:
|
||||
- none
|
||||
- startOver
|
||||
description: |-
|
||||
none - not recover, let the task be marked as failed
|
||||
startOver - do recover, start the execution of the task from the first step.
|
||||
- type: object
|
||||
# properties:
|
||||
# # come back to this one - done
|
||||
# EXPERIMENTAL_strategy:
|
||||
# type: string
|
||||
# enum:
|
||||
# - none
|
||||
# - startOver
|
||||
# description: |-
|
||||
# none - not recover, let the task be marked as failed
|
||||
# startOver - do recover, start the execution of the task from the first step.
|
||||
additionalProperties:
|
||||
type: string
|
||||
enum:
|
||||
- none
|
||||
- startOver
|
||||
description: |-
|
||||
none - not recover, let the task be marked as failed
|
||||
startOver - do recover, start the execution of the task from the first step.
|
||||
description: Depends on how you designed your task you might tailor the behaviour for each of them.
|
||||
ValidationError:
|
||||
type: object
|
||||
properties:
|
||||
path:
|
||||
type: array
|
||||
items:
|
||||
oneOf:
|
||||
- type: string
|
||||
- type: integer
|
||||
property:
|
||||
type: string
|
||||
message:
|
||||
type: string
|
||||
schema:
|
||||
oneOf:
|
||||
- type: string
|
||||
- $ref: '#/components/schemas/Schema'
|
||||
instance:
|
||||
type: object
|
||||
name:
|
||||
type: string
|
||||
argument:
|
||||
type: object
|
||||
stack:
|
||||
type: string
|
||||
required:
|
||||
- path
|
||||
- property
|
||||
- message
|
||||
- schema
|
||||
- instance
|
||||
- name
|
||||
- argument
|
||||
- stack
|
||||
securitySchemes:
|
||||
JWT:
|
||||
type: http
|
||||
@@ -812,7 +1013,12 @@ paths:
|
||||
security:
|
||||
- {}
|
||||
- JWT: []
|
||||
parameters: []
|
||||
parameters:
|
||||
- $ref: '#/components/parameters/createdBy'
|
||||
- $ref: '#/components/parameters/limit'
|
||||
- $ref: '#/components/parameters/offset'
|
||||
- $ref: '#/components/parameters/order'
|
||||
- $ref: '#/components/parameters/status'
|
||||
post:
|
||||
operationId: Scaffold
|
||||
description: |-
|
||||
@@ -835,7 +1041,18 @@ paths:
|
||||
id:
|
||||
type: string
|
||||
'400':
|
||||
$ref: '#/components/responses/ValidationError'
|
||||
description: Validation errors.
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
errors:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/components/schemas/ValidationError'
|
||||
required:
|
||||
- errors
|
||||
security:
|
||||
- {}
|
||||
- JWT: []
|
||||
@@ -966,48 +1183,51 @@ paths:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
allOf:
|
||||
- $ref: '#/components/schemas/DryRunResult'
|
||||
- type: object
|
||||
properties:
|
||||
steps:
|
||||
type: array
|
||||
items:
|
||||
allOf:
|
||||
- $ref: '#/components/schemas/TemplateEntityStepV1beta3'
|
||||
- type: object
|
||||
properties:
|
||||
id:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
required:
|
||||
- id
|
||||
- name
|
||||
directoryContents:
|
||||
type: array
|
||||
items:
|
||||
type: object
|
||||
properties:
|
||||
id:
|
||||
path:
|
||||
type: string
|
||||
name:
|
||||
executable:
|
||||
type: boolean
|
||||
base64Content:
|
||||
type: string
|
||||
action:
|
||||
type: string
|
||||
input:
|
||||
$ref: '#/components/schemas/JsonObject'
|
||||
if:
|
||||
oneOf:
|
||||
- type: string
|
||||
- type: boolean
|
||||
backstage:permissions:
|
||||
$ref: '#/components/schemas/TemplatePermissionsV1beta3'
|
||||
required:
|
||||
- id
|
||||
- name
|
||||
- action
|
||||
directoryContents:
|
||||
type: object
|
||||
properties:
|
||||
path:
|
||||
type: string
|
||||
executable:
|
||||
type: boolean
|
||||
base64Content:
|
||||
type: string
|
||||
required:
|
||||
- path
|
||||
- base64Content
|
||||
- path
|
||||
- base64Content
|
||||
'400':
|
||||
$ref: '#/components/responses/ValidationError'
|
||||
description: Validation errors.
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
errors:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/components/schemas/ValidationError'
|
||||
required:
|
||||
- errors
|
||||
parameters: []
|
||||
|
||||
/v2/autocomplete/{provider}/{resource}:
|
||||
@@ -1027,6 +1247,9 @@ paths:
|
||||
type: string
|
||||
token:
|
||||
type: string
|
||||
required:
|
||||
- context
|
||||
- token
|
||||
responses:
|
||||
'200':
|
||||
description: Ok
|
||||
|
||||
@@ -0,0 +1,167 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { Action } from '../models/Action.model';
|
||||
import { Autocomplete200Response } from '../models/Autocomplete200Response.model';
|
||||
import { AutocompleteRequest } from '../models/AutocompleteRequest.model';
|
||||
import { CancelTask200Response } from '../models/CancelTask200Response.model';
|
||||
import { DryRun200Response } from '../models/DryRun200Response.model';
|
||||
import { DryRunRequest } from '../models/DryRunRequest.model';
|
||||
import { ListTasksResponse } from '../models/ListTasksResponse.model';
|
||||
import { Scaffold201Response } from '../models/Scaffold201Response.model';
|
||||
import { Scaffold400Response } from '../models/Scaffold400Response.model';
|
||||
import { ScaffolderScaffoldOptions } from '../models/ScaffolderScaffoldOptions.model';
|
||||
import { SerializedTask } from '../models/SerializedTask.model';
|
||||
import { SerializedTaskEvent } from '../models/SerializedTaskEvent.model';
|
||||
import { TemplateParameterSchema } from '../models/TemplateParameterSchema.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type Autocomplete = {
|
||||
path: {
|
||||
provider: string;
|
||||
resource: string;
|
||||
};
|
||||
body: AutocompleteRequest;
|
||||
response: Autocomplete200Response;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type CancelTask = {
|
||||
path: {
|
||||
taskId: string;
|
||||
};
|
||||
response: CancelTask200Response;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type DryRun = {
|
||||
body: DryRunRequest;
|
||||
response: DryRun200Response | Scaffold400Response;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type GetTask = {
|
||||
path: {
|
||||
taskId: string;
|
||||
};
|
||||
response: SerializedTask;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type GetTemplateParameterSchema = {
|
||||
path: {
|
||||
namespace: string;
|
||||
kind: string;
|
||||
name: string;
|
||||
};
|
||||
response: TemplateParameterSchema | Error | Error;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type ListActions = {
|
||||
response: Array<Action>;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type ListTasks = {
|
||||
query: {
|
||||
createdBy?: string;
|
||||
limit?: number;
|
||||
offset?: number;
|
||||
order?: 'asc' | 'desc';
|
||||
status?: string;
|
||||
};
|
||||
response: ListTasksResponse;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type Retry = {
|
||||
path: {
|
||||
taskId: string;
|
||||
};
|
||||
response: Scaffold201Response;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type Scaffold = {
|
||||
body: ScaffolderScaffoldOptions;
|
||||
response: Scaffold201Response | Scaffold400Response;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type StreamLogsEventStream = {
|
||||
path: {
|
||||
taskId: string;
|
||||
};
|
||||
query: {
|
||||
after?: number;
|
||||
};
|
||||
response: string;
|
||||
};
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type StreamLogsPolling = {
|
||||
path: {
|
||||
taskId: string;
|
||||
};
|
||||
query: {
|
||||
after?: number;
|
||||
};
|
||||
response: Array<SerializedTaskEvent>;
|
||||
};
|
||||
|
||||
/**
|
||||
* no description
|
||||
*/
|
||||
|
||||
export type EndpointMap = {
|
||||
'#post|/v2/autocomplete/{provider}/{resource}': Autocomplete;
|
||||
|
||||
'#post|/v2/tasks/{taskId}/cancel': CancelTask;
|
||||
|
||||
'#post|/v2/dry-run': DryRun;
|
||||
|
||||
'#get|/v2/tasks/{taskId}': GetTask;
|
||||
|
||||
'#get|/v2/templates/{namespace}/{kind}/{name}/parameter-schema': GetTemplateParameterSchema;
|
||||
|
||||
'#get|/v2/actions': ListActions;
|
||||
|
||||
'#get|/v2/tasks': ListTasks;
|
||||
|
||||
'#post|/v2/tasks/{taskId}/retry': Retry;
|
||||
|
||||
'#post|/v2/tasks': Scaffold;
|
||||
|
||||
'#get|/v2/tasks/{taskId}/eventstream': StreamLogsEventStream;
|
||||
|
||||
'#get|/v2/tasks/{taskId}/events': StreamLogsPolling;
|
||||
};
|
||||
@@ -0,0 +1,17 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
export * from './DefaultApi.server';
|
||||
@@ -0,0 +1,18 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
export * from './apis';
|
||||
export * from './router';
|
||||
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { ActionExample } from '../models/ActionExample.model';
|
||||
import { ActionSchema } from '../models/ActionSchema.model';
|
||||
|
||||
/**
|
||||
* The response shape for a single action in the `listActions` call to the `scaffolder-backend`
|
||||
* @public
|
||||
*/
|
||||
export interface Action {
|
||||
id: string;
|
||||
description?: string;
|
||||
examples?: Array<ActionExample>;
|
||||
schema?: ActionSchema;
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* A single action example
|
||||
* @public
|
||||
*/
|
||||
export interface ActionExample {
|
||||
description: string;
|
||||
example: string;
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface ActionSchema {
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
input?: { [key: string]: any };
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
output?: { [key: string]: any };
|
||||
}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { Autocomplete200ResponseResultsInner } from '../models/Autocomplete200ResponseResultsInner.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface Autocomplete200Response {
|
||||
results?: Array<Autocomplete200ResponseResultsInner>;
|
||||
}
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface Autocomplete200ResponseResultsInner {
|
||||
title?: string;
|
||||
}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface AutocompleteRequest {
|
||||
context: { [key: string]: string };
|
||||
token: string;
|
||||
}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TaskStatus } from '../models/TaskStatus.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface CancelTask200Response {
|
||||
status?: TaskStatus;
|
||||
}
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { DryRun200ResponseAllOfDirectoryContentsInner } from '../models/DryRun200ResponseAllOfDirectoryContentsInner.model';
|
||||
import { DryRun200ResponseAllOfStepsInner } from '../models/DryRun200ResponseAllOfStepsInner.model';
|
||||
import { DryRunResultLogInner } from '../models/DryRunResultLogInner.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface DryRun200Response {
|
||||
log: Array<DryRunResultLogInner>;
|
||||
directoryContents: Array<DryRun200ResponseAllOfDirectoryContentsInner>;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
output: { [key: string]: any };
|
||||
steps?: Array<DryRun200ResponseAllOfStepsInner>;
|
||||
}
|
||||
+29
@@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { DryRun200ResponseAllOfDirectoryContentsInner } from '../models/DryRun200ResponseAllOfDirectoryContentsInner.model';
|
||||
import { DryRun200ResponseAllOfStepsInner } from '../models/DryRun200ResponseAllOfStepsInner.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface DryRun200ResponseAllOf {
|
||||
steps?: Array<DryRun200ResponseAllOfStepsInner>;
|
||||
directoryContents?: Array<DryRun200ResponseAllOfDirectoryContentsInner>;
|
||||
}
|
||||
+28
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface DryRun200ResponseAllOfDirectoryContentsInner {
|
||||
path: string;
|
||||
executable?: boolean;
|
||||
base64Content: string;
|
||||
}
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface DryRun200ResponseAllOfStepsInner {
|
||||
id: string;
|
||||
name: string;
|
||||
action: string;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
input?: { [key: string]: any };
|
||||
}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface DryRun200ResponseAllOfStepsInnerAllOf {
|
||||
id: string;
|
||||
name: string;
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { DryRunRequestDirectoryContentsInner } from '../models/DryRunRequestDirectoryContentsInner.model';
|
||||
import { TemplateEntityV1beta3 } from '../models/TemplateEntityV1beta3.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface DryRunRequest {
|
||||
template: TemplateEntityV1beta3;
|
||||
values: any;
|
||||
secrets?: any;
|
||||
directoryContents: Array<DryRunRequestDirectoryContentsInner>;
|
||||
}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface DryRunRequestDirectoryContentsInner {
|
||||
path?: string;
|
||||
base64Content?: string;
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { DryRunResultLogInner } from '../models/DryRunResultLogInner.model';
|
||||
import { SerializedFile } from '../models/SerializedFile.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface DryRunResult {
|
||||
log: Array<DryRunResultLogInner>;
|
||||
directoryContents: Array<SerializedFile>;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
output: { [key: string]: any };
|
||||
}
|
||||
+29
@@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface DryRunResultLogInner {
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
body?: { [key: string]: any };
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { EntityMeta } from '../models/EntityMeta.model';
|
||||
import { EntityRelation } from '../models/EntityRelation.model';
|
||||
|
||||
/**
|
||||
* The parts of the format that's common to all versions/kinds of entity.
|
||||
* @public
|
||||
*/
|
||||
export interface Entity {
|
||||
/**
|
||||
* The relations that this entity has with other entities.
|
||||
*/
|
||||
relations?: Array<EntityRelation>;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
spec?: { [key: string]: any };
|
||||
metadata: EntityMeta;
|
||||
/**
|
||||
* The high level entity type being described.
|
||||
*/
|
||||
kind: string;
|
||||
/**
|
||||
* The version of specification format for this particular entity that this is written against.
|
||||
*/
|
||||
apiVersion: string;
|
||||
}
|
||||
@@ -0,0 +1,42 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* A link to external information that is related to the entity.
|
||||
* @public
|
||||
*/
|
||||
export interface EntityLink {
|
||||
/**
|
||||
* An optional value to categorize links into specific groups
|
||||
*/
|
||||
type?: string;
|
||||
/**
|
||||
* An optional semantic key that represents a visual icon.
|
||||
*/
|
||||
icon?: string;
|
||||
/**
|
||||
* An optional descriptive title for the link.
|
||||
*/
|
||||
title?: string;
|
||||
/**
|
||||
* The url to the external site, document, etc.
|
||||
*/
|
||||
url: string;
|
||||
}
|
||||
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { EntityLink } from '../models/EntityLink.model';
|
||||
|
||||
/**
|
||||
* Metadata fields common to all versions/kinds of entity.
|
||||
* @public
|
||||
*/
|
||||
export interface EntityMeta {
|
||||
[key: string]: any;
|
||||
|
||||
/**
|
||||
* A list of external hyperlinks related to the entity.
|
||||
*/
|
||||
links?: Array<EntityLink>;
|
||||
/**
|
||||
* A list of single-valued strings, to for example classify catalog entities in various ways.
|
||||
*/
|
||||
tags?: Array<string>;
|
||||
/**
|
||||
* Construct a type with a set of properties K of type T
|
||||
*/
|
||||
annotations?: { [key: string]: string };
|
||||
/**
|
||||
* Construct a type with a set of properties K of type T
|
||||
*/
|
||||
labels?: { [key: string]: string };
|
||||
/**
|
||||
* A short (typically relatively few words, on one line) description of the entity.
|
||||
*/
|
||||
description?: string;
|
||||
/**
|
||||
* A display name of the entity, to be presented in user interfaces instead of the `name` property above, when available. This field is sometimes useful when the `name` is cumbersome or ends up being perceived as overly technical. The title generally does not have as stringent format requirements on it, so it may contain special characters and be more explanatory. Do keep it very short though, and avoid situations where a title can be confused with the name of another entity, or where two entities share a title. Note that this is only for display purposes, and may be ignored by some parts of the code. Entity references still always make use of the `name` property, not the title.
|
||||
*/
|
||||
title?: string;
|
||||
/**
|
||||
* The namespace that the entity belongs to.
|
||||
*/
|
||||
namespace?: string;
|
||||
/**
|
||||
* The name of the entity. Must be unique within the catalog at any given point in time, for any given namespace + kind pair. This value is part of the technical identifier of the entity, and as such it will appear in URLs, database tables, entity references, and similar. It is subject to restrictions regarding what characters are allowed. If you want to use a different, more human readable string with fewer restrictions on it in user interfaces, see the `title` field below.
|
||||
*/
|
||||
name: string;
|
||||
/**
|
||||
* An opaque string that changes for each update operation to any part of the entity, including metadata. This field can not be set by the user at creation time, and the server will reject an attempt to do so. The field will be populated in read operations. The field can (optionally) be specified when performing update or delete operations, and the server will then reject the operation if it does not match the current stored value.
|
||||
*/
|
||||
etag?: string;
|
||||
/**
|
||||
* A globally unique ID for the entity. This field can not be set by the user at creation time, and the server will reject an attempt to do so. The field will be populated in read operations. The field can (optionally) be specified when performing update or delete operations, but the server is free to reject requests that do so in such a way that it breaks semantics.
|
||||
*/
|
||||
uid?: string;
|
||||
}
|
||||
+34
@@ -0,0 +1,34 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* A relation of a specific type to another entity in the catalog.
|
||||
* @public
|
||||
*/
|
||||
export interface EntityRelation {
|
||||
/**
|
||||
* The entity ref of the target of this relation.
|
||||
*/
|
||||
targetRef: string;
|
||||
/**
|
||||
* The type of the relation.
|
||||
*/
|
||||
type: string;
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface ErrorError {
|
||||
name: string;
|
||||
message: string;
|
||||
stack?: string;
|
||||
code?: string;
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface ErrorRequest {
|
||||
method: string;
|
||||
url: string;
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface ErrorResponse {
|
||||
statusCode: number;
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* A type representing all allowed JSON primitive values.
|
||||
* @public
|
||||
*/
|
||||
export type JsonPrimitive = any | boolean | number | string;
|
||||
@@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { JsonPrimitive } from '../models/JsonPrimitive.model';
|
||||
|
||||
/**
|
||||
* A type representing all allowed JSON values.
|
||||
* @public
|
||||
*/
|
||||
export type JsonValue =
|
||||
| Array<JsonValue>
|
||||
| JsonPrimitive
|
||||
| { [key: string]: any };
|
||||
+28
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { SerializedTask } from '../models/SerializedTask.model';
|
||||
|
||||
/**
|
||||
* The response shape for the `listTasks` call to the `scaffolder-backend`
|
||||
* @public
|
||||
*/
|
||||
export interface ListTasksResponse {
|
||||
tasks?: Array<SerializedTask>;
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { ErrorError } from '../models/ErrorError.model';
|
||||
import { ErrorRequest } from '../models/ErrorRequest.model';
|
||||
import { ErrorResponse } from '../models/ErrorResponse.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface ModelError {
|
||||
[key: string]: any;
|
||||
|
||||
error: ErrorError;
|
||||
request?: ErrorRequest;
|
||||
response: ErrorResponse;
|
||||
}
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface Scaffold201Response {
|
||||
id?: string;
|
||||
}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { ValidationError } from '../models/ValidationError.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface Scaffold400Response {
|
||||
errors: Array<ValidationError>;
|
||||
}
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { JsonValue } from '../models/JsonValue.model';
|
||||
|
||||
/**
|
||||
* The input options to the `scaffold` method of the `ScaffolderClient`.
|
||||
* @public
|
||||
*/
|
||||
export interface ScaffolderScaffoldOptions {
|
||||
templateRef: string;
|
||||
values: { [key: string]: JsonValue };
|
||||
secrets?: { [key: string]: string };
|
||||
}
|
||||
@@ -0,0 +1,64 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { SchemaAdditionalItems } from '../models/SchemaAdditionalItems.model';
|
||||
import { SchemaDependenciesValue } from '../models/SchemaDependenciesValue.model';
|
||||
import { SchemaExclusiveMaximum } from '../models/SchemaExclusiveMaximum.model';
|
||||
import { SchemaItems } from '../models/SchemaItems.model';
|
||||
import { SchemaRequired } from '../models/SchemaRequired.model';
|
||||
import { SchemaType } from '../models/SchemaType.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface Schema {
|
||||
[key: string]: any;
|
||||
|
||||
id?: string;
|
||||
title?: string;
|
||||
description?: string;
|
||||
multipleOf?: number;
|
||||
maximum?: number;
|
||||
exclusiveMaximum?: SchemaExclusiveMaximum;
|
||||
minimum?: number;
|
||||
exclusiveMinimum?: SchemaExclusiveMaximum;
|
||||
maxLength?: number;
|
||||
minLength?: number;
|
||||
pattern?: any;
|
||||
additionalItems?: SchemaAdditionalItems;
|
||||
items?: SchemaItems;
|
||||
maxItems?: number;
|
||||
minItems?: number;
|
||||
uniqueItems?: boolean;
|
||||
maxProperties?: number;
|
||||
minProperties?: number;
|
||||
required?: SchemaRequired;
|
||||
additionalProperties?: SchemaAdditionalItems;
|
||||
definitions?: { [key: string]: Schema };
|
||||
properties?: { [key: string]: Schema };
|
||||
patternProperties?: { [key: string]: Schema };
|
||||
dependencies?: { [key: string]: SchemaDependenciesValue };
|
||||
type?: SchemaType;
|
||||
format?: string;
|
||||
allOf?: Array<Schema>;
|
||||
anyOf?: Array<Schema>;
|
||||
oneOf?: Array<Schema>;
|
||||
not?: Schema;
|
||||
then?: Schema;
|
||||
}
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { Schema } from '../models/Schema.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type SchemaAdditionalItems = Schema | boolean;
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { Schema } from '../models/Schema.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type SchemaDependenciesValue = Array<string> | Schema;
|
||||
+24
@@ -0,0 +1,24 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type SchemaExclusiveMaximum = boolean | number;
|
||||
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { Schema } from '../models/Schema.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type SchemaItems = Array<Schema> | Schema;
|
||||
+24
@@ -0,0 +1,24 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type SchemaRequired = Array<string> | boolean;
|
||||
@@ -0,0 +1,24 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type SchemaType = Array<string> | string;
|
||||
+29
@@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface SerializedFile {
|
||||
path: string;
|
||||
content: string;
|
||||
executable?: boolean;
|
||||
symlink?: boolean;
|
||||
}
|
||||
+40
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TaskSecrets } from '../models/TaskSecrets.model';
|
||||
import { TaskSpecV1beta3 } from '../models/TaskSpecV1beta3.model';
|
||||
import { TaskStatus } from '../models/TaskStatus.model';
|
||||
|
||||
/**
|
||||
* SerializedTask
|
||||
* @public
|
||||
*/
|
||||
export interface SerializedTask {
|
||||
id: string;
|
||||
spec: TaskSpecV1beta3;
|
||||
status: TaskStatus;
|
||||
createdAt: string;
|
||||
lastHeartbeatAt?: string;
|
||||
createdBy?: string;
|
||||
secrets?: TaskSecrets;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
state?: { [key: string]: any };
|
||||
}
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TaskEventType } from '../models/TaskEventType.model';
|
||||
|
||||
/**
|
||||
* SerializedTaskEvent
|
||||
* @public
|
||||
*/
|
||||
export interface SerializedTaskEvent {
|
||||
id: number;
|
||||
isTaskRecoverable?: boolean;
|
||||
taskId: string;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
body: { [key: string]: any };
|
||||
type: TaskEventType;
|
||||
createdAt: string;
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type TaskEventType = 'completion' | 'log' | 'cancelled' | 'recovered';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const TaskEventType = {
|
||||
Completion: 'completion' as TaskEventType,
|
||||
Log: 'log' as TaskEventType,
|
||||
Cancelled: 'cancelled' as TaskEventType,
|
||||
Recovered: 'recovered' as TaskEventType,
|
||||
};
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type TaskRecoverStrategy = 'none' | 'startOver';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const TaskRecoverStrategy = {
|
||||
None: 'none' as TaskRecoverStrategy,
|
||||
StartOver: 'startOver' as TaskRecoverStrategy,
|
||||
};
|
||||
@@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* TaskSecrets
|
||||
* @public
|
||||
*/
|
||||
export interface TaskSecrets {
|
||||
[key: string]: any;
|
||||
|
||||
backstageToken?: string;
|
||||
}
|
||||
+55
@@ -0,0 +1,55 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { JsonValue } from '../models/JsonValue.model';
|
||||
import { TaskSpecV1beta3User } from '../models/TaskSpecV1beta3User.model';
|
||||
import { TaskStep } from '../models/TaskStep.model';
|
||||
import { TemplateInfo } from '../models/TemplateInfo.model';
|
||||
|
||||
/**
|
||||
* A scaffolder task as stored in the database, generated from a v1beta3 apiVersion Template.
|
||||
* @public
|
||||
*/
|
||||
export interface TaskSpecV1beta3 {
|
||||
[key: string]: any;
|
||||
|
||||
/**
|
||||
* The apiVersion string of the TaskSpec.
|
||||
*/
|
||||
apiVersion: TaskSpecV1beta3ApiVersionEnum;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
parameters: { [key: string]: any };
|
||||
/**
|
||||
* A list of steps to be executed in sequence which are defined by the template. These steps are a list of the underlying javascript action and some optional input parameters that may or may not have been collected from the end user.
|
||||
*/
|
||||
steps: Array<TaskStep>;
|
||||
/**
|
||||
* The output is an object where template authors can pull out information from template actions and return them in a known standard way.
|
||||
*/
|
||||
output: { [key: string]: JsonValue };
|
||||
templateInfo?: TemplateInfo;
|
||||
user?: TaskSpecV1beta3User;
|
||||
}
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type TaskSpecV1beta3ApiVersionEnum = 'scaffolder.backstage.io/v1beta3';
|
||||
+34
@@ -0,0 +1,34 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* Some decoration of the author of the task that should be available in the context
|
||||
* @public
|
||||
*/
|
||||
export interface TaskSpecV1beta3User {
|
||||
/**
|
||||
* The decorated entity from the Catalog
|
||||
*/
|
||||
entity?: { [key: string]: any };
|
||||
/**
|
||||
* An entity ref for the author of the task
|
||||
*/
|
||||
ref?: string;
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type TaskStatus =
|
||||
| 'cancelled'
|
||||
| 'completed'
|
||||
| 'failed'
|
||||
| 'open'
|
||||
| 'processing';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const TaskStatus = {
|
||||
Cancelled: 'cancelled' as TaskStatus,
|
||||
Completed: 'completed' as TaskStatus,
|
||||
Failed: 'failed' as TaskStatus,
|
||||
Open: 'open' as TaskStatus,
|
||||
Processing: 'processing' as TaskStatus,
|
||||
};
|
||||
@@ -0,0 +1,46 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TaskStepEach } from '../models/TaskStepEach.model';
|
||||
|
||||
/**
|
||||
* An individual step of a scaffolder task, as stored in the database.
|
||||
* @public
|
||||
*/
|
||||
export interface TaskStep {
|
||||
[key: string]: any;
|
||||
|
||||
/**
|
||||
* A unique identifier for this step.
|
||||
*/
|
||||
id: string;
|
||||
/**
|
||||
* A display name to show the user.
|
||||
*/
|
||||
name: string;
|
||||
/**
|
||||
* The underlying action ID that will be called as part of running this step.
|
||||
*/
|
||||
action: string;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
input?: { [key: string]: any };
|
||||
each?: TaskStepEach;
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { JsonValue } from '../models/JsonValue.model';
|
||||
|
||||
/**
|
||||
* Run step repeatedly.
|
||||
* @public
|
||||
*/
|
||||
export type TaskStepEach = Array<JsonValue> | string;
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* Step that is part of a Template Entity.
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateEntityStepV1beta3 {
|
||||
[key: string]: any;
|
||||
|
||||
id?: string;
|
||||
name?: string;
|
||||
action: string;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
input?: { [key: string]: any };
|
||||
}
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateEntityStepV1beta3AllOf {
|
||||
id?: string;
|
||||
name?: string;
|
||||
action: string;
|
||||
/**
|
||||
* A type representing all allowed JSON object values.
|
||||
*/
|
||||
input?: { [key: string]: any };
|
||||
}
|
||||
+53
@@ -0,0 +1,53 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { EntityMeta } from '../models/EntityMeta.model';
|
||||
import { EntityRelation } from '../models/EntityRelation.model';
|
||||
import { TemplateEntityV1beta3AllOfSpec } from '../models/TemplateEntityV1beta3AllOfSpec.model';
|
||||
|
||||
/**
|
||||
* Backstage catalog Template kind Entity. Templates are used by the Scaffolder plugin to create new entities, such as Components.
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateEntityV1beta3 {
|
||||
/**
|
||||
* The relations that this entity has with other entities.
|
||||
*/
|
||||
relations?: Array<EntityRelation>;
|
||||
spec: TemplateEntityV1beta3AllOfSpec;
|
||||
metadata: EntityMeta;
|
||||
/**
|
||||
* The kind of the entity
|
||||
*/
|
||||
kind: TemplateEntityV1beta3KindEnum;
|
||||
/**
|
||||
* The apiVersion string of the TaskSpec.
|
||||
*/
|
||||
apiVersion: TemplateEntityV1beta3ApiVersionEnum;
|
||||
}
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type TemplateEntityV1beta3KindEnum = 'Template';
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type TemplateEntityV1beta3ApiVersionEnum =
|
||||
'scaffolder.backstage.io/v1beta3';
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TemplateEntityV1beta3AllOfSpec } from '../models/TemplateEntityV1beta3AllOfSpec.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateEntityV1beta3AllOf {
|
||||
/**
|
||||
* The apiVersion string of the TaskSpec.
|
||||
*/
|
||||
apiVersion: TemplateEntityV1beta3AllOfApiVersionEnum;
|
||||
/**
|
||||
* The kind of the entity
|
||||
*/
|
||||
kind: TemplateEntityV1beta3AllOfKindEnum;
|
||||
spec: TemplateEntityV1beta3AllOfSpec;
|
||||
}
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type TemplateEntityV1beta3AllOfApiVersionEnum =
|
||||
'scaffolder.backstage.io/v1beta3';
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type TemplateEntityV1beta3AllOfKindEnum = 'Template';
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TemplateEntityStepV1beta3 } from '../models/TemplateEntityStepV1beta3.model';
|
||||
import { TemplateEntityV1beta3AllOfSpecParameters } from '../models/TemplateEntityV1beta3AllOfSpecParameters.model';
|
||||
import { TemplatePresentationV1beta3 } from '../models/TemplatePresentationV1beta3.model';
|
||||
|
||||
/**
|
||||
* The specification of the Template Entity
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateEntityV1beta3AllOfSpec {
|
||||
[key: string]: any;
|
||||
|
||||
/**
|
||||
* The type that the Template will create. For example service, website or library.
|
||||
*/
|
||||
type: string;
|
||||
presentation?: TemplatePresentationV1beta3;
|
||||
parameters?: TemplateEntityV1beta3AllOfSpecParameters;
|
||||
/**
|
||||
* A list of steps to be executed in sequence which are defined by the template. These steps are a list of the underlying javascript action and some optional input parameters that may or may not have been collected from the end user.
|
||||
*/
|
||||
steps: Array<TemplateEntityStepV1beta3>;
|
||||
/**
|
||||
* The output is an object where template authors can pull out information from template actions and return them in a known standard way.
|
||||
*/
|
||||
output?: { [key: string]: string };
|
||||
/**
|
||||
* The owner entityRef of the TemplateEntity
|
||||
*/
|
||||
owner?: string;
|
||||
}
|
||||
+28
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TemplateParametersV1beta3 } from '../models/TemplateParametersV1beta3.model';
|
||||
|
||||
/**
|
||||
* This is a JSONSchema or an array of JSONSchema's which is used to render a form in the frontend to collect user input and validate it against that schema. This can then be used in the `steps` part below to template variables passed from the user into each action in the template.
|
||||
* @public
|
||||
*/
|
||||
export type TemplateEntityV1beta3AllOfSpecParameters =
|
||||
| Array<TemplateParametersV1beta3>
|
||||
| TemplateParametersV1beta3;
|
||||
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TemplateInfoEntity } from '../models/TemplateInfoEntity.model';
|
||||
|
||||
/**
|
||||
* Information about a template that is stored on a task specification. Includes a stringified entityRef, and the baseUrl which is usually the relative path of the template definition
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateInfo {
|
||||
/**
|
||||
* The entityRef of the template.
|
||||
*/
|
||||
entityRef: string;
|
||||
/**
|
||||
* Where the template is stored, so we can resolve relative paths for things like `fetch:template` paths.
|
||||
*/
|
||||
baseUrl?: string;
|
||||
entity?: TemplateInfoEntity;
|
||||
}
|
||||
+28
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { EntityMeta } from '../models/EntityMeta.model';
|
||||
|
||||
/**
|
||||
* The Template entity.
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateInfoEntity {
|
||||
metadata?: EntityMeta;
|
||||
}
|
||||
+34
@@ -0,0 +1,34 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TemplateParameterSchemaStepsInner } from '../models/TemplateParameterSchemaStepsInner.model';
|
||||
import { TemplatePresentationV1beta3 } from '../models/TemplatePresentationV1beta3.model';
|
||||
|
||||
/**
|
||||
* The shape of each entry of parameters which gets rendered as a separate step in the wizard input
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateParameterSchema {
|
||||
[key: string]: any;
|
||||
|
||||
title: string;
|
||||
presentation?: TemplatePresentationV1beta3;
|
||||
description?: string;
|
||||
steps: Array<TemplateParameterSchemaStepsInner>;
|
||||
}
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { JsonValue } from '../models/JsonValue.model';
|
||||
import { TemplateParametersV1beta3 } from '../models/TemplateParametersV1beta3.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateParameterSchemaStepsInner {
|
||||
title: JsonValue;
|
||||
description?: JsonValue;
|
||||
schema: TemplateParametersV1beta3;
|
||||
}
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* Parameter that is part of a Template Entity.
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateParametersV1beta3 {}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* Access control properties for parts of a template.
|
||||
* @public
|
||||
*/
|
||||
export interface TemplatePermissionsV1beta3 {
|
||||
tags?: Array<string>;
|
||||
}
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface TemplatePermissionsV1beta3AllOf {
|
||||
tags?: Array<string>;
|
||||
}
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { TemplatePresentationV1beta3ButtonLabels } from '../models/TemplatePresentationV1beta3ButtonLabels.model';
|
||||
|
||||
/**
|
||||
* The presentation of the template.
|
||||
* @public
|
||||
*/
|
||||
export interface TemplatePresentationV1beta3 {
|
||||
[key: string]: any;
|
||||
|
||||
buttonLabels?: TemplatePresentationV1beta3ButtonLabels;
|
||||
}
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* Overrides default buttons' text
|
||||
* @public
|
||||
*/
|
||||
export interface TemplatePresentationV1beta3ButtonLabels {
|
||||
/**
|
||||
* The text for the button which leads to the previous template page
|
||||
*/
|
||||
backButtonText?: string;
|
||||
/**
|
||||
* The text for the button which starts the execution of the template
|
||||
*/
|
||||
createButtonText?: string;
|
||||
/**
|
||||
* The text for the button which opens template's review/summary
|
||||
*/
|
||||
reviewButtonText?: string;
|
||||
}
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* Depends on how you designed your task you might tailor the behaviour for each of them.
|
||||
* @public
|
||||
*/
|
||||
export interface TemplateRecoveryV1beta3 {}
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { ValidationErrorPathInner } from '../models/ValidationErrorPathInner.model';
|
||||
import { ValidationErrorSchema } from '../models/ValidationErrorSchema.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export interface ValidationError {
|
||||
path: Array<ValidationErrorPathInner>;
|
||||
property: string;
|
||||
message: string;
|
||||
schema: ValidationErrorSchema;
|
||||
instance: any;
|
||||
name: string;
|
||||
argument: any;
|
||||
stack: string;
|
||||
}
|
||||
+24
@@ -0,0 +1,24 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type ValidationErrorPathInner = number | string;
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
// ******************************************************************
|
||||
// * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. *
|
||||
// ******************************************************************
|
||||
import { Schema } from '../models/Schema.model';
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type ValidationErrorSchema = Schema | string;
|
||||
@@ -0,0 +1,83 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
export * from '../models/Action.model';
|
||||
export * from '../models/ActionExample.model';
|
||||
export * from '../models/ActionSchema.model';
|
||||
export * from '../models/Autocomplete200Response.model';
|
||||
export * from '../models/Autocomplete200ResponseResultsInner.model';
|
||||
export * from '../models/AutocompleteRequest.model';
|
||||
export * from '../models/CancelTask200Response.model';
|
||||
export * from '../models/DryRun200Response.model';
|
||||
export * from '../models/DryRun200ResponseAllOf.model';
|
||||
export * from '../models/DryRun200ResponseAllOfDirectoryContentsInner.model';
|
||||
export * from '../models/DryRun200ResponseAllOfStepsInner.model';
|
||||
export * from '../models/DryRun200ResponseAllOfStepsInnerAllOf.model';
|
||||
export * from '../models/DryRunRequest.model';
|
||||
export * from '../models/DryRunRequestDirectoryContentsInner.model';
|
||||
export * from '../models/DryRunResult.model';
|
||||
export * from '../models/DryRunResultLogInner.model';
|
||||
export * from '../models/Entity.model';
|
||||
export * from '../models/EntityLink.model';
|
||||
export * from '../models/EntityMeta.model';
|
||||
export * from '../models/EntityRelation.model';
|
||||
export * from '../models/ErrorError.model';
|
||||
export * from '../models/ErrorRequest.model';
|
||||
export * from '../models/ErrorResponse.model';
|
||||
export * from '../models/JsonPrimitive.model';
|
||||
export * from '../models/JsonValue.model';
|
||||
export * from '../models/ListTasksResponse.model';
|
||||
export * from '../models/ModelError.model';
|
||||
export * from '../models/Scaffold201Response.model';
|
||||
export * from '../models/Scaffold400Response.model';
|
||||
export * from '../models/ScaffolderScaffoldOptions.model';
|
||||
export * from '../models/Schema.model';
|
||||
export * from '../models/SchemaAdditionalItems.model';
|
||||
export * from '../models/SchemaDependenciesValue.model';
|
||||
export * from '../models/SchemaExclusiveMaximum.model';
|
||||
export * from '../models/SchemaItems.model';
|
||||
export * from '../models/SchemaRequired.model';
|
||||
export * from '../models/SchemaType.model';
|
||||
export * from '../models/SerializedFile.model';
|
||||
export * from '../models/SerializedTask.model';
|
||||
export * from '../models/SerializedTaskEvent.model';
|
||||
export * from '../models/TaskEventType.model';
|
||||
export * from '../models/TaskRecoverStrategy.model';
|
||||
export * from '../models/TaskSecrets.model';
|
||||
export * from '../models/TaskSpecV1beta3.model';
|
||||
export * from '../models/TaskSpecV1beta3User.model';
|
||||
export * from '../models/TaskStatus.model';
|
||||
export * from '../models/TaskStep.model';
|
||||
export * from '../models/TaskStepEach.model';
|
||||
export * from '../models/TemplateEntityStepV1beta3.model';
|
||||
export * from '../models/TemplateEntityStepV1beta3AllOf.model';
|
||||
export * from '../models/TemplateEntityV1beta3.model';
|
||||
export * from '../models/TemplateEntityV1beta3AllOf.model';
|
||||
export * from '../models/TemplateEntityV1beta3AllOfSpec.model';
|
||||
export * from '../models/TemplateEntityV1beta3AllOfSpecParameters.model';
|
||||
export * from '../models/TemplateInfo.model';
|
||||
export * from '../models/TemplateInfoEntity.model';
|
||||
export * from '../models/TemplateParameterSchema.model';
|
||||
export * from '../models/TemplateParameterSchemaStepsInner.model';
|
||||
export * from '../models/TemplateParametersV1beta3.model';
|
||||
export * from '../models/TemplatePermissionsV1beta3.model';
|
||||
export * from '../models/TemplatePermissionsV1beta3AllOf.model';
|
||||
export * from '../models/TemplatePresentationV1beta3.model';
|
||||
export * from '../models/TemplatePresentationV1beta3ButtonLabels.model';
|
||||
export * from '../models/TemplateRecoveryV1beta3.model';
|
||||
export * from '../models/ValidationError.model';
|
||||
export * from '../models/ValidationErrorPathInner.model';
|
||||
export * from '../models/ValidationErrorSchema.model';
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,17 @@
|
||||
/*
|
||||
* Copyright 2024 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
export * from './generated';
|
||||
@@ -79,7 +79,6 @@ import {
|
||||
} from '@backstage/plugin-scaffolder-node/alpha';
|
||||
import { HumanDuration, JsonObject } from '@backstage/types';
|
||||
import express from 'express';
|
||||
import Router from 'express-promise-router';
|
||||
import { validate } from 'jsonschema';
|
||||
import { Duration } from 'luxon';
|
||||
import { pathToFileURL } from 'url';
|
||||
@@ -93,6 +92,7 @@ import {
|
||||
import { createDryRunner } from '../scaffolder/dryrun';
|
||||
import { StorageTaskBroker } from '../scaffolder/tasks/StorageTaskBroker';
|
||||
import { InternalTaskSecrets } from '../scaffolder/tasks/types';
|
||||
import { createOpenApiRouter } from '../schema/openapi';
|
||||
import {
|
||||
checkPermission,
|
||||
checkTaskPermission,
|
||||
@@ -187,7 +187,7 @@ const readDuration = (
|
||||
export async function createRouter(
|
||||
options: RouterOptions,
|
||||
): Promise<express.Router> {
|
||||
const router = Router();
|
||||
const router = await createOpenApiRouter();
|
||||
// Be generous in upload size to support a wide range of templates in dry-run mode.
|
||||
router.use(express.json({ limit: '10MB' }));
|
||||
|
||||
|
||||
@@ -7323,6 +7323,7 @@ __metadata:
|
||||
dependencies:
|
||||
"@backstage/backend-app-api": "workspace:^"
|
||||
"@backstage/backend-defaults": "workspace:^"
|
||||
"@backstage/backend-openapi-utils": "workspace:^"
|
||||
"@backstage/backend-plugin-api": "workspace:^"
|
||||
"@backstage/backend-test-utils": "workspace:^"
|
||||
"@backstage/catalog-model": "workspace:^"
|
||||
@@ -7359,7 +7360,6 @@ __metadata:
|
||||
concat-stream: "npm:^2.0.0"
|
||||
esbuild: "npm:^0.25.0"
|
||||
express: "npm:^4.17.1"
|
||||
express-promise-router: "npm:^4.1.0"
|
||||
fs-extra: "npm:^11.2.0"
|
||||
globby: "npm:^11.0.0"
|
||||
isbinaryfile: "npm:^5.0.0"
|
||||
|
||||
Reference in New Issue
Block a user