openapi: 3.0.0
info:
  title: Evaluation
  version: 1.0.0
  description: |
    The Evaluation API is responsible for evaluation workflows in FDPlan. The
    key features of the API include:

    * The ability to create custom evaluation workflows.
    * The ability to drive custom evaluation workflows and computations.

    The key API concepts include:

    * **workflow-specs**: A workflow-spec is a workflow specification defining
      all the computation specifications which form the workflow. A workflow
      specification also defines the edges which connect computations together
      in a graph. These edges connect an output from one computation
      specification to the input of another.
      A number of default 'system' workflow specifications are provided to the
      user. Details of these 'system' workflow specifications can be discovered
      by using the API to get all workflow specifications.

    * **computation-specs**: A computation-spec is a computation specification
      which defines all the input and output data-types for the computation.
      A number of default 'system' computation specifications are provided to
      the user.  Details of these 'system' computation specifications can be
      discovered by using the API to get all computation specifications.

    * **data-types**: A data-type is a specification for a data representation
      which is required as one of a computation-spec's inputs or produced as
      one of a computation-spec's outputs.
      A number of default 'system' data-types are provided to the user. Details
      of these 'system' data-types can be discovered by using the API to get all
      data-types.

    * **computation**: A computation is an instance of a computation-spec for a
      running workflow. It encapsulates the state of the computation
      (i.e. running, succeeded), input/output data containers which have been
      associated with the computation and any errors which have occurred during
      the running of the computation. The input and output data containers
      associated with the computation can be accessed through the containers API
      operations.

    * **container**: A container is a resource which holds all the data for a
      given data-type definition.

    * **schema**: A schema is a formal description of a data-type. It defines
      the structure of the data-type against which data can be validated.
      A number of default schemas for 'system' data-types are provided for the
      user.
      Currently only JSON schemas are supported, for more information see
      [JSON Schema](https://json-schema.org/).
      Schemas defined in the OSDU schema service may be used to describe
      evaluation data-types by using their unique identifiers in schema
      references, e.g. osdu:wks:wellbore:1.0.0.

    Below is the list of Client IDs for FDPlan Services.
    ```plain {% title="Client ID" %}
    prod-nam-services-fdplan.slbservice.com
    prod-eu-services-fdplan.slbservice.com
    prod-au-services-fdplan.slbservice.com
    prod-id-services-fdplan.slbservice.com
    production-services-fdplan.slbservice.com
    ```
paths:
  /workflow-specs:
    get:
      tags:
        - WorkflowSpecs
      summary: Get all workflow specifications
      description: >-
        Get all workflow specifications. The parameter 'IncludePreviousVersions'
        may be used to return either the most recent versions of the workflow
        specifications or all possible versions of each workflow specification.
      operationId: getWorkflowSpecs
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - $ref: '#/components/parameters/IncludePreviousVersions'
      responses:
        '200':
          description: Retrieved workflow specifications successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowSpecs'
        '204':
          description: No workflow specifications were found.
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    post:
      tags:
        - WorkflowSpecs
      summary: Create workflow specification
      description: >-
        Create workflow specification. The create request must contain all the
        computation specifications which are to make up the workflow
        specification. These computation specifications must have previously
        been created. The request must also contain all the edges which connect
        the computation specifications together. The edges describe the flow of
        data from one computation specifications output data-type to another
        computation specifications input data-type. As an example, a workflow
        specification could consist of two computation specifications connected
        together. The connection between the two computation specifications
        could consist of the first output data-type from the first computation
        specification being connected to the first input data-type of the second
        computation specification. If the two computation specifications being
        connected together were the 'ix' and 'peep' computation specifications,
        the output data-type 'production-forecast' of the 'ix' computation
        specification would be connected to the input data-type
        'production-forecast' of the 'peep' computation specification. As the
        'production-forecast' data-type is the first output data-type (zeroth
        index) in the 'ix' computation specification and the first input
        data-type (zeroth index) in the 'peep' computation specification, the
        workflow edge would be defined as going from the index zero output
        data-type of the computation specification with index zero (the 'ix'
        computation specification) to  the index zero output data-type of the
        computation index with index one (the 'peep' computation index). The
        order of the computation specifications provided in the creation of the
        workflow specification is maintained in the created workflow
        specification and may only be changed through performing PATCH
        operations on the workflow specification.
      operationId: postWorkflowSpec
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateWorkflowSpec'
        description: The workflow specification to be created.
        required: true
      responses:
        '201':
          description: Workflow specification created successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowSpec'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /workflow-specs/{workflowSpecId}:
    get:
      tags:
        - WorkflowSpecs
      summary: Get a workflow specification
      description: Get a workflow specification.
      operationId: getWorkflowSpec
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The workflow specification ID.
          name: workflowSpecId
          x-nullable: false
          schema:
            type: string
        - in: query
          description: >-
            The id of the data-type to get. If not specified, the latest version
            will be returned.
          name: version
          x-nullable: false
          schema:
            type: integer
            format: int32
      responses:
        '200':
          description: Retrieved workflow specification successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowSpec'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The workflow specification was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    put:
      tags:
        - WorkflowSpecs
      summary: Create or update workflow specification
      description: >-
        Create or update workflow specification. The request must contain all
        the computation specifications which are to make up the workflow
        specification. These computation specifications must have previously
        been created. The request must also contain all the edges which connect
        the computation specifications together. The edges describe the flow of
        data from one computation specifications output data-type to another
        computation specifications input data-type. As an example, a workflow
        specification could consist of two computation specifications connected
        together. The connection between the two computation specifications
        could consist of the first output data-type from the first computation
        specification being connected to the first input data-type of the second
        computation specification. If the two computation specifications being
        connected together were the 'ix' and 'peep' computation specifications,
        the output data-type 'production-forecast' of the 'ix' computation
        specification would be connected to the input data-type
        'production-forecast' of the 'peep' computation specification. As the
        'production-forecast' data-type is the first output data-type (zeroth
        index) in the 'ix' computation specification and the first input
        data-type (zeroth index) in the 'peep' computation specification, the
        workflow edge would be defined as going from the index zero output
        data-type of the computation specification with index zero (the 'ix'
        computation specification) to  the index zero output data-type of the
        computation index with index one (the 'peep' computation index). The
        order of the computation specifications provided in the creation of the
        workflow specification is maintained in the created workflow
        specification and may be changed through performing PATCH or PUT
        operations on the workflow specification.
      operationId: putWorkflowSpec
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The workflow specification ID.
          name: workflowSpecId
          x-nullable: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ReplaceWorkflowSpec'
        description: The workflow specification to be created.
        required: true
      responses:
        '200':
          description: Workflow specification updated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowSpec'
        '201':
          description: Workflow specification created successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowSpec'
        '400':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    patch:
      tags:
        - WorkflowSpecs
      summary: Update a workflow specification
      description: >-
        Update a workflow specification. It is only possible to update the
        "name", "description", "archived", "computationSpecs", "edges" and
        "annotations" fields of the workflow specification.
      operationId: patchWorkflowSpec
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The workflow specification ID.
          name: workflowSpecId
          x-nullable: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PatchReq'
        description: >-
          The patches to apply to the workflow specification. Only "replace"
          operations are supported with the exception of "add" and "remove" for
          "annotations" path. It is only possible to update the "name",
          "description", "archived", "computationSpecs", "edges" and
          "annotations" fields of the workflow specification.
        required: true
      responses:
        '200':
          description: Workflow specification updated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowSpec'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The workflow specification was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /workflow-specs/{workflowSpecId}/computation-config:
    put:
      tags:
        - WorkflowSpecs
      summary: Create or update configuration for a computation
      description: >
        Create or update configuration properties for a computation. The
        paramaters workflowSpecId

        and computationIndex will be used to uniquely identify the configuration
        to be created or updated.


        **Note**: It is advised not to change the computation configurations
        while an evaluation is running. This might lead to unexpected evaluation
        results.
      operationId: putComputationConfig
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The workflow specification ID.
          name: workflowSpecId
          x-nullable: false
          schema:
            type: string
        - required: true
          in: query
          description: The computation index in the workflow spec.
          name: computationIndex
          x-nullable: false
          schema:
            type: number
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ComputationConfiguration'
        description: The configuration properties for a computation
        required: true
      responses:
        '204':
          description: Computation configuration created successfully.
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /computation-specs:
    get:
      tags:
        - ComputationSpecs
      summary: Get all computation specifications
      description: >-
        Get all computation specifications. The parameter
        'IncludePreviousVersions' may be used to return either the most recent
        versions of the computation specifications or all possible versions of
        each computation specification.
      operationId: getComputationSpecs
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - $ref: '#/components/parameters/IncludePreviousVersions'
      responses:
        '200':
          description: Retrieved computation specifications successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ComputationSpecs'
        '204':
          description: No computation specifications were found.
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    post:
      tags:
        - ComputationSpecs
      summary: Create a computation specification
      description: >-
        Create a computation specification. The create request must contain all
        the input and output data-type IDs which are used to define the
        computation specification. These data-types must have previously been
        created. As an example, a computation specification could be defined as
        a specification for a compute which takes two pieces of input data and
        calculates a single piece of output data. The specification for this
        compute would take two input data-types and output a single output
        data-type. The order of the input and output data-type IDs provided in
        the creation of the computation specification is maintained in the
        created computation specification and may only be changed through
        performing PATCH operations on the computation specification.
      operationId: postComputationSpec
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateComputationSpec'
        description: The computation specification to be created.
        required: true
      responses:
        '201':
          description: Computation specification created successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ComputationSpec'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /computation-specs/{computationSpecId}:
    get:
      tags:
        - ComputationSpecs
      summary: Get computation specification
      description: Get computation specification.
      operationId: getComputationSpec
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The computation specification ID.
          name: computationSpecId
          x-nullable: false
          schema:
            type: string
        - in: query
          description: >-
            The id of the data-type to get. If not specified, the latest version
            will be returned.
          name: version
          x-nullable: false
          schema:
            type: integer
            format: int32
      responses:
        '200':
          description: Retrieved computation specification successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ComputationSpec'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The computation specification was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    put:
      tags:
        - ComputationSpecs
      summary: Create or update a computation specification
      description: >-
        Create or update a computation specification. The request must contain
        all the input and output data-type IDs which are used to define the
        computation specification. These data-types must have previously been
        created. As an example, a computation specification could be defined as
        a specification for a compute which takes two pieces of input data and
        calculates a single piece of output data. The specification for this
        compute would take two input data-types and output a single output
        data-type.
      operationId: putComputationSpec
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The computation specification ID.
          name: computationSpecId
          x-nullable: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ReplaceComputationSpec'
        description: The computation specification to be created or updated.
        required: true
      responses:
        '200':
          description: Computation specification updated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ComputationSpec'
        '201':
          description: Computation specification created successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ComputationSpec'
        '400':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    patch:
      tags:
        - ComputationSpecs
      summary: Update computation specification
      description: >-
        Update computation specification. It is only possible to update the
        "name", "description", "archived", "inputDataTypeIds",
        "outputDataTypeIds" and "annotations" fields of the computation
        specification.
      operationId: patchComputationSpec
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The computation specification ID.
          name: computationSpecId
          x-nullable: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PatchReq'
        description: >-
          The patches to apply to the computation specification. Only "replace"
          operations are supported with the exception of "add" and "remove" for
          "annotations" path. It is only possible to update the "name",
          "description", "archived", "inputDataTypeIds", "outputDataTypeIds" and
          "annotations" fields of the computation specification.
        required: true
      responses:
        '200':
          description: Computation specification updated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ComputationSpec'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The computation specification was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /data-types:
    get:
      tags:
        - DataTypes
      summary: Get all data-types
      description: >-
        Get all data-types. The parameter 'IncludePreviousVersions' may be used
        to return either the most recent versions of the data-types or all
        possible versions of each data-type.
      operationId: getDataTypes
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - $ref: '#/components/parameters/IncludePreviousVersions'
      responses:
        '200':
          description: Retrieved data-types successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataTypes'
        '204':
          description: No data-types were found.
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    post:
      tags:
        - DataTypes
      summary: Create data-type
      description: >-
        Create data-type. The create request must contain all the file types
        which are to be associated with the data-type. For example, if the
        data-type was to allow the use of JSON documents then the request would
        list it as a file specification.
      operationId: postDataType
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateDataType'
        description: The data-type to be created.
        required: true
      responses:
        '201':
          description: Data-type created successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataType'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /data-types/{dataTypeId}:
    get:
      tags:
        - DataTypes
      summary: Get a data-type
      description: Get a data-type.
      operationId: getDataType
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The data-type ID.
          name: dataTypeId
          x-nullable: false
          schema:
            type: string
        - in: query
          description: >-
            The id of the data-type to get. If not specified, the latest version
            will be returned.
          name: version
          x-nullable: false
          schema:
            type: integer
            format: int32
      responses:
        '200':
          description: Retrieved data-type successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataType'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The data-type was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    put:
      tags:
        - DataTypes
      summary: Create or update data-type
      description: |
        Create or update data-type. The request must contain all the file types
        which are to be associated with the data-type. For example, if
        the data-type was to allow the use of JSON documents then the request
        would list it as a file specification.
      operationId: putDataType
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The data-type ID.
          name: dataTypeId
          x-nullable: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ReplaceDataType'
        description: The data-type to be updated or created.
        required: true
      responses:
        '200':
          description: Data-type updated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataType'
        '201':
          description: Data-type created successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataType'
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    patch:
      tags:
        - DataTypes
      summary: Update a data-type
      description: >-
        Update a data-type. It is only possible to update the "name",
        "description", "archived", and "fileSpecs" fields of the data-type.
      operationId: patchDataType
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The data-type ID.
          name: dataTypeId
          x-nullable: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PatchReq'
        description: >-
          The patches to apply to the data-type. Only "replace" operations are
          supported. It is only possible to update the "name", "description",
          "archived" and "fileSpecs" fields of the data-type.
        required: true
      responses:
        '200':
          description: Data-type updated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataType'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The data-type was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /computations/{computationId}:
    get:
      tags:
        - Computations
      summary: Get a computation
      description: >-
        Get a computation given the computation ID. The computation contains the
        state of the computation (i.e. running, succeeded), input/output data
        containers which has been associated with the computation and any errors
        which have occurred during the running of the computation. The input and
        output data containers associated with the computation can be accessed
        through the containers API operations.

        Computations external to FDPlan can discover when computations are
        required to be performed by querying the FDPlan Events API for events
        with the type
        'com.slb.cloud.fdplan.evaluation.computation_required_{computation_spec_id}_v{computation_spec_version}.v1',
        for instance
        'com.slb.cloud.fdplan.evaluation.computation_required_ix_v1.v1'. The
        data for this event type contains information on the computation which
        is required.
      operationId: getComputation
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The ID of the computation.
          name: computationId
          schema:
            type: string
        - in: query
          description: Flag will include data-link.json content encoded as base64.
          name: includeDataLinkContent
          schema:
            type: boolean
            default: false
      responses:
        '200':
          description: Retrieved computation successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Computation'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The computation was not found.
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /computations/{computationId}/status:
    post:
      tags:
        - Computations
      summary: Set status of computation
      description: Set status of computation given the computation ID.
      operationId: postComputationStatus
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The ID of the computation.
          name: computationId
          x-nullable: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SetComputationStatus'
        description: The details of the computation status to be set.
        required: true
      responses:
        '201':
          description: Computation status updated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Computation'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The computation was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /containers/{containerId}:
    get:
      tags:
        - Containers
      summary: Get container
      description: >-
        Get container given the container ID. The container ID associated with a
        given computation can be accessed through the computations API
        operations.
      operationId: getContainer
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The ID of the container.
          name: containerId
          schema:
            type: string
        - in: query
          description: Flag will include data-link.json content encoded as base64.
          name: includeDataLinkContent
          schema:
            type: boolean
            default: false
      responses:
        '200':
          description: Retrieved container successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Container'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The container was not found.
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /containers/{containerId}/files:
    post:
      tags:
        - Containers
      summary: Upload file associated with a container
      description: Upload file associated with a container.
      operationId: postContainerFile
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The ID of the container
          name: containerId
          schema:
            type: string
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                uploadFile:
                  description: The file to upload.
                  type: string
                  format: binary
              required:
                - uploadFile
        required: true
      responses:
        '201':
          description: File uploaded successfully.
          content:
            application/octet-stream:
              schema:
                $ref: '#/components/schemas/CreateContainerFileResponse'
        '401':
          description: Unauthorized.
          content:
            application/octet-stream:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/octet-stream:
              schema:
                $ref: '#/components/schemas/Error'
  /containers/{containerId}/files/{fileName}:
    get:
      tags:
        - Containers
      summary: Get a file associated with a container
      description: >-
        Get a file associated with a container. The MIME type will be set
        according to the data-type.
      operationId: getContainerFile
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The name of the file.
          name: fileName
          schema:
            type: string
        - required: true
          in: path
          description: The ID of the container.
          name: containerId
          schema:
            type: string
      responses:
        '200':
          description: File retrieved successfully.
          content:
            application/octet-stream:
              schema:
                type: string
                format: binary
        '401':
          description: Unauthorized.
          content:
            application/octet-stream:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/octet-stream:
              schema:
                $ref: '#/components/schemas/Error'
  /containers/{containerId}/files/{fileName}/download-url:
    get:
      tags:
        - Containers
      summary: Get a signed url which can be used to download a file.
      description: >-
        Generate a signed url which can be used for downloading a specified
        file.
      operationId: getDownloadSignedURL
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The name of the file.
          name: fileName
          schema:
            type: string
        - required: true
          in: path
          description: The ID of the container.
          name: containerId
          schema:
            type: string
      responses:
        '200':
          description: Download Signed URL generation successful.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SignedURLResponse'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The file was not found error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /containers/{containerId}/files/{fileName}/upload-url:
    get:
      tags:
        - Containers
      summary: Get a signed url which can be used to upload a file.
      description: Generate a signed url which can be used for uploading a specified file.
      operationId: getUploadSignedURL
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The name of the file.
          name: fileName
          schema:
            type: string
        - required: true
          in: path
          description: The ID of the container
          name: containerId
          schema:
            type: string
      responses:
        '200':
          description: Upload signed URL generation successful.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SignedURLResponse'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The container was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
  /schemas/{schemaId}:
    get:
      tags:
        - Schemas
      summary: Get schema
      description: Get a schema given its schema ID.
      operationId: getSchema
      parameters:
        - $ref: '#/components/parameters/SlbDataPartitionId'
        - required: true
          in: path
          description: The ID of the schema.
          name: schemaId
          schema:
            type: string
      responses:
        '200':
          description: Retrieved schema successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Schema'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: The schema was not found.
        default:
          description: Unexpected error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
security:
  - bearer: []
    appkey: []
tags:
  - name: WorkflowSpecs
    description: Creating, getting and updating workflow-specifications.
  - name: ComputationSpecs
    description: Creating, getting and updating computation-specifications.
  - name: DataTypes
    description: Creating, getting and updating data-types.
  - name: Computations
    description: Managing computation state.
  - name: Containers
    description: Getting and updating containers.
  - name: Schemas
    description: Getting schema for data-types.
servers:
  - url: https://api.delfi.slb.com/fdplan/evaluation/v1
components:
  parameters:
    SlbDataPartitionId:
      required: true
      in: header
      description: Data partition id.
      name: slb-data-partition-id
      schema:
        type: string
    IncludePreviousVersions:
      in: query
      description: >-
        Unless includePreviousVersions is true the response will return only the
        latest version of each specification.
      name: includePreviousVersions
      x-nullable: false
      schema:
        type: boolean
  securitySchemes:
    bearer:
      type: apiKey
      name: Authorization
      in: header
    appkey:
      type: apiKey
      name: appkey
      in: header
  schemas:
    Error:
      description: Generic error response.
      required:
        - data
      type: object
      properties:
        data:
          required:
            - code
          type: object
          properties:
            code:
              format: int32
              description: The HTTP status code.
              type: integer
              example: 500
              nullable: false
            message:
              description: The error message.
              type: string
              example: internal server error
      example:
        data:
          code: 500
          message: internal server error
    PatchReq:
      type: array
      items:
        $ref: '#/components/schemas/PatchItem'
      example:
        - op: replace
          path: description
          value: Description
        - op: replace
          path: archived
          value: false
    PatchItem:
      description: A JSON patch document as defined by RFC 6902.
      required:
        - op
        - path
      type: object
      properties:
        op:
          description: The operation to be performed.
          enum:
            - replace
            - add
            - remove
          type: string
          example: replace
          nullable: false
        path:
          description: A JSON-Pointer.
          type: string
          example: description
          nullable: false
        value:
          description: The value to be used within the operations.
          type: object
          example: Description
        from:
          description: A string containing a JSON Pointer value.
          type: string
          nullable: false
      example:
        op: replace
        path: description
        value: Description
    ReplaceSpec:
      required:
        - id
        - name
        - description
        - version
      type: object
      properties:
        id:
          description: >
            The id of the specification. The id should be of the form

            '{authority}:{spec-type}:{id}', where '{authority}' is the owning

            authority of the specification, '{spec-type}' is one of
            'data-types',

            'computation-specs' or 'workflow-specs'.
          pattern: >-
            ^[a-z]([a-z0-9]|-)*[a-z0-9]:(data-types|computation-specs|workflow-specs):[a-z]([a-z0-9]|-)*[a-z0-9]$
          type: string
          example: slb:data-types:custom-specification
          nullable: false
        name:
          description: The name of the specification.
          type: string
          example: A custom data-type
          nullable: false
        version:
          description: The version of the specification definition.
          type: integer
          example: 1
          nullable: false
        archived:
          description: Whether this specification has been marked as archived.
          type: boolean
          example: false
          nullable: false
        description:
          description: The description of the specification.
          type: string
          example: A specification
          nullable: false
      example:
        id: 01DV2RPKYS5NYBAR6TNMJ8TNT8
        name: spec-type
        version: 1
        archived: false
        description: A specification.
    Spec:
      required:
        - id
        - name
        - version
        - latest
        - archived
        - description
        - createdBy
        - createdAt
      type: object
      properties:
        id:
          description: The ID of the specification.
          type: string
          example: 01DV2RPKYS5NYBAR6TNMJ8TNT8
          nullable: false
        name:
          description: The name of the specification.
          type: string
          example: A custom data-type
          nullable: false
        version:
          description: The version of the specification definition.
          type: integer
          example: 1
          nullable: false
        latest:
          description: Whether this is the latest version of the given specification.
          type: boolean
          example: true
          nullable: false
        archived:
          description: Whether this specification has been marked as archived.
          type: boolean
          example: false
          nullable: false
        description:
          description: The description of the specification.
          type: string
          example: A specification
          nullable: false
        createdBy:
          description: The ID of the user who created the specification.
          type: string
          example: user@slb.com
          nullable: false
        createdAt:
          format: date-time
          description: The date the specification was created.
          type: string
          example: '2020-01-01T00:00:00.000Z'
          nullable: false
      example:
        id: 01DV2RPKYS5NYBAR6TNMJ8TNT8
        name: spec-type
        version: 1
        latest: true
        archived: false
        description: A specification.
        createdBy: user@slb.com
        createdAt: '2020-01-01T00:00:00.000Z'
    DataTypes:
      description: A list of data-types.
      type: array
      items:
        $ref: '#/components/schemas/DataType'
      example:
        - id: decline-curves
          name: decline-curves
          description: Decline Curves
          version: 1
          fileSpecs:
            - extension: json
        - id: facility-constraints
          name: facility-constraints
          description: Facility Constraints
          version: 1
          fileSpecs:
            - extension: json
    DataType:
      description: An evaluation data-type.
      allOf:
        - $ref: '#/components/schemas/Spec'
        - type: object
          properties:
            fileSpecs:
              description: >-
                Specification of the file types allowed to be used with this
                container.
              type: array
              items:
                $ref: '#/components/schemas/FileSpec'
              example:
                - extension: xlsx
                - extension: json
                  schemaRef:
                    id: planning:fdplan:result-set:0.0.1
                    type: JSON
                  defaultFilename: filename.json
      example:
        id: 01DV2RPKYS5NYBAR6TNMJ8TNT8
        name: custom-data-type
        version: 1
        latest: true
        archived: false
        description: Description
        createdBy: user@slb.com
        createdAt: '2020-01-01T00:00:00.000Z'
        fileSpecs:
          - extension: json
            schemaRef:
              id: planning:fdplan:result-set:0.0.1
              type: JSON
            defaultFilename: filename.json
          - extension: xlsx
    SchemaRef:
      description: A schema reference.
      required:
        - id
        - type
      type: object
      properties:
        id:
          description: The unique idenitifer for the schema.
          type: string
          example: planning:fdplan:result-set:0.0.1
          nullable: false
        type:
          description: The type of schema, for instance JSON schema.
          enum:
            - JSON
          type: string
          example: JSON
          nullable: false
      example:
        id: planning:fdplan:result-set:0.0.1
        type: JSON
    Schema:
      description: A schema.
      required:
        - id
        - type
        - definition
      type: object
      properties:
        id:
          description: The unique idenitifer for the schema.
          type: string
          example: planning:fdplan:result-set:0.0.1
          nullable: false
        type:
          description: The type of schema, for instance JSON schema.
          enum:
            - JSON
          type: string
          example: JSON
          nullable: false
        definition:
          description: The schema definition.
          type: object
          example: {}
          nullable: false
      example:
        id: planning:fdplan:result-set:0.0.1
        type: JSON
        definition: {}
    ComputationSpecs:
      description: A list of computation specifications.
      type: array
      items:
        $ref: '#/components/schemas/ComputationSpec'
      example:
        - id: ix
          latest: true
          name: ix
          createdBy: system
          version: 1
          inputDataTypeIds:
            - id: decline-curves
              version: 1
            - id: drilling-constraints
              version: 1
            - id: facility-constraints
              version: 1
          outputDataTypeIds:
            - id: production-forecast
              version: 1
        - id: peep
          latest: true
          name: peep
          createdBy: system
          version: 1
          inputDataTypeIds:
            - id: production-forecast
              version: 1
            - id: well-capex
              version: 1
            - id: general-capex
              version: 1
            - id: general-opex
              version: 1
            - id: economic-framework
              version: 1
          outputDataTypeIds:
            - id: peep-output
              version: 1
    ComputationSpec:
      description: >-
        An evaluation computation specification. The specification details the
        input data-types to the computation specification and the computed
        output data-types.
      allOf:
        - $ref: '#/components/schemas/Spec'
        - required:
            - inputDataTypeIds
            - outputDataTypeIds
          type: object
          properties:
            inputDataTypeIds:
              description: The input data-type IDs for the computation specification.
              type: array
              items:
                $ref: '#/components/schemas/VersionId'
              example:
                - id: decline-curves
                  version: 1
                - id: drilling-constraints
                  version: 1
                - id: facility-constraints
                  version: 1
            outputDataTypeIds:
              description: 'The output data-type IDs for the computation specification. '
              type: array
              items:
                $ref: '#/components/schemas/VersionId'
              example:
                - id: production-forecast
                  version: 1
            annotations:
              description: >-
                The annotations for the computation specification. These
                annotations can be used to annotate the computation
                specification with useful information such as a 'name'.
              type: array
              items:
                $ref: '#/components/schemas/Annotation'
              example:
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 0
                  key: name
                  value: Decline Curves
                  createdBy: user@slb.com
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 1
                  key: name
                  value: Drilling Constraints
                  createdBy: user@slb.com
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 2
                  key: name
                  value: Facility Constraints
                  createdBy: user@slb.com
                - address:
                    type: DataTypeOutput
                    computationIndex: 0
                    dataTypeIndex: 0
                  key: name
                  value: Production Forecast
                  createdBy: user@slb.com
              nullable: false
      example:
        id: 01DV2RPKYS5NYBAR6TNMJ8TNT8
        name: custom-computation-spec
        version: 1
        latest: true
        archived: false
        description: Description
        createdBy: user@slb.com
        createdAt: '2020-01-01T00:00:00.000Z'
        inputDataTypeIds:
          - id: decline-curves
            version: 1
          - id: drilling-constraints
            version: 1
          - id: facility-constraints
            version: 1
        outputDataTypeIds:
          - id: production-forecast
            version: 1
        annotations:
          - address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 0
            key: name
            value: Decline Curves
            createdBy: user@slb.com
          - address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 1
            key: name
            value: Drilling Constraints
            createdBy: user@slb.com
          - address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 2
            key: name
            value: Facility Constraints
            createdBy: user@slb.com
          - address:
              type: DataTypeOutput
              computationIndex: 0
              dataTypeIndex: 0
            key: name
            value: Production Forecast
            createdBy: user@slb.com
    WorkflowSpecs:
      description: A list of workflow specifications.
      type: array
      items:
        $ref: '#/components/schemas/WorkflowSpec'
      example:
        - id: id
          createdBy: system
          name: Well driven
          description: Well driven
          latest: true
          version: 1
          computationSpecs:
            - id: ix
              latest: true
              name: ix
              createdBy: system
              version: 1
              address:
                - computationIndex: 0
                  type: Computation
              inputDataTypeIds:
                - id: decline-curves
                  version: 1
                  address:
                    - computationIndex: 0
                      dataTypeIndex: 0
                      type: DataTypeInput
                - id: drilling-constraints
                  version: 1
                  address:
                    - computationIndex: 0
                      dataTypeIndex: 1
                      type: DataTypeInput
                - id: facility-constraints
                  version: 1
                  address:
                    - computationIndex: 0
                      dataTypeIndex: 2
                      type: DataTypeInput
              outputDataTypeIds:
                - id: production-forecast
                  version: 1
                  address:
                    type: DataTypeOutput
                    computationIndex: 0
                    dataTypeIndex: 0
            - id: peep
              latest: true
              name: peep
              createdBy: system
              version: 1
              address:
                - computationIndex: 1
                  type: Computation
              inputDataTypeIds:
                - id: production-forecast
                  version: 1
                  address:
                    - computationIndex: 1
                      dataTypeIndex: 0
                      type: DataTypeInput
                - id: well-capex
                  version: 1
                  address:
                    - computationIndex: 1
                      dataTypeIndex: 1
                      type: DataTypeInput
                - id: general-capex
                  version: 1
                  address:
                    - computationIndex: 1
                      dataTypeIndex: 2
                      type: DataTypeInput
                - id: general-opex
                  version: 1
                  address:
                    - computationIndex: 1
                      dataTypeIndex: 3
                      type: DataTypeInput
                - id: economic-framework
                  version: 1
                  address:
                    - computationIndex: 1
                      dataTypeIndex: 4
                      type: DataTypeInput
              outputDataTypeIds:
                - id: peep-output
                  version: 1
                  address:
                    - computationIndex: 1
                      dataTypeIndex: 0
                      type: DataTypeOutput
          edges:
            - fromAddressType: DataTypeOutput
              fromComputationIndex: 0
              fromDataTypeIndex: 0
              toComputationIndex: 1
              toDataTypeIndex: 0
    WorkflowSpec:
      description: An evaluation workflow specification.
      allOf:
        - $ref: '#/components/schemas/Spec'
        - required:
            - computationSpecs
          type: object
          properties:
            computationSpecs:
              description: >-
                The computation specifications which make up the workflow
                specification.
              type: array
              items:
                $ref: '#/components/schemas/WorkflowComputationSpec'
              example:
                - id: 01DV2RPKYS5NYBAR6TNMJ8TNT8
                  name: spec-type
                  version: 1
                  latest: true
                  archived: false
                  description: A specification.
                  createdBy: user@slb.com
                  createdAt: '2020-01-01T00:00:00.000Z'
                  address:
                    type: Computation
                    computationIndex: 0
                    dataTypeIndex: 0
                  inputDataTypeIds:
                    - id: decline-curves
                      version: 1
                      address:
                        type: DataTypeInput
                        computationIndex: 0
                        dataTypeIndex: 0
                    - id: facility-constraints
                      version: 1
                      address:
                        type: DataTypeInput
                        computationIndex: 0
                        dataTypeIndex: 1
                  outputDataTypeIds:
                    - id: production-forecast
                      version: 1
                      address:
                        type: DataTypeOutput
                        computationIndex: 0
                        dataTypeIndex: 0
            edges:
              description: >-
                A list of graph edges which describe the data flow from one
                computation specifications output data-type to the next
                computation specifications input data-type.
              type: array
              items:
                $ref: '#/components/schemas/Edge'
              example:
                - fromAddressType: DataTypeOutput
                  fromComputationIndex: 0
                  fromDataTypeIndex: 0
                  toComputationIndex: 1
                  toDataTypeIndex: 0
            annotations:
              type: array
              items:
                $ref: '#/components/schemas/Annotation'
              example:
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 0
                  key: name
                  value: Decline Curves
                  createdBy: user@slb.com
              nullable: false
      example:
        id: 01DV2RPKYS5NYBAR6TNMJ8TNT8
        name: custom-workflow-spec
        version: 1
        latest: true
        archived: false
        description: Description
        createdBy: user@slb.com
        createdAt: '2020-01-01T00:00:00.000Z'
        computationSpecs:
          - id: ix
            name: ix
            version: 1
            latest: true
            archived: false
            description: A specification.
            createdBy: system
            createdAt: '2020-01-01T00:00:00.000Z'
            address:
              type: Computation
              computationIndex: 0
              dataTypeIndex: 0
            inputDataTypeIds:
              - id: decline-curves
                version: 1
                address:
                  - computationIndex: 0
                    dataTypeIndex: 0
                    type: DataTypeInput
              - id: drilling-constraints
                version: 1
                address:
                  - computationIndex: 0
                    dataTypeIndex: 1
                    type: DataTypeInput
              - id: facility-constraints
                version: 1
                address:
                  - computationIndex: 0
                    dataTypeIndex: 2
                    type: DataTypeInput
            outputDataTypeIds:
              - id: production-forecast
                version: 1
                address:
                  type: DataTypeOutput
                  computationIndex: 0
                  dataTypeIndex: 0
          - id: peep
            name: peep
            version: 1
            latest: true
            archived: false
            description: A specification.
            createdBy: system
            createdAt: '2020-01-01T00:00:00.000Z'
            address:
              type: Computation
              computationIndex: 0
              dataTypeIndex: 0
            inputDataTypeIds:
              - id: production-forecast
                version: 1
                address:
                  - computationIndex: 1
                    dataTypeIndex: 0
                    type: DataTypeInput
              - id: well-capex
                version: 1
                address:
                  - computationIndex: 1
                    dataTypeIndex: 1
                    type: DataTypeInput
              - id: general-capex
                version: 1
                address:
                  - computationIndex: 1
                    dataTypeIndex: 2
                    type: DataTypeInput
              - id: general-opex
                version: 1
                address:
                  - computationIndex: 1
                    dataTypeIndex: 3
                    type: DataTypeInput
              - id: economic-framework
                version: 1
                address:
                  - computationIndex: 1
                    dataTypeIndex: 4
                    type: DataTypeInput
            outputDataTypeIds:
              - id: peep-output
                version: 1
                address:
                  type: DataTypeOutput
                  computationIndex: 1
                  dataTypeIndex: 0
        edges:
          - fromAddressType: DataTypeOutput
            fromComputationIndex: 0
            fromDataTypeIndex: 0
            toComputationIndex: 1
            toDataTypeIndex: 0
    CreateSpec:
      required:
        - name
        - description
      type: object
      properties:
        id:
          description: >
            The optional id of the specification. The id should be of the form

            '{authority}:{spec-type}:{id}', where '{authority}' is the owning

            authority of the specification, '{spec-type}' is one of
            'data-types',

            'computation-specs' or 'workflow-specs'.
          pattern: >-
            ^[a-z]([a-z0-9]|-)*[a-z0-9]:(data-types|computation-specs|workflow-specs):[a-z]([a-z0-9]|-)*[a-z0-9]$
          type: string
          example: slb:data-types:custom-specification
        name:
          description: The name of the specification.
          type: string
          example: custom-specification
          nullable: false
        description:
          description: The description of the specification.
          type: string
          example: Custom specification.
          nullable: false
      example:
        name: spec
        description: Description
    CreateDataType:
      description: Create data-type request.
      allOf:
        - $ref: '#/components/schemas/CreateSpec'
        - type: object
          properties:
            fileSpecs:
              type: array
              items:
                $ref: '#/components/schemas/FileSpec'
              example:
                - extension: json
                  schemaRef:
                    id: planning:fdplan:result-set:0.0.1
                    type: JSON
                  defaultFilename: filename.json
                - extension: xlsx
      example:
        id: slb:data-types:custom-data-type
        name: custom-data-type
        description: Description
        fileSpecs:
          - extension: json
            schemaRef:
              id: planning:fdplan:result-set:0.0.1
              type: JSON
            defaultFilename: filename.json
          - extension: xlsx
    ReplaceDataType:
      description: Replace data-type request.
      allOf:
        - $ref: '#/components/schemas/ReplaceSpec'
        - type: object
          properties:
            fileSpecs:
              type: array
              items:
                $ref: '#/components/schemas/FileSpec'
              example:
                - extension: json
                  schemaRef:
                    id: planning:fdplan:result-set:0.0.1
                    type: JSON
                  defaultFilename: filename.json
                - extension: xlsx
      example:
        id: slb:data-types:custom-data-type
        version: 1
        name: custom-data-type
        description: Description
        archived: false
        fileSpecs:
          - extension: json
            schemaRef:
              id: planning:fdplan:result-set:0.0.1
              type: JSON
            defaultFilename: filename.json
          - extension: xlsx
    CreateComputationSpec:
      description: Create computation specification request.
      allOf:
        - $ref: '#/components/schemas/CreateSpec'
        - required:
            - inputDataTypeIds
            - outputDataTypeIds
          type: object
          properties:
            inputDataTypeIds:
              description: >-
                The input data-type IDs for the computation specification.
                These  data-types must have already been previously created. The
                order of the input data-type IDs is maintained in the created
                computation specification. Note that specific versions of a
                data-type can be specified by using the format 'id:version'.
              type: array
              items:
                type: string
              example:
                - decline-curves
                - drilling-constraints
                - facility-constraints"
            outputDataTypeIds:
              description: >-
                The output data-type IDs for the computation specification.
                These data-types must have already been previously created. The
                order of the output data-type IDs is maintained in the created
                computation specification. Note that specific versions of a
                data-type can be specified by using the format 'id:version'.
              type: array
              items:
                type: string
              example:
                - production-forecast
            annotations:
              description: The annotations for the computation specification.
              type: array
              items:
                $ref: '#/components/schemas/Annotation'
              example:
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 0
                  key: name
                  value: Decline Curves
                  createdBy: user@slb.com
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 1
                  key: name
                  value: Drilling Constraints
                  createdBy: user@slb.com
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 2
                  key: name
                  value: Facility Constraints
                  createdBy: user@slb.com
                - address:
                    type: DataTypeOutput
                    computationIndex: 0
                    dataTypeIndex: 0
                  key: name
                  value: Production Forecast
                  createdBy: user@slb.com
              nullable: false
      example:
        id: slb:computation-specs:custom-computation-spec
        name: custom-computation-spec
        description: Description
        inputDataTypeIds:
          - decline-curves
          - drilling-constraints
          - facility-constraints
        outputDataTypeIds:
          - production-forecast
        annotations:
          - address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 0
            key: name
            value: Decline Curves
            createdBy: user@slb.com
          - address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 1
            key: name
            value: Drilling Constraints
            createdBy: user@slb.com
          - address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 2
            key: name
            value: Facility Constraints
            createdBy: user@slb.com
          - address:
              type: DataTypeOutput
              computationIndex: 0
              dataTypeIndex: 0
            key: name
            value: Production Forecast
            createdBy: user@slb.com
    ReplaceComputationSpec:
      description: Create or update computation specification request.
      allOf:
        - $ref: '#/components/schemas/ReplaceSpec'
        - required:
            - inputDataTypeIds
            - outputDataTypeIds
          type: object
          properties:
            inputDataTypeIds:
              description: The input data-type IDs for the computation specification.
              type: array
              items:
                $ref: '#/components/schemas/VersionId'
              example:
                - id: decline-curves
                  version: 1
                - id: drilling-constraints
                  version: 1
                - id: facility-constraints
                  version: 1
            outputDataTypeIds:
              description: The output data-type IDs for the computation specification.
              type: array
              items:
                $ref: '#/components/schemas/VersionId'
              example:
                - id: production-forecast
                  version: 1
            annotations:
              description: The annotations for the computation specification.
              type: array
              items:
                $ref: '#/components/schemas/Annotation'
              example:
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 0
                  key: name
                  value: Decline Curves
                  createdBy: user@slb.com
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 1
                  key: name
                  value: Drilling Constraints
                  createdBy: user@slb.com
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 2
                  key: name
                  value: Facility Constraints
                  createdBy: user@slb.com
                - address:
                    type: DataTypeOutput
                    computationIndex: 0
                    dataTypeIndex: 0
                  key: name
                  value: Production Forecast
                  createdBy: user@slb.com
              nullable: false
      example:
        id: slb:computation-specs:custom-computation-spec
        name: custom-computation-spec
        description: Description
        inputDataTypeIds:
          - decline-curves
          - drilling-constraints
          - facility-constraints
        outputDataTypeIds:
          - production-forecast
        annotations:
          - address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 0
            key: name
            value: Decline Curves
            createdBy: user@slb.com
          - address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 1
            key: name
            value: Drilling Constraints
            createdBy: user@slb.com
          - address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 2
            key: name
            value: Facility Constraints
            createdBy: user@slb.com
          - address:
              type: DataTypeOutput
              computationIndex: 0
              dataTypeIndex: 0
            key: name
            value: Production Forecast
            createdBy: user@slb.com
    CreateWorkflowSpec:
      description: Create workflow specification request.
      allOf:
        - $ref: '#/components/schemas/CreateSpec'
        - required:
            - computationSpecIds
          type: object
          properties:
            computationSpecIds:
              description: >-
                The computation specification IDs which make up the workflow
                specification. These computation specifications must have
                already been previously created.  The order of the computation
                specifications is maintained in the created workflow
                specification. Note that specific versions of a computation-spec
                can be specified by using the format 'id:version'.
              type: array
              items:
                type: string
              example:
                - ix
                - peep
            edges:
              description: >-
                A list of edges which describe all the links in the workflow
                specification. The edges describe the flow of data from one 
                computation specifications output data-type to another
                computation specifications input data-type. The computation
                specifications referred to in the edges must have been
                previously created and be defined in the computationSpecIds
                property.
              type: array
              items:
                $ref: '#/components/schemas/Edge'
              example:
                - fromAddressType: DataTypeOutput
                  fromComputationIndex: 0
                  fromDataTypeIndex: 0
                  toComputationIndex: 1
                  toDataTypeIndex: 0
            annotations:
              type: array
              items:
                $ref: '#/components/schemas/Annotation'
              example:
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 0
                  key: name
                  value: Decline Curves
                  createdBy: user@slb.com
              nullable: false
      example:
        id: slb:workflow-specs:custom-workflow-spec
        name: custom-workflow-spec
        description: Description
        computationSpecIds:
          - ix
          - peep
        edges:
          - fromAddressType: DataTypeOutput
            fromComputationIndex: 0
            fromDataTypeIndex: 0
            toComputationIndex: 1
            toDataTypeIndex: 0
    ReplaceWorkflowSpec:
      description: Replace workflow specification request.
      allOf:
        - $ref: '#/components/schemas/ReplaceSpec'
        - required:
            - computationSpecs
          type: object
          properties:
            computationSpecs:
              description: >-
                The computation specifications which make up the workflow
                specification. These computation specifications must have
                already been previously created. The order of the computation
                specifications is maintained in the created/updated workflow
                specification.
              type: array
              items:
                $ref: '#/components/schemas/VersionId'
              example:
                - id: ix
                  version: 1
                - id: peep
                  version: 1
            edges:
              description: >-
                A list of edges which describe all the links in the workflow
                specification. The edges describe the flow of data from one 
                computation specifications output data-type to another
                computation specifications input data-type. The computation
                specifications referred to in the edges must have been
                previously created and be defined in the computationSpecIds
                property.
              type: array
              items:
                $ref: '#/components/schemas/Edge'
              example:
                - fromAddressType: DataTypeOutput
                  fromComputationIndex: 0
                  fromDataTypeIndex: 0
                  toComputationIndex: 1
                  toDataTypeIndex: 0
            annotations:
              type: array
              items:
                $ref: '#/components/schemas/Annotation'
              example:
                - address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 0
                  key: name
                  value: Decline Curves
                  createdBy: user@slb.com
              nullable: false
      example:
        id: slb:workflow-specs:custom-workflow-spec
        name: custom-workflow-spec
        description: Description
        computationSpecIds:
          - ix
          - peep
        edges:
          - fromAddressType: DataTypeOutput
            fromComputationIndex: 0
            fromDataTypeIndex: 0
            toComputationIndex: 1
            toDataTypeIndex: 0
    Edge:
      description: >-
        A graph edge which describes a data flow from one computation
        specifications output data-type to the next computation specifications
        input data-type. The workflow specification must have the appropriate
        computation specifications and data-types or else the edge will not be
        considered valid by the API. As an example, a workflow specification
        could consist of two computation specifications connected together. The
        connection between the two computation specifications could consist of
        the first output data-type from the first computation specification
        being connected to the first input of the second computation
        specification. This edge would be describe as:
          fromAddressType: DataTypeOutput,
          fromComputationIndex: 0,
          fromDataTypeIndex: 0,
          toComputationIndex: 1,
          toDataTypeIndex:0
      type: object
      properties:
        fromAddressType:
          description: >-
            Whether the address refers to a data-type input or data-type output 
            (defaults to output).
          default: DataTypeOutput
          enum:
            - DataTypeInput
            - DataTypeOutput
          type: string
          example: DataTypeOutput
          nullable: false
        fromComputationIndex:
          description: >-
            The zero based index of the computation specification which
            generates the data-type in the workflow specification.
          type: integer
          example: 1
          x-omitempty: false
        fromDataTypeIndex:
          description: >-
            The zero based index of the data-type as listed as an output
            data-type in computation specification referred to in the
            'fromComputationIndex' above.
          type: integer
          example: 0
          x-omitempty: false
        toComputationIndex:
          description: >-
            The zero based index of the computation specification which consumes
            the data-type in the workflow specification.
          type: integer
          example: 1
          x-omitempty: false
        toDataTypeIndex:
          description: >-
            The zero based index of the data-type as listed as an input
            data-type in the computation specification referred to in the
            'toComputationIndex' above.
          type: integer
          example: 0
          x-omitempty: false
      example:
        fromAddressType: DataTypeOutput
        fromComputationIndex: 0
        fromDataTypeIndex: 0
        toComputationIndex: 1
        toDataTypeIndex: 0
    VersionId:
      description: >-
        A specification reference which allows the API users to specify the
        version of a specification when creating or updating a parent
        specification.
      required:
        - id
        - version
      type: object
      properties:
        id:
          description: The specification ID.
          type: string
          example: 01DV2RPKYS5NYBAR6TNMJ8TNT8
          x-omitempty: false
          nullable: false
        version:
          description: The version of the specification of the given ID.
          type: integer
          example: 1
          x-omitempty: false
          nullable: false
      example:
        id: 01DV2RPKYS5NYBAR6TNMJ8TNT8
        version: 1
    SetComputationStatus:
      description: The details of the computation status to be set.
      type: object
      properties:
        status:
          description: The computation status.
          enum:
            - CompletedSuccessfully
            - CompletedWithErrors
            - Stopped
            - ProgressEvent
            - ComputationLogEvent
          type: string
          example: CompletedSuccessfully
          nullable: false
        computationErrors:
          description: >-
            The computation errors. There should not be any computation errors
            if the status of the computation is being set to
            'CompletedSuccessfully'.
          type: array
          items:
            $ref: '#/components/schemas/ComputationError'
          example:
            - addresses:
                - type: DataTypeInput
                  computationIndex: 0
                  dataTypeIndex: 0
                - type: DataTypeInput
                  computationIndex: 0
                  dataTypeIndex: 1
              message: Something went wrong.
        progressEvent:
          $ref: '#/components/schemas/ComputationProgressEventMessage'
        computationLogEvent:
          $ref: '#/components/schemas/ComputationLogEvent'
      example:
        status: CompletedWithErrors
        computationErrors:
          - addresses:
              - type: DataTypeInput
                computationIndex: 0
                dataTypeIndex: 0
              - type: DataTypeInput
                computationIndex: 0
                dataTypeIndex: 1
            message: Something went wrong.
    Computation:
      description: >-
        A computation is an instance of a computation specification which keeps
        track of a computation state as well as its input and output containers.
      required:
        - id
      type: object
      properties:
        id:
          description: The computation ID.
          type: string
          example: 0006803dc06c9bab3f82d4018287b8ccae575bd68eaa47f3c1797242e78daf03
          nullable: false
        status:
          description: The computation status.
          enum:
            - Running
            - CompletedSuccessfully
            - CompletedWithErrors
            - Stopping
            - Stopped
          type: string
          example: Running
          nullable: false
        computationSpec:
          $ref: '#/components/schemas/VersionId'
        inputContainers:
          description: A list of containers for the computation inputs.
          type: array
          items:
            $ref: '#/components/schemas/Container'
          example:
            - id: >-
                01C7VGQWGZVPSBV9NJMEAJSBGM/containers/decline-curves/01CH0K76B5ANMW149TZZEGPZFV
              dataType:
                id: decline-curves
                version: 1
                address:
                  type: DataTypeInput
                  computationIndex: 0
                  dataTypeIndex: 0
              fileNames:
                - decline_curves.json
              files:
                - name: decline_curves.json
            - id: >-
                01C7VGQWGZVPSBV9NJMEAJSBGM/containers/drilling-constraints/01CH0K76B5ANMW149TZZEGPZFV
              dataType:
                id: drilling-constraints
                version: 1
                address:
                  type: DataTypeInput
                  computationIndex: 0
                  dataTypeIndex: 1
              fileNames:
                - drilling-constraints.json
              files:
                - name: drilling-constraints.json
        outputContainers:
          description: A list of containers for the computation outputs.
          type: array
          items:
            $ref: '#/components/schemas/Container'
          example:
            - id: >-
                01C7VGQWGZVPSBV9NJMEAJSBGM/containers/production-forecast/01CH0K76B5ANMW149TZZEGPZFV
              dataType:
                id: production-forecast
                version: 1
                address:
                  type: DataTypeOutput
                  computationIndex: 0
                  dataTypeIndex: 0
              fileNames:
                - production-forecast.json
              files:
                - name: production-forecast.json
        logsContainer:
          $ref: '#/components/schemas/Container'
        computationErrors:
          description: The error associated with the computation.
          type: array
          items:
            $ref: '#/components/schemas/ComputationError'
          example:
            - addresses:
                - type: DataTypeInput
                  computationIndex: 0
                  dataTypeIndex: 0
                - type: DataTypeInput
                  computationIndex: 0
                  dataTypeIndex: 1
              message: Something went wrong.
        computationConfiguration:
          description: >-
            A computation configuration describes the configuration properties
            of the computation.
          type: object
          properties:
            schemaRef:
              $ref: '#/components/schemas/SchemaRef'
          example:
            schemaRef:
              ID: planning:fdplan:dataiku:0.0.1
              Type: JSON
      example:
        id: 0006803dc06c9bab3f82d4018287b8ccae575bd68eaa47f3c1797242e78daf03
        status: CompletedWithErrors
        computationSpec:
          id: ix
          version: 1
        inputContainers:
          - id: >-
              01C7VGQWGZVPSBV9NJMEAJSBGM/containers/decline-curves/01CH0K76B5ANMW149TZZEGPZFV
            dataType:
              id: decline-curves
              version: 1
              address:
                type: DataTypeInput
                computationIndex: 0
                dataTypeIndex: 0
            fileNames:
              - decline_curves.json
            files:
              - name: decline_curves.json
          - id: >-
              01C7VGQWGZVPSBV9NJMEAJSBGM/containers/drilling-constraints/01CH0K76B5ANMW149TZZEGPZFV
            dataType:
              id: drilling-constraints
              version: 1
              address:
                type: DataTypeInput
                computationIndex: 0
                dataTypeIndex: 1
            fileNames:
              - drilling-constraints.json
            files:
              - name: drilling-constraints.json
        outputContainers:
          - id: >-
              01C7VGQWGZVPSBV9NJMEAJSBGM/containers/production-forecast/01CH0K76B5ANMW149TZZEGPZFV
            dataType:
              id: production-forecast
              version: 1
              address:
                type: DataTypeOutput
                computationIndex: 0
                dataTypeIndex: 0
            fileNames:
              - production-forecast.json
            files:
              - name: production-forecast.json
        computationErrors:
          - addresses:
              - type: DataTypeInput
                computationIndex: 0
                dataTypeIndex: 0
              - type: DataTypeInput
                computationIndex: 0
                dataTypeIndex: 1
            message: Something went wrong.
        computationConfiguration:
          schemaRef:
            ID: planning:fdplan:dataiku:0.0.1
            Type: JSON
    Container:
      description: >-
        A container is an instance of a data-type which is used to obtain the
        location of files which are part of the container, along with input and
        output errors.
      type: object
      properties:
        id:
          description: The ID of the container.
          type: string
          example: >-
            01C7VGQWGZVPSBV9NJMEAJSBGM/containers/production-forecast/01CH0K76B5ANMW149TZZEGPZFV
          nullable: false
        dataType:
          $ref: '#/components/schemas/WorkflowDataType'
        store:
          description: The data store where the data within the container is located.
          type: string
          example: fdplan
        fileNames:
          description: >-
            The file names which are part of the container. (marked for
            deprecation in favour of files).
          type: array
          items:
            type: string
          example:
            - production-forecast.json
        files:
          description: The files which are part of the container.
          type: array
          items:
            $ref: '#/components/schemas/File'
        labels:
          $ref: '#/components/schemas/ContainerLabels'
        caseContainers:
          description: >-
            The containers for each case (only if the current container is a
            composite container)
          type: array
          items:
            $ref: '#/components/schemas/CaseContainer'
      example:
        id: >-
          01C7VGQWGZVPSBV9NJMEAJSBGM/containers/production-forecast/01CH0K76B5ANMW149TZZEGPZFV
        dataType:
          id: production-forecast
          version: 1
          address:
            type: DataTypeOutput
            computationIndex: 0
            dataTypeIndex: 0
        fileNames:
          - production-forecast.json
        files:
          - name: production-forecast.json
        labels:
          name: p10
    CaseContainer:
      required:
        - name
        - uri
        - dataType
        - version
      type: object
      properties:
        name:
          description: The name of the case.
          type: string
          nullable: false
        uri:
          description: The uri of the container.
          type: string
          nullable: false
        dataType:
          description: The data-type the container contains.
          type: string
          nullable: false
        version:
          format: int32
          description: >-
            The version of the data-type to which the data container is
            associated.
          type: integer
          nullable: false
    File:
      description: The metadata and optional content of a file.
      required:
        - name
      type: object
      properties:
        name:
          description: The name of the file.
          type: string
          example: data-link.json
          nullable: false
        content:
          description: >-
            Encoded content of the file in the Data URI format. It will be empty
            if the file size is larger than 15kb.
          type: string
          example: >-
            data:application/json;base64,eyJsaW5rcyI6W3sidXJsIjoiaHR0cHM6Ly9zdXBlcnNlY3JldGV4YW1wbGUuY29tL3lvdS1mb3VuZC10aGUtZXhhbXBsZSJ9XX0K
      example:
        name: data-link.json
        content: >-
          data:application/json;base64,eyJsaW5rcyI6W3sidXJsIjoiaHR0cHM6Ly9zdXBlcnNlY3JldGV4YW1wbGUuY29tL3lvdS1mb3VuZC10aGUtZXhhbXBsZSJ9XX0K
    CreateContainerFileResponse:
      description: Response for a successful file creation.
      type: object
      properties:
        fileURI:
          description: The relative URI of the file.
          type: string
          example: >-
            01C7VGQWGZVPSBV9NJMEAJSBGM/containers/production-forecast/01CH0K76B5ANMW149TZZEGPZFV/production-forecast.json
          nullable: false
      example:
        fileURI: >-
          01C7VGQWGZVPSBV9NJMEAJSBGM/containers/production-forecast/01CH0K76B5ANMW149TZZEGPZFV/production-forecast.json
    FileSpec:
      description: A specification for the type of file allowed for a data-type.
      type: object
      properties:
        extension:
          description: The file extension e.g. 'xlsx'
          type: string
          example: xlsx
          nullable: false
        schemaRef:
          $ref: '#/components/schemas/SchemaRef'
        defaultFilename:
          description: >-
            The optional default filename for this file specification. This
            field is useful when the file specification defines a single file
            which always has the same filename. (e.g. filename.json). Note that
            the extension of the default filename should match the file
            specification extension.
          type: string
          nullable: false
      example:
        extension: json
        schemaRef:
          - id: planning:fdplan:result-set:0.0.1
          - type: JSON
        defaultFilename: filename.json
    ComputationError:
      description: >-
        Human readible error messages and references to the workflow elements
        responsible for a computation error.
      type: object
      properties:
        addresses:
          description: >-
            A list of workflow spec addresses to describe the parts of a
            workflow which have resulted in the error.
          type: array
          items:
            $ref: '#/components/schemas/SpecAddress'
          example:
            - type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 0
            - type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 1
        message:
          description: A message which describes the error(s).
          type: string
          example: Something went wrong.
      example:
        addresses:
          - type: DataTypeInput
            computationIndex: 0
            dataTypeIndex: 0
          - type: DataTypeInput
            computationIndex: 0
            dataTypeIndex: 1
        message: Something went wrong.
    SpecAddress:
      description: >-
        An address used to describe the location of a Spec within a
        WorkflowSpec. Used to enrich the spec model with additional attributes
        such as specifying the location of a data container or providing
        annotations.
      required:
        - type
      type: object
      properties:
        type:
          description: >-
            Whether the address refers to a data-type input, a data-type output
            or a computation specification.
          enum:
            - Invalid
            - Computation
            - DataTypeInput
            - DataTypeOutput
          type: string
          example: DataTypeInput
          nullable: false
        computationIndex:
          description: The zero based index of the Computation Spec.
          type: integer
          example: 0
          x-omitempty: false
          nullable: false
        dataTypeIndex:
          description: >-
            The zero based index of a data-type with respect to a computation
            specification. Inputs and outputs are treated as separate ordered
            lists.
          type: integer
          example: 1
          x-omitempty: false
          nullable: false
      example:
        type: DataTypeInput
        computationIndex: 0
        dataTypeIndex: 0
    WorkflowComputationSpec:
      description: >-
        An evaluation computation specification reference which includes inputs
        and outputs with relevant workflow specification addresses.
      allOf:
        - $ref: '#/components/schemas/Spec'
        - required:
            - inputDataTypes
            - outputDataTypes
          type: object
          properties:
            address:
              $ref: '#/components/schemas/SpecAddress'
            inputDataTypeIds:
              description: The input data-types for the computation.
              type: array
              items:
                $ref: '#/components/schemas/WorkflowDataType'
              example:
                - id: decline-curves
                  version: 1
                  address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 0
                - id: facility-constraints
                  version: 1
                  address:
                    type: DataTypeInput
                    computationIndex: 0
                    dataTypeIndex: 1
            outputDataTypeIds:
              description: The output data-types for the computation.
              type: array
              items:
                $ref: '#/components/schemas/WorkflowDataType'
              example:
                - id: production-forecast
                  version: 1
                  address:
                    type: DataTypeOutput
                    computationIndex: 0
                    dataTypeIndex: 0
          example:
            id: 01DV2RPKYS5NYBAR6TNMJ8TNT8
            name: spec-type
            version: 1
            latest: true
            archived: false
            description: A specification.
            createdBy: user@slb.com
            createdAt: '2020-01-01T00:00:00.000Z'
            address:
              type: Computation
              computationIndex: 0
              dataTypeIndex: 0
            inputDataTypeIds:
              - id: decline-curves
                version: 1
                address:
                  type: DataTypeInput
                  computationIndex: 0
                  dataTypeIndex: 0
              - id: facility-constraints
                version: 1
                address:
                  type: DataTypeInput
                  computationIndex: 0
                  dataTypeIndex: 1
            outputDataTypeIds:
              - id: production-forecast
                version: 1
                address:
                  type: DataTypeOutput
                  computationIndex: 0
                  dataTypeIndex: 0
    WorkflowDataType:
      description: >-
        A workflow specific version of an evaluation data-type that includes its
        address within the workflow.
      allOf:
        - $ref: '#/components/schemas/VersionId'
        - type: object
          properties:
            address:
              $ref: '#/components/schemas/SpecAddress'
          example:
            id: decline-curves
            version: 1
            address:
              type: DataTypeInput
              computationIndex: 0
              dataTypeIndex: 0
    Annotation:
      description: An annotation or tag which describes elements within a workflow spec.
      type: object
      properties:
        address:
          $ref: '#/components/schemas/SpecAddress'
        key:
          description: Free form content with relevant information for the given address.
          type: string
          example: name
          x-omitempty: false
        value:
          description: Free form content with relevant information for the given address.
          type: string
          example: Decline Curves
          x-omitempty: false
        createdBy:
          description: The user who created this annotation.
          type: string
          example: user@slb.com
          x-omitempty: false
      example:
        address:
          type: DataTypeInput
          computationIndex: 0
          dataTypeIndex: 0
        key: name
        value: Decline Curves
        createdBy: user@slb.com
    RemoveAnnotationParams:
      description: The values that need to be sent to remove an annotation.
      type: object
      properties:
        address:
          $ref: '#/components/schemas/SpecAddress'
        key:
          description: Free form content with relevant information for the given address.
          type: string
          example: name
          x-omitempty: false
          nullable: false
      example:
        address:
          type: DataTypeInput
          computationIndex: 0
          dataTypeIndex: 0
        key: name
    ComputationLogEvent:
      description: >-
        The computationLogEvent. The log event should contain a list of logs
        associated with the computation.
      type: object
      properties:
        logs:
          description: The computation logs.
          type: array
          items:
            $ref: '#/components/schemas/ComputationLog'
    ComputationLog:
      description: Computation log describing the log file.
      type: object
      properties:
        text:
          description: Text to describe the computation log file.
          maxLength: 100
          type: string
        filePath:
          description: File path for the log file.
          maxLength: 256
          type: string
    ComputationProgressEventMessage:
      description: >-
        A message to provide a progress report on the status of an ongoing
        computation. Messages are logged as events.
      required:
        - timeStamp
        - progressStatus
        - source
      type: object
      properties:
        timeStamp:
          format: date-time
          description: >-
            The time that the event occurred given in format RFC3339, see. <a
            href="https://www.rfc-editor.org/rfc/rfc3339">https://www.rfc-editor.org/rfc/rfc3339</a>.
          type: string
          example: '2020-01-01T00:00:00.000Z'
          nullable: false
        progressStatus:
          description: The progress status of the computation e.g. Queued.
          maxLength: 50
          type: string
          example: Queued
          nullable: false
        source:
          description: The environment/infrastructure the computation is executing.
          maxLength: 100
          type: string
          example: External application
          nullable: false
        body:
          description: Free-form text as per individual requirements.
          maxLength: 1500
          type: string
          example: This is a progress event message.
          nullable: false
      example:
        timeStamp: '2020-01-01T00:00:00.000Z'
        progressStatus: Queued
        source: External application
        body: This is a progress event message
    ContainerLabels:
      description: The labels of a container.
      additionalProperties:
        type: string
      type: object
      example:
        name: p10
      nullable: false
    ComputationConfiguration:
      description: >-
        The request body to create or update configuration properties for a
        computation
      additionalProperties:
        type: string
        nullable: false
      type: object
    SignedURLResponse:
      description: A signed URL
      required:
        - signedURL
        - filePath
      type: object
      properties:
        signedURL:
          description: The signed URL
          type: string
          nullable: false
        filePath:
          description: The file path for which the signed URL was generated.
          type: string
          example: >-
            01JKZXK6ZDKC25MN3BN2ZDP1AQ/containers/slb:data-types:drilling-parameters/01JKZXMA7WRM8RCQKANECXZ9K1/slb-data-types-drilling-parameters.json
          nullable: false
