Slope Software Arrays API

The Arrays API from Slope Software — 2 operation(s) for arrays.

OpenAPI Specification

slope-software-arrays-api-openapi.yml Raw ↑
openapi: 3.0.4
info:
  title: Slope Arrays API
  version: '1.0'
tags:
- name: Arrays
paths:
  /api/v1/Arrays/{arrayId}:
    get:
      tags:
      - Arrays
      summary: Get detailed information about a specific array including all values and type-specific properties.
      description: "This endpoint returns array details with properties varying based on the array type:\n            \n- **Static Arrays**: Returns a list of string values in order\n- **Product Output Grouping Arrays**: Returns the product output grouping ID\n- **Calculated Range Arrays**: Returns start/end/step value configurations (variable, constant, or time index)\n- **Data Table Arrays**: Returns the data table variable name and calculation level\n- **Multi-Dimensional Arrays**: Returns the IDs of both dimension arrays\n            \nThis endpoint can be used with:\n- Production models (using a Workspace token ONLY)\n- Workspace models (using a Workspace or Personal token)\n            \nThe user must have appropriate permissions to access the model containing the array."
      operationId: GetArrayDetails
      parameters:
      - name: arrayId
        in: path
        description: The unique identifier of the array to retrieve.
        required: true
        schema:
          type: integer
          description: The ID of the array to retrieve
          format: int32
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetArrayDetailsResponse'
        '201':
          description: Created
        '400':
          description: Bad Request
        '403':
          description: Not Allowed To Access
        '429':
          description: Too Many Requests
        '404':
          description: Not Found
        '401':
          description: Unauthorized
      security:
      - API Token: []
  /api/v1/Arrays/{ArrayId}/Values:
    put:
      tags:
      - Arrays
      summary: Update the values in a static array.
      description: "This endpoint can be used to replace all existing values in a static array.\n            \nAll values must be unique and non-empty. Each value can be up to 200 characters."
      operationId: UpdateStaticArrayValues
      parameters:
      - name: ArrayId
        in: path
        description: The ID of the static array to update.
        required: true
        schema:
          type: integer
          description: The ID of the static array to update
          format: int32
      requestBody:
        description: The request containing the new array values.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateStaticArrayValuesRequestV1'
          text/json:
            schema:
              $ref: '#/components/schemas/UpdateStaticArrayValuesRequestV1'
          application/*+json:
            schema:
              $ref: '#/components/schemas/UpdateStaticArrayValuesRequestV1'
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UpdateStaticArrayValuesResponseV1'
        '400':
          description: Bad Request
          content:
            text/plain:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
            text/json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
        '404':
          description: Not Found
          content:
            text/plain:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
            text/json:
              schema:
                $ref: '#/components/schemas/ProblemDetails'
        '201':
          description: Created
        '403':
          description: Not Allowed To Access
        '429':
          description: Too Many Requests
        '401':
          description: Unauthorized
      security:
      - API Token: []
components:
  schemas:
    ArrayValueItemV1:
      required:
      - value
      type: object
      properties:
        value:
          maxLength: 200
          minLength: 0
          type: string
          description: The value for the array item. Maximum 200 characters.
      additionalProperties: false
    RangeArrayVariableType:
      enum:
      - Variable
      - Constant
      - TimeIndex
      type: string
    GetArrayDetailsResponse:
      type: object
      properties:
        id:
          type: integer
          format: int32
        name:
          type: string
          nullable: true
        arraySource:
          $ref: '#/components/schemas/ArrayType'
        level:
          $ref: '#/components/schemas/CalculationType'
        values:
          type: array
          items:
            type: string
          nullable: true
        productOutputGroupingId:
          type: integer
          format: int32
          nullable: true
        startValue:
          $ref: '#/components/schemas/RangeArrayValue'
        endValue:
          $ref: '#/components/schemas/RangeArrayValue'
        stepValue:
          $ref: '#/components/schemas/RangeArrayValue'
        variableName:
          type: string
          nullable: true
        dimension1ArrayId:
          type: integer
          format: int32
          nullable: true
        dimension2ArrayId:
          type: integer
          format: int32
          nullable: true
      additionalProperties: false
    ProblemDetails:
      type: object
      properties:
        type:
          type: string
          nullable: true
        title:
          type: string
          nullable: true
        status:
          type: integer
          format: int32
          nullable: true
        detail:
          type: string
          nullable: true
        instance:
          type: string
          nullable: true
      additionalProperties: {}
    UpdateStaticArrayValuesRequestV1:
      required:
      - values
      type: object
      properties:
        values:
          minItems: 1
          type: array
          items:
            $ref: '#/components/schemas/ArrayValueItemV1'
          description: 'The list of values to set for the static array.

            This will completely replace all existing values.'
      additionalProperties: false
    CalculationType:
      enum:
      - Product
      - Portfolio
      - Company
      type: string
    RangeArrayValue:
      type: object
      properties:
        type:
          $ref: '#/components/schemas/RangeArrayVariableType'
        variableName:
          type: string
          nullable: true
        value:
          type: number
          format: double
          nullable: true
      additionalProperties: false
    ArrayType:
      enum:
      - Static
      - ProductOutputGrouping
      - Range
      - DataTable
      - MultiDimensional
      type: string
    UpdateStaticArrayValuesResponseV1:
      type: object
      properties:
        arrayId:
          type: integer
          description: The ID of the updated array
          format: int32
        values:
          type: array
          items:
            type: string
          description: The updated list of array values in order
          nullable: true
      additionalProperties: false
  securitySchemes:
    API Token:
      type: http
      description: The API token received from the Authorize endpoint goes here.
      scheme: Bearer
      bearerFormat: JWT