> ## Documentation Index
> Fetch the complete documentation index at: https://docs.versori.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update an action for a system.

> UpdateSystemAction updates a single action for the given system.




## OpenAPI

````yaml /openapi/platform-api.yaml put /o/{organisation_id}/systems/{system_id}/actions/{action_id}
openapi: 3.1.0
info:
  title: Versori Platform API
  version: 0.0.1
  license:
    name: UNLICENSED
servers:
  - description: Production
    url: https://platform.versori.com/api/v2
  - description: Staging
    url: https://platform-staging.versori.com/api/v2
  - description: Development
    url: http://localhost:8901
security:
  - bearerToken: []
  - cookie: []
paths:
  /o/{organisation_id}/systems/{system_id}/actions/{action_id}:
    parameters:
      - $ref: '#/components/parameters/organisation_id'
      - $ref: '#/components/parameters/system_id'
      - $ref: '#/components/parameters/action_id'
    put:
      tags:
        - systems
      summary: Update an action for a system.
      description: |
        UpdateSystemAction updates a single action for the given system.
      operationId: UpdateSystemAction
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Action'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Action'
        default:
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  parameters:
    organisation_id:
      name: organisation_id
      in: path
      required: true
      schema:
        type: string
        format: ulid
        x-go-type: ulid.ULID
        x-go-name: OrganisationID
        x-go-type-import:
          path: versori.dev/vergo/ulid
    system_id:
      name: system_id
      in: path
      required: true
      schema:
        type: string
        format: ulid
        x-go-type: ulid.ULID
        x-go-name: SystemID
        x-go-type-import:
          path: versori.dev/vergo/ulid
    action_id:
      name: action_id
      in: path
      required: true
      schema:
        type: string
        format: ulid
        x-go-type: ulid.ULID
        x-go-name: ActionID
        x-go-type-import:
          path: versori.dev/vergo/ulid
  schemas:
    Action:
      type: object
      properties:
        id:
          type: string
          format: ulid
          x-go-name: ID
          x-go-type: ulid.ULID
          x-go-type-import:
            path: versori.dev/vergo/ulid
        systemId:
          type: string
          format: ulid
          x-go-type: ulid.ULID
          x-go-name: SystemID
          x-go-type-import:
            path: versori.dev/vergo/ulid
        type:
          $ref: '#/components/schemas/ActionType'
        name:
          type: string
        contentType:
          type: string
          description: >
            ContentType is the content type that this action expects to receive
            in the request body if any, and the

            content type of the response body if any. If this field is left
            blank, then "application/json" is assumed.
          x-go-type-skip-optional-pointer: true
        summary:
          type: string
          x-go-type-skip-optional-pointer: true
        description:
          type: string
          x-go-type-skip-optional-pointer: true
        method:
          $ref: '#/components/schemas/HTTPMethod'
        path:
          type: string
          description: >
            Path is the path of the action, which may contain templated values
            in curly braces.

            For example, `/users/{userId}`. The path should be the full path
            relative to the base URL of the system,

            the base URL containing everything before (and including) the
            top-level domain (.com, .gov, .org etc).
        parameters:
          type: array
          description: >
            Parameters is a list of parameters which are used to configure the
            action. These may be

            used to set values in the path, query string or headers of the
            request. Note that when creating an action,

            if the path contains templated values in curly braces, these will
            automatically be converted into

            parameters of type `path` with the name of the parameter being the
            name of the templated value.
          items:
            $ref: '#/components/schemas/ActionParameter'
        graphqlQuery:
          type: string
          description: >
            GraphQLQuery is the GraphQL query to execute for the action. This is
            only used if the action type is `graphql`.
        request:
          type: string
          description: >
            Request is the request body of the action. This is only used if the
            action type is `http`.
        response:
          type: string
          description: >
            Response is the response body of the action. This is only used if
            the action type is `http`.
      required:
        - id
        - systemId
        - type
        - name
        - method
        - path
        - parameters
    Error:
      type: object
      properties:
        code:
          type: string
          description: Code is a machine-readable error code.
        message:
          type: string
          description: Message is a human-readable error message.
        fields:
          type: array
          items:
            $ref: '#/components/schemas/ErrorField'
          x-go-type-skip-optional-pointer: true
        details:
          type: string
          x-go-type-skip-optional-pointer: true
      required:
        - code
        - message
    ActionType:
      type: string
      enum:
        - http
        - graphql
    HTTPMethod:
      type: string
      enum:
        - GET
        - POST
        - PUT
        - PATCH
        - DELETE
        - HEAD
        - OPTIONS
    ActionParameter:
      type: object
      properties:
        name:
          type: string
        in:
          type: string
          enum:
            - path
            - query
            - header
        required:
          type: boolean
        type:
          type: string
          enum:
            - string
            - integer
            - boolean
        default:
          type: string
      required:
        - name
        - in
        - required
        - type
    ErrorField:
      description: ErrorField denotes a field which has an error.
      type: object
      properties:
        field:
          type: string
          description: >
            Field is the name of the field which has an error, this may be a
            path to a nested field, including array

            elements. The format of this field is of the form:
            "field1.field2[0].field3"
        message:
          type: string
          description: Message is the error message for this specific field.
      required:
        - field
        - message
  securitySchemes:
    bearerToken:
      description: >
        Bearer token authentication used by the Versori Platform. External
        consumers must provide an API key, however

        internal consumers must provide a JWT id_token issued by our IdP.
      type: http
      scheme: bearer
    cookie:
      description: Cookie authentication used by the Versori Platform.
      type: apiKey
      in: cookie
      name: cookie

````