openapi: 3.0.3
info:
  version: "22"
  title: Business Rules
  contact:
    name: SAS Developers
    url: https://developer.sas.com
    email: devex@sas.com
  description: The Business Rules API supports the creation and management of business rules. These business rules are organized within rule sets.
tags:
  - name: Root
    description: Contains the operations for the root resource.
  - name: Rule Sets
    description: Contains the operations for creating, reading, and deleting rule sets.
  - name: Rules
    description: Contains the operations for importing, exporting, and querying rules directly.
  - name: Function Categories
    description: Contains the operations for creating, reading, and deleting function categories.
  - name: Functions
    description: Contains the operations for creating, reading, and deleting functions.
paths:
  /:
    get:
      operationId: root
      tags:
        - Root
      summary: Get API resource links
      description: Returns a list of links to the top level resources in this API.
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
            Last-Modified:
              schema:
                type: string
              example: Thu, 06 May 2021 21:37:00 GMT
          content:
            application/vnd.sas.api+json:
              schema:
                $ref: "#/components/schemas/api"
              examples:
                root:
                  $ref: "#/components/examples/root"
            application/json:
              schema:
                $ref: "#/components/schemas/api"
              examples:
                root:
                  $ref: "#/components/examples/root"
  /functionCategories:
    get:
      tags:
        - Function Categories
      summary: Get a collection of function categories
      description: >
        Returns a collection of function categories based on the specified pagination, filtering, and sorting options.
      operationId: getFunctionCategories
      parameters:
        - name: start
          in: query
          description: The index of the first function category to return.
          schema:
            type: integer
            format: int64
            default: 0
        - name: limit
          in: query
          description: The maximum number of function categories to return.
          schema:
            type: integer
            format: int32
            default: 20
        - name: filter
          in: query
          description: >
            The criteria for filtering the function categories. See [Filtering in REST APIs](https://developer.sas.com/rest-apis/businessRules-v22/docs/getting-started/usage-notes#filtering).
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          in: query
          description: >
            The criteria for sorting the function categories. See [Sorting in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#sorting).
          schema:
            type: string
            format: sort-criteria
      responses:
        "200":
          description: A collection of function categories.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
            Last-Modified:
              schema:
                type: string
              example: Thu, 06 May 2021 21:37:00 GMT
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/functionCategoryCollection"
              examples:
                default:
                  $ref: "#/components/examples/functionCategoryCollection"
            application/json:
              schema:
                $ref: "#/components/schemas/functionCategoryCollection"
              examples:
                default:
                  $ref: "#/components/examples/functionCategoryCollection"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
    post:
      operationId: createFunctionCategory
      tags:
        - Function Categories
      summary: Create a function category
      description: Creates a new function category.
      requestBody:
        content:
          application/vnd.sas.business.rule.function.category+json:
            schema:
              $ref: "#/components/schemas/functionCategory"
            examples:
              default:
                $ref: "#/components/examples/functionCategory"
          application/json:
            schema:
              $ref: "#/components/schemas/functionCategory"
            examples:
              default:
                $ref: "#/components/examples/functionCategory"
        description: Properties of the function category to create.
        required: true
      responses:
        "201":
          description: A function category was created.
          headers:
            Last-Modified:
              description: The date and time that the category was last modified.
              schema:
                type: string
                format: date-time
            Location:
              description: The URI at which the created category can be retrieved.
              schema:
                type: string
                format: uri
          content:
            application/vnd.sas.business.rule.function.category+json:
              schema:
                $ref: "#/components/schemas/functionCategory"
              examples:
                default:
                  $ref: "#/components/examples/functionCategory"
            application/json:
              schema:
                $ref: "#/components/schemas/functionCategory"
              examples:
                default:
                  $ref: "#/components/examples/functionCategory"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/functionCategories/{categoryId}":
    delete:
      operationId: deleteFunctionCategory
      tags:
        - Function Categories
      summary: Delete a function category
      description: Deletes the function category with the provided ID.
      parameters:
        - name: categoryId
          in: path
          required: true
          description: The ID of the category to delete.
          schema:
            type: string
      responses:
        "204":
          description: The content at the requested path was deleted.
    get:
      operationId: getFunctionCategory
      tags:
        - Function Categories
      description: Returns the function category with the provided ID.
      summary: Get a function category
      parameters:
        - name: categoryId
          in: path
          required: true
          description: The identifier of the category.
          schema:
            type: string
      responses:
        "200":
          description: The function category was found.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            ETag:
              description: The entity tag for the function category.
              schema:
                type: string
          content:
            application/vnd.sas.business.rule.function.category+json:
              schema:
                $ref: "#/components/schemas/functionCategory"
              examples:
                default:
                  $ref: "#/components/examples/functionCategory"
            application/json:
              schema:
                $ref: "#/components/schemas/functionCategory"
              examples:
                default:
                  $ref: "#/components/examples/functionCategory"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    put:
      operationId: updateFunctionCategory
      tags:
        - Function Categories
      summary: Update a function category
      description: Updates the function category with the provided content.
      parameters:
        - name: categoryId
          in: path
          required: true
          description: The ID of the function category to update.
          schema:
            type: string
        - name: If-Match
          in: header
          required: true
          description: The entity tag from the last time the category was retrieved.
          schema:
            type: string
          example: '"kt144a1d"'
      requestBody:
        content:
          application/vnd.sas.business.rule.function.category+json:
            schema:
              $ref: "#/components/schemas/functionCategory"
            examples:
              default:
                $ref: "#/components/examples/functionCategory"
          application/json:
            schema:
              $ref: "#/components/schemas/functionCategory"
            examples:
              default:
                $ref: "#/components/examples/functionCategory"
        required: true
      responses:
        "200":
          description: The function category was updated.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            ETag:
              description: The entity tag for the function category.
              schema:
                type: string
              example: '"kt144a3d"'
          content:
            application/vnd.sas.business.rule.function.category+json:
              schema:
                $ref: "#/components/schemas/functionCategory"
              examples:
                default:
                  $ref: "#/components/examples/functionCategory"
            application/json:
              schema:
                $ref: "#/components/schemas/functionCategory"
              examples:
                default:
                  $ref: "#/components/examples/functionCategory"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
        "412":
          description: The `If-Match` header did not match the resource's entity tag.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
        "428":
          description: The request headers did not include the `If-Match` precondition.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
  "/functionCategories/{categoryId}/functions":
    get:
      operationId: getCategoryFunctions
      tags:
        - Functions
      summary: Get a collection of functions in a category
      description: >
        Returns a collection of the functions in a specific category based on the specified pagination, filtering, and sorting options.
      parameters:
        - name: categoryId
          in: path
          required: true
          description: The ID of the category for which to retrieve the functions.
          schema:
            type: string
        - name: start
          in: query
          description: The index of the first function to return.
          schema:
            type: integer
            format: int64
            default: 0
        - name: limit
          in: query
          description: The maximum number of functions to return.
          schema:
            type: integer
            format: int32
            default: 20
        - name: filter
          in: query
          description: >
            The criteria for filtering the functions. See [Filtering in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#filtering).
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          in: query
          description: >
            The criteria for sorting the functions. See [Sorting in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#sorting).
          schema:
            type: string
            format: sort-criteria
      responses:
        "200":
          description: A collection of functions.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/functionCollection"
              examples:
                default:
                  $ref: "#/components/examples/functionCollection"
            application/json:
              schema:
                $ref: "#/components/schemas/functionCollection"
              examples:
                default:
                  $ref: "#/components/examples/functionCollection"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    post:
      operationId: createFunction
      tags:
        - Functions
      summary: Create a function
      description: Creates a new function in a specific category.
      parameters:
        - name: categoryId
          in: path
          required: true
          description: The ID of the category in which to create the new function.
          schema:
            type: string
      requestBody:
        content:
          application/vnd.sas.business.rule.function+json:
            schema:
              $ref: "#/components/schemas/newFunction"
            examples:
              default:
                $ref: "#/components/examples/function"
          application/json:
            schema:
              $ref: "#/components/schemas/newFunction"
            examples:
              default:
                $ref: "#/components/examples/function"
        description: The function to create.
        required: true
      responses:
        "201":
          description: A new function category was created.
          headers:
            ETag:
              description: The entity tag for the function.
              schema:
                type: string
            Location:
              description: The URI at which the new function can be retrieved.
              schema:
                type: string
                format: uri
          content:
            application/vnd.sas.business.rule.function+json:
              schema:
                $ref: "#/components/schemas/function"
              examples:
                default:
                  $ref: "#/components/examples/function"
            application/json:
              schema:
                $ref: "#/components/schemas/function"
              examples:
                default:
                  $ref: "#/components/examples/function"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  /functions:
    get:
      operationId: getFunctions
      tags:
        - Functions
      summary: Get a collection of functions
      description: >
        Returns a collection of functions based on the specified pagination, filtering, and sorting options.
      parameters:
        - name: start
          in: query
          description: The index of the first function to return.
          schema:
            type: integer
            format: int64
            default: 0
        - name: limit
          in: query
          description: The maximum number of functions to return.
          schema:
            type: integer
            format: int32
            default: 20
        - name: filter
          in: query
          description: >
            The criteria for filtering the functions. See [Filtering in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#filtering).
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          in: query
          description: >
            The criteria for sorting the functions. See [Sorting in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#sorting).
          schema:
            type: string
            format: sort-criteria
      responses:
        "200":
          description: A collection of functions.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/functionCollection"
              examples:
                default:
                  $ref: "#/components/examples/functionCollection"
            application/json:
              schema:
                $ref: "#/components/schemas/functionCollection"
              examples:
                default:
                  $ref: "#/components/examples/functionCollection"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/functions/{functionId}":
    delete:
      operationId: deleteFunction
      tags:
        - Functions
      summary: Delete a function
      description: Deletes the function with the provided ID.
      parameters:
        - name: functionId
          in: path
          required: true
          description: The ID of the function to delete.
          schema:
            type: string
      responses:
        "204":
          description: The function at the requested path was deleted.
    get:
      operationId: getFunction
      tags:
        - Functions
      summary: Get a user-defined function
      description: Retrieves the user-defined function with the given ID.
      parameters:
        - name: functionId
          in: path
          required: true
          description: The ID of the function to retrieve.
          schema:
            type: string
      responses:
        "200":
          description: The function was retrieved.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            ETag:
              description: The entity tag for the function.
              schema:
                type: string
                example: '"kt144a1d"'
          content:
            application/vnd.sas.business.rule.function+json:
              schema:
                $ref: "#/components/schemas/function"
              examples:
                default:
                  $ref: "#/components/examples/function"
            application/json:
              schema:
                $ref: "#/components/schemas/function"
              examples:
                default:
                  $ref: "#/components/examples/function"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    put:
      operationId: updateFunction
      tags:
        - Functions
      summary: Update a function
      description: Updates the function with the provided content.
      parameters:
        - name: functionId
          in: path
          required: true
          description: The ID of the function to update.
          schema:
            type: string
        - name: If-Match
          in: header
          required: true
          description: The entity tag from the last time the function was retrieved.
          schema:
            type: string
            example: '"kt144a1d"'
      requestBody:
        content:
          application/vnd.sas.business.rule.function+json:
            schema:
              $ref: "#/components/schemas/function"
            examples:
              default:
                $ref: "#/components/examples/function"
          application/json:
            schema:
              $ref: "#/components/schemas/function"
            examples:
              default:
                $ref: "#/components/examples/function"
        required: true
      responses:
        "200":
          description: The function was updated.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            ETag:
              description: The entity tag for the function.
              schema:
                type: string
          content:
            application/vnd.sas.business.rule.function+json:
              schema:
                $ref: "#/components/schemas/function"
              examples:
                default:
                  $ref: "#/components/examples/function"
            application/json:
              schema:
                $ref: "#/components/schemas/function"
              examples:
                default:
                  $ref: "#/components/examples/function"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
        "412":
          description: The `If-Match` header did not match the resource's entity tag.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
        "428":
          description: The request headers did not include the `If-Match` precondition.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
  /commons/validations/functions:
    post:
      operationId: validateFunction
      tags:
        - Functions
      summary: Validate a custom function
      description: Verifies that the custom function compiles without errors.
      requestBody:
        content:
          application/vnd.sas.business.rule.function+json:
            schema:
              $ref: "#/components/schemas/newFunction"
            examples:
              default:
                $ref: "#/components/examples/function"
          application/json:
            schema:
              $ref: "#/components/schemas/newFunction"
            examples:
              default:
                $ref: "#/components/examples/function"
        description: The function to be validated.
        required: true
      responses:
        "200":
          description: The validations for the custom function were created.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/errorCollection"
              examples:
                default:
                  $ref: "#/components/examples/errorCollection"
            application/json:
              schema:
                $ref: "#/components/schemas/errorCollection"
              examples:
                default:
                  $ref: "#/components/examples/errorCollection"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  /ruleSets:
    get:
      operationId: getRuleSets
      tags:
        - Rule Sets
      summary: Get all rule sets
      description: Returns a resource collection of all the rule sets.
      parameters:
        - name: filter
          description: An expression for filtering the collection. Valid expressions include eq(member,"string"). Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy`.
          in: query
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          description: The criteria for sorting the rule sets. Valid sortBy parameters include `sortBy=id:descending`. Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy.
          in: query
          schema:
            type: string
            format: sort-criteria
        - name: start
          in: query
          description: The starting index of the first item on a page. The index is 0-based. The default is 0.
          schema:
            type: integer
        - name: limit
          in: query
          description: The maximum number of items to return on this page of results. The actual number of returned items might be less if there are no more items in the collection. The default is 10.
          schema:
            type: integer
        - name: parentFolderUri
          in: query
          description: The folder where the target rule sets are located.
          required: false
          schema:
            type: string
            format: /folders/folders/{parentFolderId}
        - name: Accept-Item
          description: Used for selecting the desired item representation.
          in: header
          schema:
            type: string
            format: media-type
            enum:
              - application/vnd.sas.business.rule.set+json
              - application/vnd.sas.summary+json
              - application/vnd.sas.dcm.summary+json
            default: application/vnd.sas.summary+json
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                anyOf:
                  - $ref: "#/components/schemas/resourceSummaryCollection"
                  - $ref: "#/components/schemas/ruleSetCollection"
              examples:
                application/vnd.sas.summary+json:
                  $ref: "#/components/examples/summaryOfRuleSets"
                application/vnd.sas.business.rule.set+json:
                  $ref: "#/components/examples/detailedRuleSets"
            application/json:
              schema:
                $ref: "#/components/schemas/resourceSummaryCollection"
              examples:
                application/vnd.sas.summary+json:
                  $ref: "#/components/examples/summaryOfRuleSets"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "406":
          description: The media type is incompatible. This is usually the case when there is an error, but the error response media type is not compatible with the text/csv media type. The REST client or browser returns this status error instead.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notAcceptable"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notAcceptable"
    post:
      operationId: createRuleSet
      tags:
        - Rule Sets
      summary: Create a rule set
      description: Creates a new rule set.
      parameters:
        - name: parentFolderUri
          in: query
          description: The folder in which the new rule set is placed.
          required: false
          schema:
            type: string
            format: /folders/folders/{parentFolderId}
        - name: fromRevisionUri
          in: query
          description: This value specifies the URI of the rule set revision from which the new rule set is created. This property enables you to trace the lineage of a rule set. The valid format for this parameter is '/businessRules/ruleSets/${rulesetId}/revisions/${revisionId}'
          schema:
            type: string
            format: /businessRules/ruleSets/{rulesetId}/revisions/{revisionId}
      requestBody:
        content:
          application/vnd.sas.business.rule.set+json:
            schema:
              $ref: "#/components/schemas/ruleSet"
            examples:
              default:
                $ref: "#/components/examples/ruleset"
          application/json:
            schema:
              $ref: "#/components/schemas/ruleSet"
            examples:
              default:
                $ref: "#/components/examples/ruleset"
        description: The rule set object that should be created.
        required: true
      responses:
        "201":
          description: A folder was created.
          headers:
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
            Location:
              schema:
                type: string
                format: uri
          content:
            application/vnd.sas.business.rule.set+json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}":
    head:
      operationId: headersForRuleSet
      tags:
        - Rule Sets
      summary: Get the headers of a rule set
      description: Returns the headers for the specified rule set.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    get:
      operationId: getRuleSet
      tags:
        - Rule Sets
      description: Returns the rule set for the provided ID.
      summary: Get a rule set
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.business.rule.set+json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    put:
      summary: Update a rule set
      operationId: updateRuleSet
      tags:
        - Rule Sets
      description: Updates the rule set with the provided content.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: If-Unmodified-Since
          in: header
          required: true
          description: The date and time that the rule set was last modified.
          schema:
            type: string
            format: date-time
      requestBody:
        content:
          application/vnd.sas.business.rule.set+json:
            schema:
              $ref: "#/components/schemas/ruleSet"
            examples:
              default:
                $ref: "#/components/examples/ruleset"
          application/json:
            schema:
              $ref: "#/components/schemas/ruleSet"
            examples:
              default:
                $ref: "#/components/examples/ruleset"
        description: The rule set body that is updated with the existing rule set.
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.business.rule.set+json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
        "412":
          description: The `If-Unmodified-Since` request header did not match the resource's last modified timestamp.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
        "428":
          description: The request headers did not include a `If-Unmodified-Since` precondition.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
    delete:
      summary: Delete a rule set
      operationId: deleteRuleSet
      tags:
        - Rule Sets
      description: Deletes the specified rule set.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      responses:
        "204":
          description: The rule set was deleted.
        "404":
          description: No rule set exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}#revisionSummary":
    get:
      operationId: getRuleSetDcmSummary
      tags:
        - Rule Sets
      description: Returns the decisioning revision summary of a rule set for the provided ID.
      summary: Get a rule set
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: start
          in: query
          required: false
          description: The starting index of the first item on a page. The index is 0-based. The default is 0.
          schema:
            type: integer
        - name: limit
          in: query
          required: false
          description: The maximum number of items to return on this page. The actual number of returned items might be less if there are no more items in the collection. The default is 10.
          schema:
            type: integer
        - name: filter
          in: query
          description: >
            The criteria for filtering the function categories. See [Filtering in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#filtering).
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          in: query
          description: >
            The criteria for sorting the function categories. See [Sorting in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#sorting).
          schema:
            type: string
            format: sort-criteria
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.dcm.summary+json:
              schema:
                $ref: "#/components/schemas/revisionSummary"
              examples:
                default:
                  $ref: "#/components/examples/summaryOfRuleSet"
            application/json:
              schema:
                $ref: "#/components/schemas/revisionSummary"
              examples:
                default:
                  $ref: "#/components/examples/summaryOfRuleSet"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}#withRules":
    get:
      summary: Get a rule set with all the rules
      operationId: getRuleSetWithRules
      tags:
        - Rule Sets
      description: Returns the rule set with all the rules from the latest revision.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: Accept
          in: header
          required: true
          description: Used for selecting desired representation.
          schema:
            type: string
            format: media-type
            enum:
              - application/vnd.sas.business.rule.set.integral+json
            default: application/vnd.sas.business.rule.set.integral+json
            example: application/vnd.sas.business.rule.set.integral+json
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
            ETag:
              description: The entity tag for the rule set.
              schema:
                type: string
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
            Location:
              schema:
                type: string
                format: uri
          content:
            application/vnd.sas.business.rule.set.integral+json:
              schema:
                $ref: "#/components/schemas/ruleSetIntegral"
              examples:
                default:
                  $ref: "#/components/examples/ruleSetWithRules"
        "404":
          description: No resource exists at the requested path.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}/order":
    get:
      summary: Get execution order of rules
      operationId: getRuleSetOrder
      tags:
        - Rule Sets
      description: Returns the order of the rules within the rule set.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.selection+json:
              schema:
                $ref: "#/components/schemas/selection"
              examples:
                default:
                  $ref: "#/components/examples/ruleOrderSelection"
            application/json:
              schema:
                $ref: "#/components/schemas/selection"
              examples:
                default:
                  $ref: "#/components/examples/ruleOrderSelection"
        "404":
          description: No rule set exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    put:
      summary: Update rules execution order
      operationId: updateRuleSetOrder
      tags:
        - Rule Sets
      description: Returns the execution order for rules within the rule set based on the provided body.
      parameters:
        - name: If-Unmodified-Since
          in: header
          required: true
          description: The last date and time of the contents retrieved for the rule set on which you are basing your update.
          schema:
            type: string
            format: date-time
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      requestBody:
        content:
          application/vnd.sas.selection+json:
            schema:
              $ref: "#/components/schemas/selection"
            examples:
              default:
                $ref: "#/components/examples/ruleOrderSelection"
          application/json:
            schema:
              $ref: "#/components/schemas/selection"
            examples:
              default:
                $ref: "#/components/examples/ruleOrderSelection"
        description: Customized ordering for the rules during execution.
        required: true
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.selection+json:
              schema:
                $ref: "#/components/schemas/selection"
              examples:
                default:
                  $ref: "#/components/examples/ruleOrderSelection"
            application/json:
              schema:
                $ref: "#/components/schemas/selection"
              examples:
                default:
                  $ref: "#/components/examples/ruleOrderSelection"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
        "412":
          description: The `If-Unmodified-Since` request header did not match the resource's last modified timestamp.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
        "428":
          description: The request headers did not include a `If-Unmodified-Since` precondition.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
  "/ruleSets/{ruleSetId}/code":
    get:
      summary: Get rule set code
      operationId: getRuleSetCode
      tags:
        - Rule Sets
      description: Returns the code for integrating within another program so that program is able to run the rule set.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: codeTarget
          in: query
          description: >
            The type of platform that the generated code is run on. This affects some aspects of how the code is generated. For example, the MICROANALYTICS variables that are both input and output are listed distinctly in the execute method signature rather than as one 'in_out' parameter. The default is CAS.
          schema:
            type: string
            enum:
              - MICROANALYTICSERVICE
              - CAS
        - name: lookupMode
          in: query
          required: false
          description: Generates the code using references to the reference data domains based on the format names, the inline domain contents as conditionals, or the domain contents as  DS2 packages. The default is 'format'. If the value is either format or package, the domain contents are expected to exist in that form on the Cloud Analytic Server and Micro Analytic Score server respectively. This is done the domain contents are activated using the SAS Intelligent Decisioning web application or using a Reference Data service REST API invocation. Only when executing the code would it be known that the formats or packages do not exist.
          schema:
            type: string
            enum:
              - format
              - inline
              - package
        - name: isGeneratingRuleFiredColumn
          in: query
          required: false
          description: Determines whether the rule fired columns are included in the method signatures within the return package code. The default is 'true'.
          schema:
            type: boolean
        - name: inlineAdvanceListValues
          in: query
          required: false
          description: Specifies whether the currently deployed rows in an advanced list are included as inline values within the generated code. Advanced lists and rows within an advanced list can be deployed by using the SAS Intelligent Decisioning web application, the SAS Fraud Decisioning application, or the List Data API. If this parameter is 'true', the deployed rows in an advanced list are re-created as a data grid in the generated code. If this parameter is 'false', the advanced list must exist as a tabular data set on the Redis server. To get generated code for Cloud Analytic Server, Teradata, or Hadoop destinations, specify 'true' as the parameter value.
          schema:
            type: boolean
        - name: useGlobalVariableCurrentValues
          in: query
          required: false
          description: When set to true, the current value for the global variables is used at code generation time, even if the global variable is not activated. When set to false, the value of the activated global variables is looked up and used at code execution time.
          schema:
            type: boolean
            default: true
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            text/vnd.sas.source.ds2:
              schema:
                type: string
                format: ds2
              examples:
                default:
                  $ref: "#/components/examples/ds2CodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/mappedCode":
    post:
      summary: Get the mapped code for a rule set
      operationId: getMappedRuleSetCode
      tags:
        - Rule Sets
      description: Returns the code to be able to run the rule set based on the provided data and mapping information in the request.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: injectTestCustomContext
          in: query
          required: false
          description: If true, the generated code includes the code content of the test custom context. The test custom context is conveyed by the testCustomContextUri member of the rule set. If the rule set does not use methods provided by a custom context, injectTestCustomContext should not be used.
          schema:
            type: boolean
            default: false
      requestBody:
        $ref: "#/components/requestBodies/scoreCodeGenerationRequest"
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.score.mapped.code+json:
              schema:
                $ref: "#/components/schemas/mappedCode"
              examples:
                default:
                  $ref: "#/components/examples/mappedCodeOfRuleSet"
            application/json:
              schema:
                $ref: "#/components/schemas/mappedCode"
              examples:
                default:
                  $ref: "#/components/examples/mappedCodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/mappedCode#unbound":
    post:
      summary: Get rule set code without score definition
      operationId: getMappedRuleSetCodeUnbounded
      tags:
        - Rule Sets
      description: Returns the code to be able to run the rule set based on mapping to a static input and output data set of SASEP.IN and SASEP.OUT rather than binding to a score definition.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      requestBody:
        content:
          application/vnd.sas.score.code.generation.request.unbound+json:
            schema:
              $ref: "#/components/schemas/unboundScoreCodeGenerationRequest"
            examples:
              default:
                $ref: "#/components/examples/scoreCodeGenerationRequestUnboundForRuleSet"
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.score.mapped.code+json:
              schema:
                $ref: "#/components/schemas/mappedCode"
              examples:
                default:
                  $ref: "#/components/examples/mappedCodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/mappedCode#unboundCodeOnly":
    post:
      summary: Get rule set code not bound to a score definition
      operationId: getMappedRuleSetCodeUnboundedText
      tags:
        - Rule Sets
      description: Returns the code directly as text without being wrapped in a JSON model. The text can then be used to run the rule set based on mapping to a static input and output data set of SASEP.IN and SASEP.OUT rather than binding to a score definition.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      requestBody:
        content:
          application/vnd.sas.score.code.generation.request.unbound+json:
            schema:
              $ref: "#/components/schemas/unboundScoreCodeGenerationRequest"
            examples:
              default:
                $ref: "#/components/examples/scoreCodeGenerationRequestUnboundForRuleSet"
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.score.mapped.code+json:
              schema:
                $ref: "#/components/schemas/mappedCode"
              examples:
                default:
                  $ref: "#/components/examples/mappedCodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/analysisCode":
    post:
      summary: Get rule set analysis code
      operationId: getAnalysisCode
      tags:
        - Rule Sets
      description: Returns the analysis code to generate rule fired reports based on the scoring definition.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/analysisCodeGenerationRequest"
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.score.analysis.code+json:
              schema:
                $ref: "#/components/schemas/analysisCode"
              examples:
                default:
                  $ref: "#/components/examples/analysisCodeOfRuleSet"
            application/json:
              schema:
                $ref: "#/components/schemas/analysisCode"
              examples:
                default:
                  $ref: "#/components/examples/analysisCodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/analysisCode#codeOnly":
    post:
      summary: Get rule set analysis code as text
      operationId: getAnalysisCodeText
      tags:
        - Rule Sets
      description: Returns the analysis code directly as text in response, not contained within a JSON model, to generate rule fired reports based on the analysis request.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/analysisCodeGenerationRequest"
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            text/vnd.sas.source.ds2:
              schema:
                type: string
                format: ds2
              examples:
                default:
                  $ref: "#/components/examples/ds2CodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/decisionStepCode":
    get:
      tags:
        - Rule Sets
      summary: Get the decision step code for a rule set
      description: Returns the decision step code for the specified rule set.
      operationId: getRulesetDecisionStepCode
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The identifier of the rule set.
          schema:
            type: string
        - name: inlineAdvanceListValues
          in: query
          required: false
          description: Specifies whether the currently deployed rows in an advanced list are included as inline values within the generated code. Advanced lists and rows within an advanced list can be deployed by using the SAS Intelligent Decisioning web application, the SAS Fraud Decisioning application, or the List Data API. If this parameter is 'true', the deployed rows in an advanced list are re-created as a data grid in the generated code. If this parameter is 'false', the advanced list must exist as a tabular data set on the Redis server. To get generated code for Cloud Analytic Server, Teradata, or Hadoop destinations, specify 'true' as the parameter value.
          schema:
            type: boolean
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/decisionStepCode"
              examples:
                default:
                  $ref: "#/components/examples/decisionStepCodeOfRuleSet"
            application/vnd.sas.decision.step.code+json:
              schema:
                $ref: "#/components/schemas/decisionStepCode"
              examples:
                default:
                  $ref: "#/components/examples/decisionStepCodeOfRuleSet"
        "404":
          description: No rule set exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}/actionConversion":
    post:
      summary: Convert a rule action to a target type
      operationId: convertRuleAction
      tags:
        - Rule Sets
      description: Convert a rule action to a new target type.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      requestBody:
        content:
          application/vnd.sas.business.rule.action.conversion+json:
            schema:
              $ref: "#/components/schemas/ruleActionConversion"
            examples:
              default:
                $ref: "#/components/examples/actionConversion"
          application/json:
            schema:
              $ref: "#/components/schemas/ruleActionConversion"
            examples:
              default:
                $ref: "#/components/examples/actionConversion"
        description: The action conversion request.
      responses:
        "200":
          description: The converted rule action.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.business.rule.action.conversion+json:
              schema:
                $ref: "#/components/schemas/ruleActionConversion"
              examples:
                default:
                  $ref: "#/components/examples/actionConversion"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleActionConversion"
              examples:
                default:
                  $ref: "#/components/examples/actionConversion"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/conditionConversion":
    post:
      summary: Convert a rule condition to a target type
      operationId: convertRuleCondition
      tags:
        - Rule Sets
      description: Convert a rule condition to a new target type.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
      requestBody:
        content:
          application/vnd.sas.business.rule.condition.conversion+json:
            schema:
              $ref: "#/components/schemas/ruleConditionConversion"
            examples:
              default:
                $ref: "#/components/examples/conditionConversion"
          application/json:
            schema:
              $ref: "#/components/schemas/ruleConditionConversion"
            examples:
              default:
                $ref: "#/components/examples/conditionConversion"
        description: The condition conversion request.
      responses:
        "200":
          description: The converted rule condition.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.business.rule.condition.conversion+json:
              schema:
                $ref: "#/components/schemas/ruleConditionConversion"
              examples:
                default:
                  $ref: "#/components/examples/conditionConversion"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleConditionConversion"
              examples:
                default:
                  $ref: "#/components/examples/conditionConversion"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/ruleValidations":
    post:
      summary: Retrieve a collection of errors
      operationId: validateRule
      tags:
        - Rule Sets
      description: Tests the validation of the rule content and returns a list of errors.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The identifier of the rule set.
          schema:
            type: string
      requestBody:
        content:
          application/vnd.sas.business.rule+json:
            schema:
              $ref: "#/components/schemas/businessRule"
            examples:
              default:
                $ref: "#/components/examples/validateRule"
          application/json:
            schema:
              $ref: "#/components/schemas/businessRule"
            examples:
              default:
                $ref: "#/components/examples/validateRule"
        description: The rule that needs to be validated.
        required: true
      responses:
        "200":
          description: The validations were created.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/errorCollection"
              examples:
                default:
                  $ref: "#/components/examples/errorCollection"
            application/json:
              schema:
                $ref: "#/components/schemas/errorCollection"
              examples:
                default:
                  $ref: "#/components/examples/errorCollection"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/rules":
    get:
      summary: Get all the rules for a rule set
      operationId: getRules
      tags:
        - Rules
      description: Returns the collection of rules for a specified rule set.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The ID of the rule set to match.
          schema:
            type: string
        - name: start
          in: query
          required: false
          description: The starting index of the first item on a page. The index is 0-based. The default is 0.
          schema:
            type: integer
        - name: limit
          in: query
          required: false
          description: The maximum number of items to return on this page. The actual number of returned items might be less if there are no more items in the collection. The default is 10.
          schema:
            type: integer
        - name: filter
          in: query
          description: >
            The criteria for filtering the function categories. See [Filtering in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#filtering).
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          in: query
          description: >
            The criteria for sorting the function categories. See [Sorting in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#sorting).
          schema:
            type: string
            format: sort-criteria
        - name: Accept-Item
          in: header
          description: An alternative media type that the API recognizes. If the media type is not one that the API can provide, a 406 response is returned.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/ruleCollection"
              examples:
                default:
                  $ref: "#/components/examples/collectionOfRulesInRuleSet"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleCollection"
              examples:
                default:
                  $ref: "#/components/examples/collectionOfRulesInRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
    post:
      summary: Create a rule
      operationId: createRule
      tags:
        - Rules
      description: Creates a rule within the rule set.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The identifier of the rule set.
          schema:
            type: string
        - name: createVariables
          in: query
          required: false
          description: If set to true, any variables that do not exist within the posted rule content are created if a valid data type can be derived from the expression or an optional data type is provided.
          schema:
            type: boolean
      requestBody:
        content:
          application/vnd.sas.business.rule+json:
            schema:
              $ref: "#/components/schemas/businessRule"
            examples:
              default:
                $ref: "#/components/examples/validateRule"
          application/json:
            schema:
              $ref: "#/components/schemas/businessRule"
            examples:
              default:
                $ref: "#/components/examples/validateRule"
        description: Rules to add to a rule set.
        required: true
      responses:
        "201":
          description: The rule was created.
          headers:
            Last-Modified:
              description: The date and time that the rule was last modified.
              schema:
                type: string
                format: date-time
            Location:
              schema:
                type: string
                format: uri
          content:
            application/vnd.sas.business.rule+json:
              schema:
                $ref: "#/components/schemas/businessRule"
              examples:
                default:
                  $ref: "#/components/examples/validateRule"
            application/json:
              schema:
                $ref: "#/components/schemas/businessRule"
              examples:
                default:
                  $ref: "#/components/examples/validateRule"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/legacyVariables":
    get:
      summary: Get legacy variables of a rule set
      operationId: getRuleSetLegacyVariables
      tags:
        - Rule Sets
      description: Retrieves the legacy variables of the rule set, which can be added back to the rule set.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The identifier of the rule set.
          schema:
            type: string
        - name: filter
          description: An expression for filtering the collection. Valid expressions include eq(member,"string"). Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy`.
          in: query
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          description: The criteria for sorting the rule sets. Valid `sortBy` parameters include sortBy=id:descending. Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy`.
          in: query
          schema:
            type: string
            format: sort-criteria
        - name: start
          in: query
          required: false
          description: The starting index of the first item on a page. The index is 0-based. The default is 0.
          schema:
            type: integer
        - name: limit
          in: query
          required: false
          description: The maximum number of items to return on this page. The actual number of returned items might be less if there are no more items in the collection. The default is 10.
          schema:
            type: integer
        - name: Accept-Item
          description: Used for selecting desired item representation.
          in: header
          schema:
            type: string
            format: media-type
            enum:
              - application/vnd.sas.business.rule.set.variable+json
            default: application/vnd.sas.business.rule.set.variable+json
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/ruleVariableCollection"
              examples:
                default:
                  $ref: "#/components/examples/collectionOfLegacyVariables"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleVariableCollection"
              examples:
                default:
                  $ref: "#/components/examples/collectionOfLegacyVariables"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/rules/{rid}":
    head:
      summary: Get the headers for a rule
      operationId: headersForRule
      tags:
        - Rules
      description: Returns the headers for the rule object.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: rid
          in: path
          required: true
          description: The rule's ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule was last modified.
              schema:
                type: string
                format: date-time
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    get:
      summary: Get rule details
      operationId: getRuleDetails
      tags:
        - Rules
      description: Returns the details of a rule.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: rid
          in: path
          required: true
          description: The rule ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule was last modified.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.business.rule+json:
              schema:
                $ref: "#/components/schemas/businessRule"
              examples:
                default:
                  $ref: "#/components/examples/validateRule"
            application/json:
              schema:
                $ref: "#/components/schemas/businessRule"
              examples:
                default:
                  $ref: "#/components/examples/validateRule"
        "404":
          description: No rule ID exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    put:
      summary: Update a rule
      operationId: updateRule
      tags:
        - Rules
      description: Updates the rule with new rule content.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: rid
          in: path
          required: true
          description: The rule ID.
          schema:
            type: string
        - name: createVariables
          in: query
          required: false
          description: If set to true, any variables that do not exist within the posted rule content are created if a valid data type can be derived from the expression or an optional data type is provided.
          schema:
            type: boolean
        - name: If-Unmodified-Since
          in: header
          description: The last date and time of the contents retrieved for the rule on which you are basing your update.
          schema:
            type: string
            format: date-time
      requestBody:
        content:
          application/vnd.sas.business.rule+json:
            schema:
              $ref: "#/components/schemas/businessRule"
            examples:
              default:
                $ref: "#/components/examples/validateRule"
          application/json:
            schema:
              $ref: "#/components/schemas/businessRule"
            examples:
              default:
                $ref: "#/components/examples/validateRule"
        description: The rule body with which to update the existing rule content.
        required: true
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule was last modified.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.business.rule+json:
              schema:
                $ref: "#/components/schemas/businessRule"
              examples:
                default:
                  $ref: "#/components/examples/validateRule"
            application/json:
              schema:
                $ref: "#/components/schemas/businessRule"
              examples:
                default:
                  $ref: "#/components/examples/validateRule"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
        "412":
          description: The `If-Unmodified-Since` request header did not match the resource's last modified timestamp.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionFailed"
        "428":
          description: The request headers did not include an `If-Unmodified-Since` precondition.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
    delete:
      summary: Delete a rule
      operationId: deleteRule
      tags:
        - Rules
      description: Deletes the rule from the rule set.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: rid
          in: path
          required: true
          description: The rule ID.
          schema:
            type: string
      responses:
        "204":
          description: The resource was deleted.
        "404":
          description: No rule ID exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}/revisions":
    get:
      summary: Get all revisions of a rule set
      operationId: getRevisions
      tags:
        - Rule Sets
      description: Returns all the revisions that were created for the rule set.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: filter
          description: An expression for filtering the collection. Valid expressions include eq(member,"string"). Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy`.
          in: query
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          description: The criteria for sorting the rule sets. Valid `sortBy` parameters include sortBy=id:descending. Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy`.
          in: query
          schema:
            type: string
            format: sort-criteria
        - name: start
          in: query
          required: false
          description: The starting index of the first item on a page. The index is 0-based. The default is 0.
          schema:
            type: integer
        - name: limit
          in: query
          required: false
          description: The maximum number of items to return on this page. The actual number of returned items might be less if there are no more items in the collection. The default is 10.
          schema:
            type: integer
        - name: Accept-Item
          description: Used for selecting desired item representation.
          in: header
          schema:
            type: string
            format: media-type
            enum:
              - application/vnd.sas.business.rule.set+json
              - application/vnd.sas.summary+json
              - application/vnd.sas.dcm.summary+json
            default: application/vnd.sas.summary+json
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                anyOf:
                  - $ref: "#/components/schemas/resourceSummaryCollection"
                  - $ref: "#/components/schemas/ruleSetCollection"
              examples:
                application/vnd.sas.summary+json:
                  $ref: "#/components/examples/summaryOfRuleSets"
                application/vnd.sas.business.rule.set+json:
                  $ref: "#/components/examples/detailedRuleSets"
            application/json:
              schema:
                $ref: "#/components/schemas/resourceSummaryCollection"
              examples:
                application/vnd.sas.summary+json:
                  $ref: "#/components/examples/summaryOfRuleSets"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    post:
      summary: Create a new revision
      operationId: createNewRevision
      tags:
        - Rule Sets
      description: Creates a new revision for the rule set. With this request, you supply the content that you want to initialize for a new revision.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionType
          in: query
          required: false
          description: Valid values are `major` or `minor`. This value determines how the server generates the `major` and `minor` numbers. If a `major` number is provided, the next available major version number is started. For example, if the rule set has revisions 1.0, 1.1, 1.2, 2.0, and 2.1, creating a new major revision results in 3.0. If a `minor` number is provided, then the next available minor revision number is reserved based on the existing revisions. For example, if the existing revisions have `major` and `minor` numbers of 1.1, 1.2, 1.3, 2.1, 2.2, and a user requests a new minor revision, then 2.3 is assigned. This parameter defaults to `minor` if not supplied.
          schema:
            type: string
            enum:
              - major
              - minor
        - name: fromRevisionUri
          in: query
          description: This value specifies the URI of the rule set revision from which the new rule set revision is created. This property enables you to trace the lineage of a rule set. The valid format for this parameter is '/businessRules/ruleSets/${rulesetId}/revisions/${revisionId}'
          schema:
            type: string
            format: /businessRules/ruleSets/{rulesetId}/revisions/{revisionId}
      requestBody:
        content:
          application/vnd.sas.business.rule.set+json:
            schema:
              $ref: "#/components/schemas/ruleSet"
            examples:
              default:
                $ref: "#/components/examples/ruleset"
          application/json:
            schema:
              $ref: "#/components/schemas/ruleSet"
            examples:
              default:
                $ref: "#/components/examples/ruleset"
        description: New content with which to create a rule set revision.
        required: true
      responses:
        "201":
          description: A rule set revision was created.
          headers:
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
            Location:
              schema:
                type: string
                format: uri
          content:
            application/vnd.sas.business.rule.set+json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
        "428":
          description: The request headers did not include a `If-Unmodified-Since` precondition.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
  "/ruleSets/{ruleSetId}/revisions#rules":
    post:
      summary: Create a new revision with rules
      operationId: createNewRevisionWithRules
      tags:
        - Rule Sets
      description: Creates a new revision for the rule set with rules. In this request, you supply the content that you want to initialize for a new revision.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionType
          in: query
          required: false
          description: Valid values are `major` or `minor`. This value determines how the server generates the `major` and `minor` numbers. If a `major` number is provided, the next available major version number is started. For example, if the rule set has revisions 1.0, 1.1, 1.2, 2.0, and 2.1, creating a new major revision results in 3.0. If a `minor` number is provided, then the next available minor revision number is reserved based on the existing revisions. For example, if the existing revisions have `major` and `minor` numbers of 1.1, 1.2, 1.3, 2.1, 2.2, and a user requests a new minor revision, then 2.3 is assigned. This parameter defaults to `minor` if not supplied.
          schema:
            type: string
            enum:
              - major
              - minor
        - name: fromRevisionUri
          in: query
          description: This value specifies the URI of the rule set revision from which the new rule set revision is created. This property enables you to trace the lineage of a rule set. The valid format for this parameter is '/businessRules/ruleSets/${rulesetId}/revisions/${revisionId}'
          schema:
            type: string
            format: /businessRules/ruleSets/{rulesetId}/revisions/{revisionId}
      requestBody:
        content:
          application/vnd.sas.business.rule.set.integral+json:
            schema:
              $ref: "#/components/schemas/ruleSetIntegral"
            examples:
              default:
                $ref: "#/components/examples/ruleSetWithRules"
        description: New content with which to create a rule set revision with rules.
        required: true
      responses:
        "201":
          description: A rule set revision was created.
          headers:
            Last-Modified:
              description: The date and time that the rule set was last modified.
              schema:
                type: string
                format: date-time
            Location:
              schema:
                type: string
                format: uri
          content:
            application/vnd.sas.business.rule.set.integral+json:
              schema:
                $ref: "#/components/schemas/ruleSetIntegral"
              examples:
                default:
                  $ref: "#/components/examples/ruleSetWithRules"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleSetIntegral"
              examples:
                default:
                  $ref: "#/components/examples/ruleSetWithRules"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
        "428":
          description: The request headers did not include a `If-Unmodified-Since` precondition.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/preConditionRequired"
  "/ruleSets/{ruleSetId}/dependencies":
    get:
      summary: Get direct dependent objects
      operationId: getRuleSetDependencies
      description: Retrieves the URIs for the direct dependent objects of the rule set.
      tags:
        - Rule Sets
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The identifier for the rule set.
          schema:
            type: string
          example: 6ad874f9-e6f9-4dfc-ad8b-58fea571af4c
        - name: Accept
          in: header
          description: Used for selecting desired representation.
          schema:
            type: string
            format: media-type
            enum:
              - application/vnd.sas.transfer.dependencies+json
            default: application/vnd.sas.transfer.dependencies+json
            example: application/vnd.sas.transfer.dependencies+json
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.transfer.dependencies+json:
              schema:
                $ref: "#/components/schemas/directDependentObjects"
              examples:
                default:
                  $ref: "#/components/examples/directDependentObjects"
            application/json:
              schema:
                $ref: "#/components/schemas/directDependentObjects"
              examples:
                default:
                  $ref: "#/components/examples/directDependentObjects"
        "404":
          description: No resource exists at the requested path.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}":
    head:
      summary: Get the headers of a rule set revision
      operationId: headersForRuleSetRevision
      tags:
        - Rule Sets
      description: Returns the headers for the specific rule set revision that was requested.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule set revision was last modified.
              schema:
                type: string
                format: date-time
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    get:
      summary: Get a rule set revision
      operationId: getRuleSetRevision
      tags:
        - Rule Sets
      description: Returns the content for the specific rule set revision that was requested.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule set revision was last modified.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.business.rule.set+json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleSet"
              examples:
                default:
                  $ref: "#/components/examples/ruleset"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    delete:
      summary: Delete a rule set revision
      operationId: deleteRuleSetRevision
      tags:
        - Rule Sets
      description: Deletes the specified locked rule set revision. To preserve editable content for users deletion of unlocked versions is not allowed.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      responses:
        "204":
          description: The rule set revision was deleted.
  "/ruleSets/{ruleSetId}/revisions/{revisionId}#revisionSummary":
    get:
      summary: Get a rule set revision
      operationId: getRuleSetRevisionDcmSummary
      tags:
        - Rule Sets
      description: Returns the content of the decisioning revision summary for the specific rule set revision that was requested.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
        - name: start
          in: query
          required: false
          description: The starting index of the first item on a page. The index is 0-based. The default is 0.
          schema:
            type: integer
        - name: limit
          in: query
          required: false
          description: The maximum number of items to return on this page. The actual number of returned items might be less if there are no more items in the collection. The default is 10.
          schema:
            type: integer
        - name: filter
          in: query
          description: >
            The criteria for filtering the function categories. See [Filtering in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#filtering).
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          in: query
          description: >
            The criteria for sorting the function categories. See [Sorting in REST APIs](https://developer.sas.com/rest-apis/businessRules/docs/getting-started/usage-notes#sorting).
          schema:
            type: string
            format: sort-criteria
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The date and time that the rule set revision was last modified.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.dcm.summary+json:
              schema:
                $ref: "#/components/schemas/revisionSummary"
              examples:
                default:
                  $ref: "#/components/examples/summaryOfRuleSet"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}#export":
    get:
      summary: Get the rule set revision as a CSV file
      operationId: getRuleSetRevisionCSV
      tags:
        - Rule Sets
      description: Exports all content for the specific rule set revisions to a CSV file, which matches the CSV format of /rules endpoint.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            text/csv:
              schema:
                type: string
              example: >
                ruleset_id,ruleset_nm,folder_path,ruleset_desc,rule_id,rule_nm,rule_desc,rule_seq_no,conditional,record_rule_fired_flag,datatype,lhs_term,expression,expression_type,expression_order

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,3dd0e878-a573-4b8c-8a50-3a739e2a86ab,HMEQ_loan_bin_RULE1,,1,if,Y,string,,"Lookup(""hmeq_container_job"",JOB)",CONDITION,1

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,3dd0e878-a573-4b8c-8a50-3a739e2a86ab,HMEQ_loan_bin_RULE1,,1,if,Y,decimal,DEBTINC,"<43",CONDITION,2

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,3dd0e878-a573-4b8c-8a50-3a739e2a86ab,HMEQ_loan_bin_RULE1,,1,if,Y,integer,DELINQ,"0",CONDITION,3

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,3dd0e878-a573-4b8c-8a50-3a739e2a86ab,HMEQ_loan_bin_RULE1,,1,if,Y,integer,DEROG,"0",CONDITION,4

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,3dd0e878-a573-4b8c-8a50-3a739e2a86ab,HMEQ_loan_bin_RULE1,,1,if,Y,integer,BAD,"0",CONDITION,5

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,3dd0e878-a573-4b8c-8a50-3a739e2a86ab,HMEQ_loan_bin_RULE1,,1,if,Y,integer,loan_bin,"1",ACTION,1

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,cf5654aa-a902-49b9-a264-402df62715ed,HMEQ_loan_bin_RULE2,,2,if,Y,string,,"Lookup(""hmeq_container_job"",JOB)",CONDITION,1

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,cf5654aa-a902-49b9-a264-402df62715ed,HMEQ_loan_bin_RULE2,,2,if,Y,decimal,DEBTINC,"<43",CONDITION,2

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,cf5654aa-a902-49b9-a264-402df62715ed,HMEQ_loan_bin_RULE2,,2,if,Y,,,"(""DEROG""=1 AND  ""DELINQ""=0) OR (""DEROG""=0 AND  ""DELINQ""=1) OR (""DEROG""=1 AND  ""DELINQ""=1)",CONDITION,3

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,cf5654aa-a902-49b9-a264-402df62715ed,HMEQ_loan_bin_RULE2,,2,if,Y,integer,BAD,"0",CONDITION,4

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,cf5654aa-a902-49b9-a264-402df62715ed,HMEQ_loan_bin_RULE2,,2,if,Y,integer,loan_bin,"2",ACTION,1

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,dc09904e-5c2f-475c-99e1-54950c28c11a,HMEQ_loan_bin_RULE3,,3,if,Y,string,,"Lookup(""hmeq_container_job"",JOB)",CONDITION,1

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,dc09904e-5c2f-475c-99e1-54950c28c11a,HMEQ_loan_bin_RULE3,,3,if,Y,decimal,DEBTINC,"<43",CONDITION,2

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,dc09904e-5c2f-475c-99e1-54950c28c11a,HMEQ_loan_bin_RULE3,,3,if,Y,,,"(""DEROG""=2 AND  ""DELINQ"" IN(0,1)) OR (""DEROG"" IN(0,1) AND  ""DELINQ""=2) OR (""DEROG""=2 AND  ""DELINQ""=2)",CONDITION,3

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,dc09904e-5c2f-475c-99e1-54950c28c11a,HMEQ_loan_bin_RULE3,,3,if,Y,integer,BAD,"0",CONDITION,4

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,dc09904e-5c2f-475c-99e1-54950c28c11a,HMEQ_loan_bin_RULE3,,3,if,Y,integer,loan_bin,"3",ACTION,1

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,39cc1385-7e0b-458d-989f-a13fb95293bc,HMEQ_loan_bin_RULE4,,4,if,Y,string,,"Lookup(""hmeq_container_job"",JOB)",CONDITION,1

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,39cc1385-7e0b-458d-989f-a13fb95293bc,HMEQ_loan_bin_RULE4,,4,if,Y,,,"(43 < ""DEBTINC"" <= 50.1)",CONDITION,2

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,39cc1385-7e0b-458d-989f-a13fb95293bc,HMEQ_loan_bin_RULE4,,4,if,Y,integer,DELINQ,"0",CONDITION,3

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,39cc1385-7e0b-458d-989f-a13fb95293bc,HMEQ_loan_bin_RULE4,,4,if,Y,integer,DEROG,"0",CONDITION,4

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,39cc1385-7e0b-458d-989f-a13fb95293bc,HMEQ_loan_bin_RULE4,,4,if,Y,integer,BAD,"0",CONDITION,5

                e335590e-ded8-47da-950c-6dafbdbf9c57,rs_hmeq_container_with_lookup,/Public/UI Auto Sample Data,,39cc1385-7e0b-458d-989f-a13fb95293bc,HMEQ_loan_bin_RULE4,,4,if,Y,integer,loan_bin,"4",ACTION,1
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/order":
    get:
      summary: Get the rule execution order for the revision
      operationId: getRevisionOrder
      tags:
        - Rule Sets
      description: Gets the order of the rules within the provided rule set revision.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The last time the rule set revision was changed.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.selection+json:
              schema:
                $ref: "#/components/schemas/selection"
              examples:
                default:
                  $ref: "#/components/examples/ruleOrderSelection"
            application/json:
              schema:
                $ref: "#/components/schemas/selection"
              examples:
                default:
                  $ref: "#/components/examples/ruleOrderSelection"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/code":
    get:
      summary: Get the code of a rule set revision
      operationId: getCodeForRevision
      tags:
        - Rule Sets
      description: Returns the package code for a rule set revision.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
        - name: codeTarget
          in: query
          description: >
            The type of platform that the generated code is run on. This affects some aspects of how the code is generated. For example, the MICROANALYTICS variables that are both input and output are listed distinctly in the execute method signature rather than as one 'in_out' parameter. The default is CAS.
          schema:
            type: string
            enum:
              - MICROANALYTICSERVICE
              - CAS
        - name: lookupMode
          in: query
          required: false
          description: Generates the code using references to the reference data domains based on format names, the inline domain contents as conditionals, or the domain contents as a DS2 package. The default is 'format'. If the value is either format or package, the domain contents are expected to already exist in that form on the Cloud Analytic Server and Micro Analytic Score service respectively. This is done by previously activating the domain contents using the SAS Intelligent Decisioning web application or a Reference Data service REST API invocation. Only when executing the code would it be known that the formats or packages do not exist.
          schema:
            type: string
            enum:
              - format
              - inline
              - package
        - name: isGeneratingRuleFiredColumn
          in: query
          required: false
          description: Determines whether the rule fired columns are included in the method signatures within the return package code.
          schema:
            type: boolean
            default: true
        - name: inlineAdvanceListValues
          in: query
          required: false
          description: Specifies whether the currently deployed rows in an advanced list are included as inline values within the generated code. Advanced lists and rows within an advanced list can be deployed by using the SAS Intelligent Decisioning web application, the SAS Fraud Decisioning application, or the List Data API. If this parameter is 'true', the deployed rows in an advanced list are re-created as a data grid in the generated code. If this parameter is 'false', the advanced list must exist as a tabular data set on the Redis server. To get generated code for Cloud Analytic Server, Teradata, or Hadoop destinations, specify 'true' as the parameter value.
          schema:
            type: boolean
        - name: useGlobalVariableCurrentValues
          in: query
          required: false
          description: When this parameter is set to true, the generated code uses the global variables current value (possibly not activated) at code generation time. When set to false the activated global variables value is looked up and used at code execution time.
          schema:
            type: boolean
            default: false
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            text/vnd.sas.source.ds2:
              schema:
                type: string
                format: ds2
              examples:
                default:
                  $ref: "#/components/examples/ds2CodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode":
    post:
      summary: Get the mapped code of a rule set revision
      operationId: getMappedCodeRevision
      tags:
        - Rule Sets
      description: Returns the code bound to the data that is specified in the score request for execution.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/scoreCodeGenerationRequest"
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.score.mapped.code+json:
              schema:
                $ref: "#/components/schemas/mappedCode"
              examples:
                default:
                  $ref: "#/components/examples/mappedCodeOfRuleSet"
            application/json:
              schema:
                $ref: "#/components/schemas/mappedCode"
              examples:
                default:
                  $ref: "#/components/examples/mappedCodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unbound":
    post:
      summary: Get rule set revision code without a score definition
      operationId: getMappedCodeRevisionUnbound
      tags:
        - Rule Sets
      description: Returns the code so that you can run the rule set revision. The code is based on the mapping of the static input (SASEP.IN) and output (SASEP.OUT) data sets, rather than binding to a score definition.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      requestBody:
        content:
          application/vnd.sas.score.code.generation.request.unbound+json:
            schema:
              $ref: "#/components/schemas/unboundScoreCodeGenerationRequest"
            examples:
              default:
                $ref: "#/components/examples/scoreCodeGenerationRequestUnboundForRuleSet"
        description: The information for the mapping and hints.
        required: true
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.score.mapped.code+json:
              schema:
                $ref: "#/components/schemas/mappedCode"
              examples:
                default:
                  $ref: "#/components/examples/mappedCodeOfRuleSet"
            application/json:
              schema:
                $ref: "#/components/schemas/mappedCode"
              examples:
                default:
                  $ref: "#/components/examples/mappedCodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unboundCodeOnly":
    post:
      summary: Get code for rule set revision not bound to score definition
      operationId: getMappedCodeRevisionUnboundText
      tags:
        - Rule Sets
      description: Returns the code directly as text without being wrapped in a JSON model. The text can then be used to run the rule set revision based on the mapping of the static input (SASEP.IN) and output (SASEP.OUT) data sets, rather than binding to a score definition.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      requestBody:
        content:
          application/vnd.sas.score.code.generation.request.unbound+json:
            schema:
              $ref: "#/components/schemas/unboundScoreCodeGenerationRequest"
            examples:
              default:
                $ref: "#/components/examples/scoreCodeGenerationRequestUnboundForRuleSet"
        description: The information for the mapping and hints to be used during building the execution code.
        required: true
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            text/vnd.sas.source.ds2:
              schema:
                type: string
                format: ds2
              examples:
                default:
                  $ref: "#/components/examples/ds2CodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode":
    post:
      summary: Get the analysis code of a rule set revision
      operationId: getAnalysisCodeRevision
      tags:
        - Rule Sets
      description: Returns the analysis code necessary for collecting the information about the rules that fired.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/analysisCodeGenerationRequest"
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.score.analysis.code+json:
              schema:
                $ref: "#/components/schemas/analysisCode"
              examples:
                default:
                  $ref: "#/components/examples/analysisCodeOfRuleSet"
            application/json:
              schema:
                $ref: "#/components/schemas/analysisCode"
              examples:
                default:
                  $ref: "#/components/examples/analysisCodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode#codeOnly":
    post:
      summary: Get analysis code as text for rule set revision
      operationId: getAnalysisCodeRevisionText
      tags:
        - Rule Sets
      description: Returns the analysis code directly as text in response, not contained within a JSON model, to generate rule fired reports based on the analysis request for the rule set revision.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      requestBody:
        $ref: "#/components/requestBodies/analysisCodeGenerationRequest"
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            text/vnd.sas.source.ds2:
              schema:
                type: string
                format: ds2
              examples:
                default:
                  $ref: "#/components/examples/ds2CodeOfRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/decisionStepCode":
    get:
      tags:
        - Rule Sets
      summary: Get the decision step code for a rule set revision
      description: Returns the decision step code for the specified rule set revision.
      operationId: getRulesetRevisionDecisionStepCode
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
        - name: inlineAdvanceListValues
          in: query
          required: false
          description: Specifies whether the currently deployed rows in an advanced list are included as inline values within the generated code. Advanced lists and rows within an advanced list can be deployed by using the SAS Intelligent Decisioning web application, the SAS Fraud Decisioning application, or the List Data API. If this parameter is 'true', the deployed rows in an advanced list are re-created as a data grid in the generated code. If this parameter is 'false', the advanced list must exist as a tabular data set on the Redis server. To get generated code for Cloud Analytic Server, Teradata, or Hadoop destinations, specify 'true' as the parameter value.
          schema:
            type: boolean
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/decisionStepCode"
              examples:
                default:
                  $ref: "#/components/examples/decisionStepCodeOfRuleSet"
            application/vnd.sas.decision.step.code+json:
              schema:
                $ref: "#/components/schemas/decisionStepCode"
              examples:
                default:
                  $ref: "#/components/examples/decisionStepCodeOfRuleSet"
        "404":
          description: No rule set revision exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/vnd.sas.decision.step.code+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/lookups":
    get:
      summary: Get lookups referenced by a rule set revision
      operationId: getRuleSetRevisionLookups
      description: Retrieves the lookups that are referenced by a revision of a rule set.
      tags:
        - Rule Sets
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID that is to be matched.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      responses:
        "200":
          description: A collection of lookups.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/lookupCollection"
              examples:
                default:
                  $ref: "#/components/examples/lookupsUsedInRuleSet"
            application/json:
              schema:
                $ref: "#/components/schemas/lookupCollection"
              examples:
                default:
                  $ref: "#/components/examples/lookupsUsedInRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/referencedResources":
    get:
      summary: Get resources referenced by a rule set revision
      operationId: getRuleSetRevisionReferencedResources
      description: Retrieves the resources that are referenced by a rule set revision.
      tags:
        - Rule Sets
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID that is to be matched.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
      responses:
        "200":
          description: A collection of referenced resources such as lookups and advanced lists.
          headers:
            Last-Modified:
              schema:
                type: string
              example: Wed, 01 Sep 2021 06:22:33 GMT
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/referencedResourceCollection"
              examples:
                default:
                  $ref: "#/components/examples/referencedResouces"
            application/json:
              schema:
                $ref: "#/components/schemas/referencedResourceCollection"
              examples:
                default:
                  $ref: "#/components/examples/referencedResouces"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
        "404":
          description: No resource exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  /ruleSetTerms:
    get:
      summary: Get terms by name in all rule sets
      operationId: getRulesetTerms
      description: Get terms by name in all rule sets.
      tags:
        - Rule Sets
      parameters:
        - name: name
          required: true
          description: The name of the term to search by.
          in: query
          schema:
            type: string
          example: myTermName
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/termSummaryCollection"
              examples:
                default:
                  $ref: "#/components/examples/usageOfTerm"
            application/json:
              schema:
                $ref: "#/components/schemas/termSummaryCollection"
              examples:
                default:
                  $ref: "#/components/examples/usageOfTerm"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/rules":
    get:
      summary: Get all rules for a revision
      operationId: getRulesRevision
      tags:
        - Rules
      description: Returns the rules associated with that rule set revision.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID that is to be matched.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
        - name: filter
          description: An expression for filtering the collection. Valid expressions include eq(member,"string"). Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy`.
          in: query
          schema:
            type: string
            format: filter-criteria
        - name: sortBy
          description: The criteria for sorting the rule sets. Valid `sortBy` parameters include sortBy=id:descending. Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy`.
          in: query
          schema:
            type: string
            format: sort-criteria
        - name: start
          in: query
          required: false
          description: The starting index of the first item on a page. The index is 0-based. The default is 0.
          schema:
            type: integer
        - name: limit
          in: query
          required: false
          description: The maximum number of items to return on this page. The actual number of returned items might be less if there are no more items in the collection. The default is 10.
          schema:
            type: integer
        - name: Accept-Item
          in: header
          description: An alternative media type that the API recognizes. If the media type is not one that the API can provide, a 406 response is returned.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/ruleCollection"
              examples:
                default:
                  $ref: "#/components/examples/collectionOfRulesInRuleSet"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleCollection"
              examples:
                default:
                  $ref: "#/components/examples/collectionOfRulesInRuleSet"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  "/ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid}":
    head:
      summary: Get the headers of a rule for a revision
      operationId: headersForRuleRevision
      tags:
        - Rules
      description: Returns a specific rule header for this rule set revision.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
        - name: rid
          in: path
          required: true
          description: The rule ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The last time the rule was changed.
              schema:
                type: string
                format: date-time
        "404":
          description: No resource exists at the requested path
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
    get:
      summary: Get rule revision details
      operationId: getRuleRevisionDetails
      tags:
        - Rules
      description: Returns the rule's state for the revision provided.
      parameters:
        - name: ruleSetId
          in: path
          required: true
          description: The rule set ID.
          schema:
            type: string
        - name: revisionId
          in: path
          required: true
          description: The rule set revision ID.
          schema:
            type: string
        - name: rid
          in: path
          required: true
          description: The rule ID.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Last-Modified:
              description: The last time the rule was changed.
              schema:
                type: string
                format: date-time
          content:
            application/vnd.sas.business.rule+json:
              schema:
                $ref: "#/components/schemas/businessRule"
              examples:
                default:
                  $ref: "#/components/examples/validateRule"
            application/json:
              schema:
                $ref: "#/components/schemas/businessRule"
              examples:
                default:
                  $ref: "#/components/examples/validateRule"
        "404":
          description: No rule ID exists at the requested path.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/notFound"
  /rules:
    get:
      summary: Get all rules
      operationId: getAllRules
      tags:
        - Rules
      description: Returns all rules based on a query for all rule sets.
      parameters:
        - name: start
          in: query
          description: The starting index of the first item on a page. The index is 0-based. The default is 0.
          schema:
            type: integer
          example: 1
        - name: limit
          in: query
          description: The number of items to return on each page.
          schema:
            type: integer
          example: 100
        - name: filter
          description: An expression for filtering the collection. Valid expressions include eq(member,"string"). Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy`.
          in: query
          schema:
            type: string
            format: filter-criteria
          example: gt(modifiedTimeStamp, '2024-05-03T15:38:49.654Z')
        - name: sortBy
          description: The criteria for sorting the rule sets. Valid `sortBy` parameters include sortBy=id:descending. Allowed members are `id`, `name`, `description`, `modifiedTimeStamp`, `creationTimeStamp`, `modifiedBy`, and `createdBy`.
          in: query
          schema:
            type: string
            format: sort-criteria
          example: modifiedTimeStamp:descending
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            application/vnd.sas.collection+json:
              schema:
                $ref: "#/components/schemas/ruleQueryCollection"
              examples:
                default:
                  $ref: "#/components/examples/ruleQueryCollection"
            application/json:
              schema:
                $ref: "#/components/schemas/ruleQueryCollection"
              examples:
                default:
                  $ref: "#/components/examples/ruleQueryCollection"
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
            application/json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
  /rules#import:
    get:
      summary: Export rules to a CSV file
      operationId: getAllRulesCSV
      tags:
        - Rules
      description: Exports all rules for all rule sets to a CSV file.
      parameters:
        - name: folderPath
          in: query
          description: The path to the folder's content that should be exported. This is recursive and includes the content for all the paths beneath that folder.
          schema:
            type: string
        - name: ruleSetName
          in: query
          description: The name of the rule set to match.
          schema:
            type: string
      responses:
        "200":
          description: The request succeeded.
          headers:
            Sas-Service-Response-Flag:
              $ref: "#/components/headers/Sas-Service-Response-Flag"
          content:
            text/csv:
              schema:
                type: string
              example: >
                ruleset_id,ruleset_nm,folder_path,ruleset_desc,rule_id,rule_nm,rule_desc,rule_seq_no,conditional,record_rule_fired_flag,datatype,lhs_term,expression,expression_type,expression_order

                fc96e3b2-0003-4ebb-bf3b-5409a2183da6,hmeq_ninq,/Users/sasdemo/My Folder,,8eccd5bb-a1f5-4084-8669-e80dd594b881,Default_rule_1,,1,if,Y,decimal,ninq," 1",CONDITION,1

                fc96e3b2-0003-4ebb-bf3b-5409a2183da6,hmeq_ninq,/Users/sasdemo/My Folder,,8eccd5bb-a1f5-4084-8669-e80dd594b881,Default_rule_1,,1,if,Y,string,out,"'ninq is 1'",ACTION,1

                fc96e3b2-0003-4ebb-bf3b-5409a2183da6,hmeq_ninq,/Users/sasdemo/My Folder,,15780b99-88ae-4076-8bd5-0fcd7b9ea8af,Default_rule_2,,2,if,Y,decimal,ninq," 0",CONDITION,1
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
    post:
      summary: Import rules from a CSV file
      operationId: importRules
      tags:
        - Rules
      description: Adds rules to the system via importing large CSV files. Rules are created using the content passed within the CSV file. The passed data should have 1 line for each action and condition.
      requestBody:
        content:
          text/csv:
            schema:
              type: string
            example: >
              ruleset_id,ruleset_nm,folder_path,ruleset_desc,rule_id,rule_nm,rule_desc,rule_seq_no,conditional,record_rule_fired_flag,datatype,lhs_term,expression,expression_type,expression_order

              fc96e3b2-0003-4ebb-bf3b-5409a2183da6,hmeq_ninq,/Users/sasdemo/My Folder,,8eccd5bb-a1f5-4084-8669-e80dd594b881,Default_rule_1,,1,if,Y,decimal,ninq," 1",CONDITION,1

              fc96e3b2-0003-4ebb-bf3b-5409a2183da6,hmeq_ninq,/Users/sasdemo/My Folder,,8eccd5bb-a1f5-4084-8669-e80dd594b881,Default_rule_1,,1,if,Y,string,out,"'ninq is 1'",ACTION,1

              fc96e3b2-0003-4ebb-bf3b-5409a2183da6,hmeq_ninq,/Users/sasdemo/My Folder,,15780b99-88ae-4076-8bd5-0fcd7b9ea8af,Default_rule_2,,2,if,Y,decimal,ninq," 0",CONDITION,1
        description: Rows of CSV formatted data for importing rules. See the `text/csv` media type definition within this API's documentation.
        required: true
      responses:
        "201":
          description: Success and failure responses from CSV import processing. See `multipart/mixed` media type definition within this API's documentation.
          headers:
            Content-Type:
              description: Contains the response content type 'multipart/mixed' and also the boundary string used to segment the parts of the response. For example, boundary="_001_002_003_004_005_006_007_008_009_010_011_012_"
              schema:
                type: string
          content:
            multipart/mixed:
              schema:
                type: string
              example: >
                --_001_002_003_004_005_006_007_008_009_010_011_012_

                Content-Type:text/csv; charset="utf-8";

                Content-ID:Global-Issue

                No global errors.



                --_001_002_003_004_005_006_007_008_009_010_011_012_

                Content-Type:text/csv; charset="utf-8";

                Content-ID:Rejected-csv

                No rejections.



                --_001_002_003_004_005_006_007_008_009_010_011_012_

                Content-Type:text/csv; charset="utf-8";

                Content-ID:Accepted-csv


                --_001_002_003_004_005_006_007_008_009_010_011_012_--

                ruleset_id,ruleset_nm,folder_path,ruleset_desc,rule_id,rule_nm,rule_desc,rule_seq_no,conditional,record_rule_fired_flag,datatype,lhs_term,expression,expression_type,expression_order

                fc96e3b2-0003-4ebb-bf3b-5409a2183da6,hmeq_ninq,/Users/sasdemo/My Folder,,8eccd5bb-a1f5-4084-8669-e80dd594b881,Default_rule_1,,1,if,Y,decimal,ninq," 1",CONDITION,1

                fc96e3b2-0003-4ebb-bf3b-5409a2183da6,hmeq_ninq,/Users/sasdemo/My Folder,,8eccd5bb-a1f5-4084-8669-e80dd594b881,Default_rule_1,,1,if,Y,string,out,"'ninq is 1'",ACTION,1

                fc96e3b2-0003-4ebb-bf3b-5409a2183da6,hmeq_ninq,/Users/sasdemo/My Folder,,15780b99-88ae-4076-8bd5-0fcd7b9ea8af,Default_rule_2,,2,if,Y,decimal,ninq," 0",CONDITION,1
        "400":
          description: The request was invalid.
          content:
            application/vnd.sas.error+json:
              schema:
                $ref: "#/components/schemas/error2"
              examples:
                default:
                  $ref: "#/components/examples/badRequest"
servers:
  - url: https://example.com/businessRules
    description: This is an example of a base URL for businessRules service API guider.
components:
  headers:
    Sas-Service-Response-Flag:
      description: Indicates whether the response is coming from a SAS service.
      schema:
        type: boolean
      example: true
  examples:
    root:
      description: BusinessRules root content.
      value:
        version: 1
        links:
          - method: GET
            rel: getRuleSets
            href: /businessRules/ruleSets
            uri: /businessRules/ruleSets
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set
          - method: POST
            rel: createRuleSet
            href: /businessRules/ruleSets
            uri: /businessRules/ruleSets
            type: application/vnd.sas.business.rule.set
            responseType: application/vnd.sas.business.rule.set
          - method: GET
            rel: getRules
            href: /businessRules/rules
            uri: /businessRules/rules
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.query.result
          - method: POST
            rel: importRules
            href: /businessRules/rules
            uri: /businessRules/rules
            type: text/csv; charset=\"utf-8\";
            responseType: multipart/mixed
          - method: GET
            rel: exportRules
            href: /businessRules/rules
            uri: /businessRules/rules
            type: text/csv; charset=\"utf-8\";
          - method: GET
            rel: getFunctionCategories
            href: /businessRules/functionCategories
            uri: /businessRules/functionCategories
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.function.category
          - method: POST
            rel: createFunctionCategory
            href: /businessRules/functionCategories
            uri: /businessRules/functionCategories
            type: application/vnd.sas.business.rule.function.category
            responseType: application/vnd.sas.business.rule.function.category
          - method: GET
            rel: getFunctions
            href: /businessRules/functions
            uri: /businessRules/functions
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.function
          - method: POST
            rel: createFunction
            href: /businessRules/functions
            uri: /businessRules/functions
            type: application/vnd.sas.business.rule.function
            responseType: application/vnd.sas.business.rule.function
          - method: GET
            rel: ruleSetTerms
            href: /businessRules/ruleSetTerms
            uri: /businessRules/ruleSetTerms
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.term.usage.summary
    badRequest:
      description: Bad request.
      value:
        httpStatusCode: 400
        version: 2
    ruleOrderSelection:
      description: The order selection of the rules in a rule set.
      value:
        version: 1
        type: id
        template: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/rules/{id}
        resources:
          - da5a5617-ebc8-4864-a18d-fd6c29acc5be
          - 8d72248c-3e73-4ff7-af18-9015ada4ab8e
    ruleQueryCollection:
      description: A collection of business rules.
      value:
        links:
          - method: GET
            rel: self
            href: /businessRules/rules?start=0&limit=10
            uri: /businessRules/rules?start=0&limit=10
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.query.result
          - method: GET
            rel: collection
            href: /businessRules/rules
            uri: /businessRules/rules
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.query.result
          - method: GET
            rel: next
            href: /businessRules/rules?start=10&limit=10
            uri: /businessRules/rules?start=10&limit=10
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.query.result
          - method: GET
            rel: last
            href: /businessRules/rules?start=8&limit=10
            uri: /businessRules/rules?start=8&limit=10
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.query.result
          - method: GET
            rel: up
            href: /businessRules
            uri: /businessRules
            type: application/vnd.sas.api
        name: items
        start: 0
        count: 18
        items:
          - creationTimeStamp: 2024-07-03T07:27:29.720Z
            modifiedTimeStamp: 2024-07-03T07:27:29.806Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 41c8f74d-8ef1-4afa-b9cc-77431730ee54
            name: aaduke_15aug11_11_43_43_01_2
            conditional: if
            ruleFiredTrackingEnabled: true
            status: valid
            description: Signal Tech Support contact when defect DEFERed
            conditionExpressions:
              - EVENT LIKE '%DEFER;%'
              - ITSIDS LIKE '% DUKES, AARON;%'
            actionExpressions:
              - MATCHEDRULE = 'aaduke_15aug11_11_43_43_01_2'
            ruleSet:
              creationTimeStamp: 2024-07-03T07:27:29.501Z
              modifiedTimeStamp: 2024-07-03T07:27:29.668Z
              createdBy: sasdemo
              modifiedBy: sasdemo
              id: 045af860-5dde-4fd5-8009-1694cf3eb461
              name: Subscriptions_A
              ruleSetType: assignment
              description: Signals of a Defects user
              majorRevision: 1
              minorRevision: 0
              checkout: false
              locked: false
              version: 6
              signature:
                - creationTimeStamp: 2024-07-03T07:27:29.720Z
                  modifiedTimeStamp: 2024-07-03T07:27:29.720Z
                  createdBy: sasdemo
                  modifiedBy: sasdemo
                  id: 282711d0-fb39-4c1c-a5a5-f0dfb2ec60a2
                  name: EVENT
                  dataType: string
                  direction: inOut
                  generateDataGridColumns: false
                - creationTimeStamp: 2024-07-03T07:27:29.727Z
                  modifiedTimeStamp: 2024-07-03T07:27:29.727Z
                  createdBy: sasdemo
                  modifiedBy: sasdemo
                  id: 8558d37a-1291-47db-b5e7-f1f402cb7620
                  name: ITSIDS
                  dataType: string
                  direction: inOut
                  generateDataGridColumns: false
                - creationTimeStamp: 2024-07-03T07:27:29.730Z
                  modifiedTimeStamp: 2024-07-03T07:27:29.730Z
                  createdBy: sasdemo
                  modifiedBy: sasdemo
                  id: 8e54c16f-1eb8-47f4-b3a1-4cf940f28cc6
                  name: MATCHEDRULE
                  dataType: string
                  direction: output
                  generateDataGridColumns: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/045af860-5dde-4fd5-8009-1694cf3eb461/revisions/946b72f0-c9fa-487d-930a-8eec2b790498/rules/41c8f74d-8ef1-4afa-b9cc-77431730ee54
                uri: /businessRules/ruleSets/045af860-5dde-4fd5-8009-1694cf3eb461/revisions/946b72f0-c9fa-487d-930a-8eec2b790498/rules/41c8f74d-8ef1-4afa-b9cc-77431730ee54
                type: application/vnd.sas.business.rule
              - method: GET
                rel: parent
                href: /businessRules/ruleSets/045af860-5dde-4fd5-8009-1694cf3eb461/revisions/946b72f0-c9fa-487d-930a-8eec2b790498
                uri: /businessRules/ruleSets/045af860-5dde-4fd5-8009-1694cf3eb461/revisions/946b72f0-c9fa-487d-930a-8eec2b790498
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets/045af860-5dde-4fd5-8009-1694cf3eb461/revisions/946b72f0-c9fa-487d-930a-8eec2b790498/rules
                uri: /businessRules/ruleSets/045af860-5dde-4fd5-8009-1694cf3eb461/revisions/946b72f0-c9fa-487d-930a-8eec2b790498/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
            version: 1
          - creationTimeStamp: 2024-04-22T01:06:10.315Z
            modifiedTimeStamp: 2024-04-22T01:06:10.478Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: a117eddb-4635-450b-a9e6-68763fcef53d
            name: Default_rule_1
            conditional: if
            ruleFiredTrackingEnabled: true
            status: valid
            conditionExpressions:
              - Job = 'Other'
            actionExpressions: []
            ruleSet:
              creationTimeStamp: 2024-04-22T01:05:35.220Z
              modifiedTimeStamp: 2024-04-22T01:06:09.915Z
              createdBy: sasdemo
              modifiedBy: sasdemo
              id: 1a673658-1330-4959-9843-bca4ef1dbd6c
              name: hmeq_job_filter
              ruleSetType: filtering
              description: ""
              majorRevision: 1
              minorRevision: 0
              checkout: false
              locked: false
              version: 6
              signature:
                - creationTimeStamp: 2024-04-22T01:06:09.869Z
                  modifiedTimeStamp: 2024-04-22T01:06:09.869Z
                  createdBy: sasdemo
                  modifiedBy: sasdemo
                  id: 95688a0d-e53a-4fa1-8eb5-7bef18ce2ca8
                  name: Job
                  dataType: string
                  direction: inOut
                  description: ""
                  generateDataGridColumns: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions/0d781fdf-d162-4ab3-9a0b-8f378638b706/rules/a117eddb-4635-450b-a9e6-68763fcef53d
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions/0d781fdf-d162-4ab3-9a0b-8f378638b706/rules/a117eddb-4635-450b-a9e6-68763fcef53d
                type: application/vnd.sas.business.rule
              - method: GET
                rel: parent
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions/0d781fdf-d162-4ab3-9a0b-8f378638b706
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions/0d781fdf-d162-4ab3-9a0b-8f378638b706
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions/0d781fdf-d162-4ab3-9a0b-8f378638b706/rules
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions/0d781fdf-d162-4ab3-9a0b-8f378638b706/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
            version: 1
          - creationTimeStamp: 2024-04-26T01:27:16.163Z
            modifiedTimeStamp: 2024-04-26T01:27:16.225Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 044bf48e-5585-4a38-a022-5fd329715f1e
            name: Default_rule_1
            conditional: if
            ruleFiredTrackingEnabled: true
            status: valid
            description: ""
            conditionExpressions:
              - risk >= 1.0
            actionExpressions:
              - risk = 1.0
            ruleSet:
              creationTimeStamp: 2024-04-26T01:27:16.045Z
              modifiedTimeStamp: 2024-04-26T01:27:16.121Z
              createdBy: sasdemo
              modifiedBy: sasdemo
              id: 81ac6952-ac0d-408b-91ad-54717a65ebb1
              name: InverseClage
              ruleSetType: assignment
              majorRevision: 1
              minorRevision: 0
              checkout: false
              locked: false
              version: 6
              signature:
                - creationTimeStamp: 2024-04-26T01:27:16.109Z
                  modifiedTimeStamp: 2024-04-26T01:27:16.109Z
                  createdBy: sasdemo
                  modifiedBy: sasdemo
                  id: 346734f6-c073-4db4-a71e-9eb4156f34ba
                  name: CLAGE
                  dataType: decimal
                  direction: inOut
                  generateDataGridColumns: false
                - creationTimeStamp: 2024-04-26T01:27:16.112Z
                  modifiedTimeStamp: 2024-04-26T01:27:16.112Z
                  createdBy: sasdemo
                  modifiedBy: sasdemo
                  id: 1959f25e-9ec2-4c93-db10-1cc32a9876c6
                  name: risk
                  dataType: decimal
                  direction: output
                  description: ""
                  generateDataGridColumns: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions/8427e43d-7383-4d12-8908-08a8f2d43074/rules/044bf48e-5585-4a38-a022-5fd329715f1e
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions/8427e43d-7383-4d12-8908-08a8f2d43074/rules/044bf48e-5585-4a38-a022-5fd329715f1e
                type: application/vnd.sas.business.rule
              - method: GET
                rel: parent
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions/8427e43d-7383-4d12-8908-08a8f2d43074
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions/8427e43d-7383-4d12-8908-08a8f2d43074
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions/8427e43d-7383-4d12-8908-08a8f2d43074/rules
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions/8427e43d-7383-4d12-8908-08a8f2d43074/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
            version: 1
        limit: 10
        version: 2
    detailedRuleSets:
      description: Rule sets with full details.
      value:
        name: ruleSets
        accept: application/vnd.sas.business.rule.set
        start: 0
        count: 9
        items:
          - creationTimeStamp: 2024-06-17T08:13:45.535Z
            modifiedTimeStamp: 2024-06-17T08:14:32.142Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: c01375b7-154f-47c8-9e6c-18b27b4be692
            name: hmeq_job
            ruleSetType: assignment
            description: ""
            majorRevision: 1
            minorRevision: 0
            status: valid
            checkout: false
            locked: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                type: application/vnd.sas.summary
              - method: GET
                rel: withRules
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                type: application/vnd.sas.business.rule.set.integral
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
              - method: GET
                rel: rules
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/rules
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
              - method: GET
                rel: rulesOrder
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/order
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/order
                type: application/vnd.sas.selection
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/revisions
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMinorRevision
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/revisions?revisionType=minor
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/revisions?revisionType=minor
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMajorRevision
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/revisions?revisionType=major
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/revisions?revisionType=major
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: GET
                rel: code
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/code
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/code
                type: text/vnd.sas.source.ds2
              - method: POST
                rel: mappedCode
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/mappedCode
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/mappedCode
                type: application/vnd.sas.score.code.generation.request
                responseType: application/vnd.sas.score.mapped.code
              - method: POST
                rel: analysisCode
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/analysisCode
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/analysisCode
                type: application/vnd.sas.score.analysis.code.generation.request
                responseType: application/vnd.sas.score.analysis.code
              - method: GET
                rel: metadataDocuments
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/metadataDocuments
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/metadataDocuments
                type: application/zip
              - method: GET
                rel: legacyVariables
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/legacyVariables
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/legacyVariables
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set.variable+json
            signature:
              - creationTimeStamp: 2024-06-17T08:14:32.105Z
                modifiedTimeStamp: 2024-06-17T08:14:32.105Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: d919e0e9-ded5-448d-a641-84efcf1d84fa
                name: Job
                dataType: string
                direction: inOut
                description: ""
                generateDataGridColumns: false
              - creationTimeStamp: 2024-06-17T08:14:32.131Z
                modifiedTimeStamp: 2024-06-17T08:14:32.131Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 8ef5f02f-4bb9-4768-9584-45f00e1118f6
                name: Out
                dataType: string
                direction: output
                description: ""
                generateDataGridColumns: false
            folderType: myFolder
            version: 6
          - creationTimeStamp: 2024-05-23T05:42:35.705Z
            modifiedTimeStamp: 2024-05-23T06:05:40.096Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: fec9f1ee-5442-469c-a9e6-c492ef57db50
            name: Rule_set_manual_lookup
            ruleSetType: assignment
            description: ""
            majorRevision: 1
            minorRevision: 0
            status: valid
            checkout: false
            locked: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
                type: application/vnd.sas.summary
              - method: GET
                rel: withRules
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
                type: application/vnd.sas.business.rule.set.integral
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50
              - method: GET
                rel: rules
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/rules
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
              - method: GET
                rel: rulesOrder
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/order
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/order
                type: application/vnd.sas.selection
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/revisions
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMinorRevision
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/revisions?revisionType=minor
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/revisions?revisionType=minor
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMajorRevision
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/revisions?revisionType=major
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/revisions?revisionType=major
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: GET
                rel: code
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/code
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/code
                type: text/vnd.sas.source.ds2
              - method: POST
                rel: mappedCode
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/mappedCode
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/mappedCode
                type: application/vnd.sas.score.code.generation.request
                responseType: application/vnd.sas.score.mapped.code
              - method: POST
                rel: analysisCode
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/analysisCode
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/analysisCode
                type: application/vnd.sas.score.analysis.code.generation.request
                responseType: application/vnd.sas.score.analysis.code
              - method: GET
                rel: metadataDocuments
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/metadataDocuments
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/metadataDocuments
                type: application/zip
              - method: GET
                rel: legacyVariables
                href: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/legacyVariables
                uri: /businessRules/ruleSets/fec9f1ee-5442-469c-a9e6-c492ef57db50/legacyVariables
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set.variable+json
            signature:
              - creationTimeStamp: 2024-05-23T05:45:30.708Z
                modifiedTimeStamp: 2024-05-23T05:45:30.709Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 7e42abfb-6e42-4a64-a0b7-5871d6bb2c92
                name: Type
                dataType: string
                direction: inOut
                description: ""
                generateDataGridColumns: false
              - creationTimeStamp: 2024-05-23T05:45:30.725Z
                modifiedTimeStamp: 2024-05-23T05:45:30.725Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: ee9e2781-fda5-404e-9dce-f01a6400af58
                name: value
                dataType: string
                direction: output
                description: ""
                generateDataGridColumns: false
            folderType: myFolder
            version: 6
          - creationTimeStamp: 2024-04-28T06:57:32.375Z
            modifiedTimeStamp: 2024-04-28T07:20:36.263Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: d6640f32-51a8-4df5-b523-e249173c4f32
            name: Rule_set1
            ruleSetType: assignment
            description: ""
            majorRevision: 1
            minorRevision: 1
            status: valid
            checkout: false
            locked: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
                type: application/vnd.sas.summary
              - method: GET
                rel: withRules
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
                type: application/vnd.sas.business.rule.set.integral
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32
              - method: GET
                rel: rules
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/rules
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
              - method: GET
                rel: rulesOrder
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/order
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/order
                type: application/vnd.sas.selection
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/revisions
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMinorRevision
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/revisions?revisionType=minor
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/revisions?revisionType=minor
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMajorRevision
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/revisions?revisionType=major
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/revisions?revisionType=major
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: GET
                rel: code
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/code
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/code
                type: text/vnd.sas.source.ds2
              - method: POST
                rel: mappedCode
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/mappedCode
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/mappedCode
                type: application/vnd.sas.score.code.generation.request
                responseType: application/vnd.sas.score.mapped.code
              - method: POST
                rel: analysisCode
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/analysisCode
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/analysisCode
                type: application/vnd.sas.score.analysis.code.generation.request
                responseType: application/vnd.sas.score.analysis.code
              - method: GET
                rel: metadataDocuments
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/metadataDocuments
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/metadataDocuments
                type: application/zip
              - method: GET
                rel: legacyVariables
                href: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/legacyVariables
                uri: /businessRules/ruleSets/d6640f32-51a8-4df5-b523-e249173c4f32/legacyVariables
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set.variable+json
            signature: []
            folderType: folder
            version: 6
          - creationTimeStamp: 2024-04-28T06:57:59.097Z
            modifiedTimeStamp: 2024-04-28T06:57:59.171Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 052fc19c-c359-45e4-9d37-7a705d7681df
            name: Rule_set_general
            ruleSetType: assignment
            description: ""
            majorRevision: 1
            minorRevision: 0
            status: valid
            checkout: false
            locked: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
                type: application/vnd.sas.summary
              - method: GET
                rel: withRules
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
                type: application/vnd.sas.business.rule.set.integral
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df
              - method: GET
                rel: rules
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/rules
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
              - method: GET
                rel: rulesOrder
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/order
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/order
                type: application/vnd.sas.selection
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/revisions
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMinorRevision
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/revisions?revisionType=minor
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/revisions?revisionType=minor
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMajorRevision
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/revisions?revisionType=major
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/revisions?revisionType=major
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: GET
                rel: code
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/code
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/code
                type: text/vnd.sas.source.ds2
              - method: POST
                rel: mappedCode
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/mappedCode
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/mappedCode
                type: application/vnd.sas.score.code.generation.request
                responseType: application/vnd.sas.score.mapped.code
              - method: POST
                rel: analysisCode
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/analysisCode
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/analysisCode
                type: application/vnd.sas.score.analysis.code.generation.request
                responseType: application/vnd.sas.score.analysis.code
              - method: GET
                rel: metadataDocuments
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/metadataDocuments
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/metadataDocuments
                type: application/zip
              - method: GET
                rel: legacyVariables
                href: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/legacyVariables
                uri: /businessRules/ruleSets/052fc19c-c359-45e4-9d37-7a705d7681df/legacyVariables
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set.variable+json
            signature: []
            folderType: myFolder
            version: 6
          - creationTimeStamp: 2024-04-26T01:27:16.045Z
            modifiedTimeStamp: 2024-04-26T01:27:16.121Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 81ac6952-ac0d-408b-91ad-54717a65ebb1
            name: InverseClage
            ruleSetType: assignment
            majorRevision: 1
            minorRevision: 0
            status: valid
            checkout: false
            locked: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                type: application/vnd.sas.summary
              - method: GET
                rel: withRules
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                type: application/vnd.sas.business.rule.set.integral
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
              - method: GET
                rel: rules
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
              - method: GET
                rel: rulesOrder
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/order
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/order
                type: application/vnd.sas.selection
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMinorRevision
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions?revisionType=minor
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions?revisionType=minor
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMajorRevision
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions?revisionType=major
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/revisions?revisionType=major
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: GET
                rel: code
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/code
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/code
                type: text/vnd.sas.source.ds2
              - method: POST
                rel: mappedCode
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/mappedCode
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/mappedCode
                type: application/vnd.sas.score.code.generation.request
                responseType: application/vnd.sas.score.mapped.code
              - method: POST
                rel: analysisCode
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/analysisCode
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/analysisCode
                type: application/vnd.sas.score.analysis.code.generation.request
                responseType: application/vnd.sas.score.analysis.code
              - method: GET
                rel: metadataDocuments
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/metadataDocuments
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/metadataDocuments
                type: application/zip
              - method: GET
                rel: legacyVariables
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/legacyVariables
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/legacyVariables
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set.variable+json
            signature:
              - creationTimeStamp: 2024-04-26T01:27:16.109Z
                modifiedTimeStamp: 2024-04-26T01:27:16.109Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 346734f6-c073-4db4-a71e-9eb4156f34ba
                name: CLAGE
                dataType: decimal
                direction: inOut
                generateDataGridColumns: false
              - creationTimeStamp: 2024-04-26T01:27:16.112Z
                modifiedTimeStamp: 2024-04-26T01:27:16.112Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 1959f25e-9ec2-4c93-db10-1cc32a9876c6
                name: risk
                dataType: decimal
                direction: output
                description: ""
                generateDataGridColumns: false
            version: 6
          - creationTimeStamp: 2024-04-24T01:14:30.479Z
            modifiedTimeStamp: 2024-04-24T01:23:40.904Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: c39fcf9a-cc43-4885-be41-909862e2466a
            name: hmeq_rule
            ruleSetType: assignment
            description: ""
            majorRevision: 1
            minorRevision: 0
            status: error
            checkout: false
            locked: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
                type: application/vnd.sas.summary
              - method: GET
                rel: withRules
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
                type: application/vnd.sas.business.rule.set.integral
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a
              - method: GET
                rel: rules
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/rules
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
              - method: GET
                rel: rulesOrder
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/order
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/order
                type: application/vnd.sas.selection
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/revisions
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMinorRevision
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/revisions?revisionType=minor
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/revisions?revisionType=minor
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMajorRevision
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/revisions?revisionType=major
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/revisions?revisionType=major
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: GET
                rel: code
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/code
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/code
                type: text/vnd.sas.source.ds2
              - method: POST
                rel: mappedCode
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/mappedCode
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/mappedCode
                type: application/vnd.sas.score.code.generation.request
                responseType: application/vnd.sas.score.mapped.code
              - method: POST
                rel: analysisCode
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/analysisCode
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/analysisCode
                type: application/vnd.sas.score.analysis.code.generation.request
                responseType: application/vnd.sas.score.analysis.code
              - method: GET
                rel: metadataDocuments
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/metadataDocuments
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/metadataDocuments
                type: application/zip
              - method: GET
                rel: legacyVariables
                href: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/legacyVariables
                uri: /businessRules/ruleSets/c39fcf9a-cc43-4885-be41-909862e2466a/legacyVariables
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set.variable+json
            signature:
              - creationTimeStamp: 2024-04-24T01:23:27.460Z
                modifiedTimeStamp: 2024-04-24T01:23:27.460Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: a5583440-fa99-43a2-aec3-78cca378ab8b
                name: ninq
                dataType: decimal
                direction: inOut
                description: ""
                generateDataGridColumns: false
              - creationTimeStamp: 2024-04-24T01:23:27.464Z
                modifiedTimeStamp: 2024-04-24T01:23:27.464Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 04d76e12-9c52-4902-8d26-92e617cbb92e
                name: job
                dataType: string
                direction: inOut
                description: ""
                generateDataGridColumns: false
              - creationTimeStamp: 2024-04-24T01:23:27.466Z
                modifiedTimeStamp: 2024-04-24T01:23:27.466Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 54193895-e737-47f9-b1f9-7c85a4e79850
                name: out
                dataType: string
                direction: output
                description: ""
                generateDataGridColumns: false
            folderType: trashFolder
            version: 6
          - creationTimeStamp: 2024-04-24T01:12:29.030Z
            modifiedTimeStamp: 2024-04-24T01:13:52.634Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 5a6adea0-b788-422b-8beb-ca8e2a5267f4
            name: hemq_common_rule
            ruleSetType: common
            description: ""
            majorRevision: 1
            minorRevision: 0
            status: valid
            checkout: false
            locked: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
                type: application/vnd.sas.summary
              - method: GET
                rel: withRules
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
                type: application/vnd.sas.business.rule.set.integral
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4
              - method: GET
                rel: rules
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/rules
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
              - method: GET
                rel: rulesOrder
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/order
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/order
                type: application/vnd.sas.selection
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/revisions
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMinorRevision
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/revisions?revisionType=minor
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/revisions?revisionType=minor
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMajorRevision
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/revisions?revisionType=major
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/revisions?revisionType=major
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: GET
                rel: code
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/code
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/code
                type: text/vnd.sas.source.ds2
              - method: POST
                rel: mappedCode
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/mappedCode
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/mappedCode
                type: application/vnd.sas.score.code.generation.request
                responseType: application/vnd.sas.score.mapped.code
              - method: POST
                rel: analysisCode
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/analysisCode
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/analysisCode
                type: application/vnd.sas.score.analysis.code.generation.request
                responseType: application/vnd.sas.score.analysis.code
              - method: GET
                rel: metadataDocuments
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/metadataDocuments
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/metadataDocuments
                type: application/zip
              - method: GET
                rel: legacyVariables
                href: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/legacyVariables
                uri: /businessRules/ruleSets/5a6adea0-b788-422b-8beb-ca8e2a5267f4/legacyVariables
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set.variable+json
            signature:
              - creationTimeStamp: 2024-04-24T01:13:52.623Z
                modifiedTimeStamp: 2024-04-24T01:13:52.623Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: e960b373-6d3a-41f6-bfff-81760760e018
                name: job
                dataType: string
                direction: inOut
                description: ""
                generateDataGridColumns: false
              - creationTimeStamp: 2024-04-24T01:13:52.627Z
                modifiedTimeStamp: 2024-04-24T01:13:52.627Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: e00ca6e5-0e2a-4651-8fa2-5f7336c2bb74
                name: out
                dataType: string
                direction: output
                description: ""
                generateDataGridColumns: false
            folderType: myFolder
            version: 6
          - creationTimeStamp: 2024-04-23T06:17:59.007Z
            modifiedTimeStamp: 2024-04-24T01:12:06.669Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 362bd2d9-4070-41c4-8d08-e89b00db05fa
            name: Rule_set_1datagrid
            ruleSetType: assignment
            description: ""
            majorRevision: 1
            minorRevision: 0
            status: valid
            checkout: false
            locked: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
                type: application/vnd.sas.summary
              - method: GET
                rel: withRules
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
                type: application/vnd.sas.business.rule.set.integral
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa
              - method: GET
                rel: rules
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/rules
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
              - method: GET
                rel: rulesOrder
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/order
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/order
                type: application/vnd.sas.selection
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/revisions
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMinorRevision
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/revisions?revisionType=minor
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/revisions?revisionType=minor
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMajorRevision
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/revisions?revisionType=major
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/revisions?revisionType=major
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: GET
                rel: code
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/code
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/code
                type: text/vnd.sas.source.ds2
              - method: POST
                rel: mappedCode
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/mappedCode
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/mappedCode
                type: application/vnd.sas.score.code.generation.request
                responseType: application/vnd.sas.score.mapped.code
              - method: POST
                rel: analysisCode
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/analysisCode
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/analysisCode
                type: application/vnd.sas.score.analysis.code.generation.request
                responseType: application/vnd.sas.score.analysis.code
              - method: GET
                rel: metadataDocuments
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/metadataDocuments
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/metadataDocuments
                type: application/zip
              - method: GET
                rel: legacyVariables
                href: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/legacyVariables
                uri: /businessRules/ruleSets/362bd2d9-4070-41c4-8d08-e89b00db05fa/legacyVariables
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set.variable+json
            signature:
              - creationTimeStamp: 2024-04-24T01:05:11.533Z
                modifiedTimeStamp: 2024-04-24T01:05:11.533Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 5887e954-0dee-430e-b124-36b6b8e66dc7
                name: Job
                dataType: string
                direction: inOut
                description: ""
                generateDataGridColumns: false
              - creationTimeStamp: 2024-04-24T01:05:11.540Z
                modifiedTimeStamp: 2024-04-24T01:05:11.540Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 54a1b13b-ac12-4a4e-b112-f9ad894af26c
                name: Ninq
                dataType: decimal
                direction: inOut
                description: ""
                generateDataGridColumns: false
              - creationTimeStamp: 2024-04-24T01:05:11.541Z
                modifiedTimeStamp: 2024-04-24T01:05:11.541Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 1afdd2ef-1cab-4341-b143-3e3081fc2fab
                name: Out
                dataType: string
                direction: output
                description: ""
                generateDataGridColumns: false
            folderType: trashFolder
            version: 6
          - creationTimeStamp: 2024-04-22T01:05:35.220Z
            modifiedTimeStamp: 2024-04-22T01:06:09.915Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 1a673658-1330-4959-9843-bca4ef1dbd6c
            name: hmeq_job_filter
            ruleSetType: filtering
            description: ""
            majorRevision: 1
            minorRevision: 0
            status: valid
            checkout: false
            locked: false
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
                type: application/vnd.sas.summary
              - method: GET
                rel: withRules
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
                type: application/vnd.sas.business.rule.set.integral
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c
              - method: GET
                rel: rules
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/rules
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
              - method: GET
                rel: rulesOrder
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/order
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/order
                type: application/vnd.sas.selection
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMinorRevision
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions?revisionType=minor
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions?revisionType=minor
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: POST
                rel: createMajorRevision
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions?revisionType=major
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/revisions?revisionType=major
                type: application/vnd.sas.business.rule.set
                responseType: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
              - method: GET
                rel: code
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/code
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/code
                type: text/vnd.sas.source.ds2
              - method: POST
                rel: mappedCode
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/mappedCode
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/mappedCode
                type: application/vnd.sas.score.code.generation.request
                responseType: application/vnd.sas.score.mapped.code
              - method: POST
                rel: analysisCode
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/analysisCode
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/analysisCode
                type: application/vnd.sas.score.analysis.code.generation.request
                responseType: application/vnd.sas.score.analysis.code
              - method: GET
                rel: metadataDocuments
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/metadataDocuments
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/metadataDocuments
                type: application/zip
              - method: GET
                rel: legacyVariables
                href: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/legacyVariables
                uri: /businessRules/ruleSets/1a673658-1330-4959-9843-bca4ef1dbd6c/legacyVariables
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set.variable+json
            signature:
              - creationTimeStamp: 2024-04-22T01:06:09.869Z
                modifiedTimeStamp: 2024-04-22T01:06:09.869Z
                createdBy: sasdemo
                modifiedBy: sasdemo
                id: 95688a0d-e53a-4fa1-8eb5-7bef18ce2ca8
                name: Job
                dataType: string
                direction: inOut
                description: ""
                generateDataGridColumns: false
            folderType: myFolder
            version: 6
        limit: 10
        version: 2
        links:
          - method: GET
            rel: collection
            href: /businessRules/ruleSets
            uri: /businessRules/ruleSets
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set
          - method: GET
            rel: self
            href: /businessRules/ruleSets?sortBy=modifiedTimeStamp:descending&start=0&limit=10
            uri: /businessRules/ruleSets?sortBy=modifiedTimeStamp:descending&start=0&limit=10
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set
          - method: POST
            rel: createRuleSet
            href: /businessRules/ruleSets
            uri: /businessRules/ruleSets
            type: application/vnd.sas.business.rule.set
            responseType: application/vnd.sas.business.rule.set
          - method: GET
            rel: getDefaultRuleSetThumbnail
            href: /businessRules/ruleSets/defaultRuleSetThumbnail.svg
            uri: /businessRules/ruleSets/defaultRuleSetThumbnail.svg
    ruleSetWithRules:
      description: A rule set that contains all of the rules from the latest revision.
      value:
        id: 3c14f0b9-34f2-4778-88e5-d49f229f57db
        name: DiscountEligibility
        ruleSetType: filtering
        majorRevision: 1
        minorRevision: 0
        status: valid
        checkout: false
        locked: false
        signature:
          - id: 7c7b4ccd-e552-4739-7745-38052fc162fb
            name: TitleCode
            dataType: string
            direction: inOut
            description: ""
            generateDataGridColumns: false
        rules:
          - version: 3
            id: cc441f7e-933a-4e14-a966-8496310e8227
            name: Default_rule_1
            description: ""
            ruleFiredTrackingEnabled: true
            conditional: if
            conditions:
              - term:
                  id: 7c7b4ccd-e552-4739-7745-38052fc162fb
                  name: TitleCode
                  dataType: string
                  direction: inOut
                  description: ""
                  generateDataGridColumns: false
                lookup:
                  id: 320e6e43-ad38-4cfc-bcf9-4fecd33c5570
                  name: TitleCode
                status: valid
                id: 7f677dee-127a-4451-8aa1-b1c38477d820
                type: lookup
            status: valid
        version: 1
    errorCollection:
      description: A collection of errors.
      value:
        name: errors
        accept: application/vnd.sas.error+json
        version: 2
        items:
          - id: 4f4bf2a3-5eaa-4899-b238-0e3ebd21ef68
            message: No permission.
            statusCode: 1
            errorCode: 401
          - id: 4f4bf2a3-5eaa-4899-b234-0e3ebd21ef68
            message: Function arguments must be separated by commas.
            statusCode: 1
            errorCode: 500
          - errorCode: 13750
            message: The variable name "cv11" is invalid.
            remediation: null
            version: 2
            httpStatusCode: 200
    collectionOfRulesInRuleSet:
      description: A collection of rules in a rule set.
      value:
        links:
          - method: GET
            rel: collection
            href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules
            uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule
        name: rules
        accept: application/vnd.sas.business.rule
        start: 0
        count: 2
        items:
          - creationTimeStamp: 2024-04-26T01:27:16.145Z
            modifiedTimeStamp: 2024-04-26T01:27:16.176Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            version: 3
            id: 7553d9d8-e60c-4a35-bac1-92e65d0005e7
            name: Default_assignment_2
            description: assignment
            ruleFiredTrackingEnabled: false
            conditional: if
            conditions: []
            actions:
              - expression: risk = 70/clage
                status: valid
                id: 48a13c81-a259-4caa-aa20-b52ad192131f
                type: complex
            mappings: []
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/7553d9d8-e60c-4a35-bac1-92e65d0005e7
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/7553d9d8-e60c-4a35-bac1-92e65d0005e7
                type: application/vnd.sas.business.rule
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/7553d9d8-e60c-4a35-bac1-92e65d0005e7
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/7553d9d8-e60c-4a35-bac1-92e65d0005e7
                type: application/vnd.sas.business.rule
                responseType: application/vnd.sas.business.rule
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/7553d9d8-e60c-4a35-bac1-92e65d0005e7
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/7553d9d8-e60c-4a35-bac1-92e65d0005e7
              - method: GET
                rel: parent
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
            status: valid
          - creationTimeStamp: 2024-04-26T01:27:16.163Z
            modifiedTimeStamp: 2024-04-26T01:27:16.225Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            version: 3
            id: 044bf48e-5585-4a38-a022-5fd329715f1e
            name: Default_rule_1
            description: ""
            ruleFiredTrackingEnabled: true
            conditional: if
            conditions:
              - expression: ">= 1.0"
                status: valid
                id: 6832cc6c-0f4c-4ba6-bb28-f93e146c1d31
                type: decisionTable
                term:
                  creationTimeStamp: 2024-04-26T01:27:16.112Z
                  modifiedTimeStamp: 2024-04-26T01:27:16.112Z
                  createdBy: sasdemo
                  modifiedBy: sasdemo
                  id: 1959f25e-9ec2-4c93-db10-1cc32a9876c6
                  name: risk
                  dataType: decimal
                  direction: output
                  description: ""
                  generateDataGridColumns: false
            actions:
              - expression: "1.0"
                status: valid
                id: f967aade-69e3-4f97-9b31-25bb8a940b6c
                type: assignment
                term:
                  creationTimeStamp: 2024-04-26T01:27:16.112Z
                  modifiedTimeStamp: 2024-04-26T01:27:16.112Z
                  createdBy: sasdemo
                  modifiedBy: sasdemo
                  id: 1959f25e-9ec2-4c93-db10-1cc32a9876c6
                  name: risk
                  dataType: decimal
                  direction: output
                  description: ""
                  generateDataGridColumns: false
            mappings: []
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/044bf48e-5585-4a38-a022-5fd329715f1e
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/044bf48e-5585-4a38-a022-5fd329715f1e
                type: application/vnd.sas.business.rule
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/044bf48e-5585-4a38-a022-5fd329715f1e
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/044bf48e-5585-4a38-a022-5fd329715f1e
                type: application/vnd.sas.business.rule
                responseType: application/vnd.sas.business.rule
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/044bf48e-5585-4a38-a022-5fd329715f1e
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules/044bf48e-5585-4a38-a022-5fd329715f1e
              - method: GET
                rel: parent
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: up
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1/rules
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule
            status: valid
        limit: 10
        version: 2
    usageOfTerm:
      description: A usage summary of a term.
      value:
        name: items
        accept: application/vnd.sas.term.usage.summary
        items:
          - parentName: InverseClage
            parentUri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
            name: CLAGE
            dataType: decimal
            direction: inOut
            links:
              - method: GET
                rel: self
                href: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                uri: /businessRules/ruleSets/81ac6952-ac0d-408b-91ad-54717a65ebb1
                type: application/vnd.sas.business.rule.set
        version: 2
    ruleset:
      description: a simple ruleset
      value:
        name: filteringRulesetTest
        ruleSetType: filtering
        description: a filtering ruleset test
        majorRevision: 1
        minorRevision: 0
        status: valid
        locked: false
        signature:
          - id: 9669d209-53e2-4f6c-085b-d554da3e8442
            name: inputString
            creationTimeStamp: 2020-09-30T17:54:13.738Z
            modifiedTimeStamp: 2020-09-30T17:54:13.738Z
            createdBy: sasboot
            modifiedBy: sasboot
            dataType: string
            direction: inOut
            description: ""
    analysisCodeOfRuleSet:
      description: Generated analysis code for a rule set.
      value:
        code: >-
          /*rule fired detail*/ thread brm_rf_detail_thread / inline; dcl varchar(100)  "RULE_NM"; dcl varchar(100)  "RULE_SET_NM"; dcl varchar(36)   "RULE_SET_ID";

          dcl varchar(36)   "RULE_SET_VERSION_ID"; dcl varchar(36)   "RULE_ID";

          dcl varchar(36)   "rule_action_fire_id"; dcl integer       "ruleFiredSequence";


          dcl package hash  ruleFireFlagOffsetHash; dcl package hiter ruleFiredHashIterator;

          dcl integer       ruleFiredFlagPosition; dcl integer       ruleFiredBasePosition;


          keep "rule_action_fire_id" "RULE_NM" "RULE_SET_ID" "RULE_SET_VERSION_ID" "RULE_SET_NM" "RULE_ID" "ruleFiredSequence" "_recordCorrelationKey";

          method initRuleFireHashes(); if null(ruleFireFlagOffsetHash) then do; ruleFireFlagOffsetHash = _new_ [this] hash(); ruleFireFlagOffsetHash.keys([RULE_ID]); ruleFireFlagOffsetHash.data([RULE_ID ruleFiredFlagPosition RULE_NM RULE_SET_ID RULE_SET_VERSION_ID RULE_SET_NM]); ruleFireFlagOffsetHash.defineDone(); ruleFireFlagOffsetHash.clear(); end; ruleFiredFlagPosition    = ruleFiredBasePosition; RULE_ID = 'da5a5617-ebc8-4864-a18d-fd6c29acc5be'; "RULE_NM" = 'Default_rule_2'; "RULE_SET_ID" = '1525f975-eb00-4602-bf73-f9d1f020a178'; "RULE_SET_VERSION_ID" = 'cee3b513-d75d-4757-869f-a835a76baa08'; "RULE_SET_NM"    = 'ppn_rs1'; ruleFireFlagOffsetHash.ref(); ruleFiredFlagPosition  = ruleFiredFlagPosition+1; RULE_ID = '8d72248c-3e73-4ff7-af18-9015ada4ab8e'; "RULE_NM" = 'Default_rule_3'; "RULE_SET_ID" = '1525f975-eb00-4602-bf73-f9d1f020a178'; "RULE_SET_VERSION_ID" = 'cee3b513-d75d-4757-869f-a835a76baa08'; "RULE_SET_NM"  = 'ppn_rs1'; ruleFireFlagOffsetHash.ref(); ruleFiredFlagPosition   = ruleFiredFlagPosition+1; end;

          method init(); ruleFiredBasePosition   = 1; initRuleFireHashes(); ruleFiredHashIterator = _new_ hiter('ruleFireFlagOffsetHash'); end;

          method run(); dcl double rfLen; set "public"."ppn_rs1_Test_ppn_rs1_2024-07-01_06-44-38_output"

          (keep=("ruleFiredFlags" "_recordCorrelationKey")); rfLen   = lengthc("ruleFiredFlags"); ruleFiredHashIterator.first(); do until (ruleFiredHashIterator.next()); if ruleFiredFlagPosition > 0 and  ruleFiredFlagPosition <= rfLen then do; if (substr("ruleFiredFlags",ruleFiredFlagPosition,1) = '1') then do; "rule_action_fire_id"=uuidgen(); "ruleFiredSequence"=ruleFiredFlagPosition; output ; end; end; end;

          end;


          method term(); ruleFiredHashIterator.delete(); rulefireFlagoffsethash.delete();

          end; endthread;

          data "public"."OUT_ruleFired" (overwrite=yes ) ;

          dcl thread  brm_rf_detail_thread _t;

          method run(); set from _t; output; end; enddata;
        codeType: text/vnd.sas.source.ds2
        outputTableName: OUT_ruleFired
        outputLibraryName: public
        analysisType: ruleFiredDetails
        version: 1
    summaryOfRuleSet:
      description: The summary of a rule set.
      value:
        creationTimeStamp: 2024-07-01T05:28:53.812Z
        modifiedTimeStamp: 2024-07-01T05:28:54.206Z
        createdBy: sasdemo
        modifiedBy: sasdemo
        id: 1525f975-eb00-4602-bf73-f9d1f020a178
        name: ppn_rs1
        majorRevision: 1
        minorRevision: 0
        locked: false
        links:
          - method: GET
            rel: self
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            type: application/vnd.sas.business.rule.set
          - method: GET
            rel: alternate
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            type: application/vnd.sas.summary
          - method: GET
            rel: withRules
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            type: application/vnd.sas.business.rule.set.integral
          - method: PUT
            rel: update
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            type: application/vnd.sas.business.rule.set
            responseType: application/vnd.sas.business.rule.set
          - method: DELETE
            rel: delete
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
          - method: GET
            rel: rules
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/rules
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/rules
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule
          - method: GET
            rel: rulesOrder
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/order
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/order
            type: application/vnd.sas.selection
          - method: GET
            rel: revisions
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set
          - method: POST
            rel: createMinorRevision
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions?revisionType=minor
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions?revisionType=minor
            type: application/vnd.sas.business.rule.set
            responseType: application/vnd.sas.business.rule.set
          - method: POST
            rel: createMajorRevision
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions?revisionType=major
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions?revisionType=major
            type: application/vnd.sas.business.rule.set
            responseType: application/vnd.sas.business.rule.set
          - method: GET
            rel: up
            href: /businessRules/ruleSets
            uri: /businessRules/ruleSets
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set
          - method: GET
            rel: code
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/code
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/code
            type: text/vnd.sas.source.ds2
          - method: POST
            rel: mappedCode
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/mappedCode
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/mappedCode
            type: application/vnd.sas.score.code.generation.request
            responseType: application/vnd.sas.score.mapped.code
          - method: POST
            rel: analysisCode
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/analysisCode
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/analysisCode
            type: application/vnd.sas.score.analysis.code.generation.request
            responseType: application/vnd.sas.score.analysis.code
          - method: GET
            rel: metadataDocuments
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/metadataDocuments
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/metadataDocuments
            type: application/zip
          - method: GET
            rel: legacyVariables
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/legacyVariables
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/legacyVariables
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set.variable+json
        version: 1
    functionCategory:
      description: Content of a function category
      value:
        name: statistical_functions
        description: Functions used to calculate various statistics.
        hidden: false
    scoreCodeGenerationRequestUnboundForRuleSet:
      description: A request to generate score code unbound.
      value:
        mappings:
          - mappingType: static
            mappingValue: 25
            variableName: a
        hints:
          outputLibraryName: public
          tableBaseName: test_outputTable_
          isGeneratingRuleFiredColumn: "true"
          variableCarried: "true"
          traversedPathFlag: "true"
          lookupMode: INLINE
          codeTarget: PROCDS2
          inputLibraryName: public
          inputTableName: output
          filterToBeRecordedFlag: "true"
    lookupsUsedInRuleSet:
      description: A collection of lookups that are used in a rule set.
      value:
        links:
          - method: GET
            rel: collection
            href: /businessRules/ruleSets/e335590e-ded8-47da-950c-6dafbdbf9c57/revisions/0bde8adb-5baa-4142-a950-ba4ee780873a/lookups
            uri: /businessRules/ruleSets/e335590e-ded8-47da-950c-6dafbdbf9c57/revisions/0bde8adb-5baa-4142-a950-ba4ee780873a/lookups
            type: application/vnd.sas.collection
            itemType: application/json
        name: lookups
        count: 1
        items:
          - id: 6ba098d7-37b9-4ba9-a8c8-5211a55ded82
            version: 2
            name: $LNOQJRVZXXFF2TKGIKII2KXPNQI_K
            realName: hmeq_container_job
            packageName: lnoqjrvzxxff2tkgikii2kxpnqi
            checkout: false
        version: 2
    conditionConversion:
      description: The request body to convert the condition.
      value:
        source:
          term:
            creationTimeStamp: 2024-07-02T15:10:10.267Z
            modifiedTimeStamp: 2024-07-02T15:10:10.267Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 5ad020cb+b931+40d4+e8b9+61fdb3cdbb7a
            name: JOB
            dataType: string
            direction: inOut
          expression: = JSales
          status: valid
          id: 5dcf65c4-24c5-4069-9641-f0eb57c6b038
          type: decisionTable
        targetType: complex
    directDependentObjects:
      description: The direct dependent objects of a rule set.
      value:
        uri: /businessRules/ruleSets/b7f5c6c4-60ef-43ee-af2b-84d470279286
        name: Assign Value
        dependentUris:
          - /referenceData/domains/22b0ed51-9a5b-447f-bdc3-8ecac64c9463
          - /comments/comments/7c701ee9-ea45-469c-ab7c-f02c2f66aef9
          - /comments/comments/92c8b316-75c8-40eb-968b-84c2757f2570
          - /decisions/codeFiles/a23b84eb-251f-4103-abe6-3fd5446af90e
        version: 2
    analysisCodeGenerationRequestForRuleSet:
      description: A request to generate analysis code.
      value:
        scoreExecutionId: fc6e491b-fc28-49b7-9d6b-2f82af24ada9
        analysisType: ruleFiredDetails
        hints:
          outputLibraryName: public
          tableBaseName: output_fired_detail
          inputLibraryName: public
          inputTableName: ppn_rs1_Test_ppn_rs1_2024-07-01_06-44-38_output
    validateRule:
      description: A rule to be validated.
      value:
        name: Default_rule_1
        ruleFiredTrackingEnabled: true
        conditional: if
        conditions:
          - expression: "> 3"
            type: decisionTable
            term:
              name: int1
              dataType: integer
              direction: inOut
        actions:
          - expression: "'keygreaterthan3'"
            type: assignment
            term:
              name: str1
              dataType: string
              direction: inOut
    functionCollection:
      description: A collection of function
      value:
        name: items
        accept: application/vnd.sas.business.rule.function
        version: 2
        items:
          - id: 26674236-bc80-41de-954d-d37b1a19d98d
            categoryId: 85329ae9-52df-444f-8e18-bffb1a523da7
            creationTimeStamp: 2020-08-04T17:46:19.097Z
            modifiedTimeStamp: 2020-08-04T17:47:28.848Z
            createdBy: brmdev
            modifiedBy: brmdev
            version: 2
            name: customadd2
            code: method customAdd2(double a, double b) returns double; return a + 2*b; end;
            returnType: double
            signature:
              - type: double
                name: a
                inOut: false
                nameQuoted: false
              - type: double
                name: b
                inOut: false
                nameQuoted: false
            links:
              - method: GET
                rel: self
                href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
                uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
                type: application/vnd.sas.business.rule.function
              - method: PUT
                rel: update
                href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
                uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
                type: application/vnd.sas.business.rule.function
              - method: DELETE
                rel: delete
                href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
                uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
              - method: GET
                rel: up
                href: /businessRules/functions
                uri: /businessRules/functions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.function
              - method: GET
                rel: category
                href: /businessRules/functionCategories/85329ae9-52df-444f-8e18-bffb1a523da7
                uri: /businessRules/functionCategories/85329ae9-52df-444f-8e18-bffb1a523da7
                type: application/vnd.sas.business.rule.function.category
            hidden: false
            nameQuoted: false
          - id: 26674236-bc80-41de-954d-d37b1a19d98e
            categoryId: 85329ae9-52df-444f-8e18-bffb1a523da7
            creationTimeStamp: 2020-08-04T17:46:19.097Z
            modifiedTimeStamp: 2020-08-04T17:47:28.848Z
            createdBy: brmdev
            modifiedBy: brmdev
            version: 2
            name: customadd3
            code: method customAdd3(double a, double b) returns double; return a + 3*b; end;
            returnType: double
            signature:
              - type: double
                name: a
                inOut: false
                nameQuoted: false
              - type: double
                name: b
                inOut: false
                nameQuoted: false
            links:
              - method: GET
                rel: self
                href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98e
                uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98e
                type: application/vnd.sas.business.rule.function
              - method: PUT
                rel: update
                href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98e
                uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98e
                type: application/vnd.sas.business.rule.function
              - method: DELETE
                rel: delete
                href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98e
                uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98e
              - method: GET
                rel: up
                href: /businessRules/functions
                uri: /businessRules/functions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.function
              - method: GET
                rel: category
                href: /businessRules/functionCategories/85329ae9-52df-444f-8e18-bffb1a523da7
                uri: /businessRules/functionCategories/85329ae9-52df-444f-8e18-bffb1a523da7
                type: application/vnd.sas.business.rule.function.category
            hidden: false
            nameQuoted: true
    functionCategoryCollection:
      description: A collection of function category
      value:
        name: items
        accept: application/vnd.sas.business.rule.function.category
        version: 2
        items:
          - id: 4f4bf2a3-5eaa-4899-b238-0e3ebd21ef68
            name: statistical_functions
            creationTimeStamp: 2020-06-01T15:38:30.988Z
            modifiedTimeStamp: 2020-06-01T15:38:30.988Z
            createdBy: edmdev
            modifiedBy: edmdev
            description: Functions used to calculate various statistics.
            hidden: true
            links:
              - method: GET
                rel: self
                href: /businessRules/functionCategories/4f4bf2a3-5eaa-4899-b238-0e3ebd21ef68
                uri: /businessRules/functionCategories/4f4bf2a3-5eaa-4899-b238-0e3ebd21ef68
                type: application/vnd.sas.business.rule.function.category
          - id: 4f4bf2a3-5eaa-4899-b238-0e3ebd21ef67
            name: statistical_functions
            creationTimeStamp: 2020-06-01T15:38:30.988Z
            modifiedTimeStamp: 2020-06-01T15:38:30.988Z
            createdBy: edmdev
            modifiedBy: edmdev
            description: Functions used to calculate various statistics.
            hidden: true
            links:
              - method: GET
                rel: self
                href: /businessRules/functionCategories/4f4bf2a3-5eaa-4899-b238-0e3ebd21ef67
                uri: /businessRules/functionCategories/4f4bf2a3-5eaa-4899-b238-0e3ebd21ef67
                type: application/vnd.sas.business.rule.function.category
    summaryOfRuleSets:
      description: A collection of rule sets as resource summary representations.
      value:
        name: ruleSets
        accept: application/vnd.sas.summary
        start: 0
        count: 1
        items:
          - creationTimeStamp: 2024-06-17T08:13:45.535Z
            modifiedTimeStamp: 2024-06-17T08:14:32.142Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: c01375b7-154f-47c8-9e6c-18b27b4be692
            type: ruleSet
            name: hmeq_job
            description: test
            typeDefName: ruleSet_assignment
            links:
              - method: GET
                rel: up
                href: /businessRules/ruleSets
                uri: /businessRules/ruleSets
                type: application/vnd.sas.collection
              - method: GET
                rel: self
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                type: application/vnd.sas.business.rule.set
              - method: GET
                rel: alternate
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                type: application/vnd.sas.summary
              - method: PUT
                rel: update
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                type: application/vnd.sas.business.rule
                responseType: application/vnd.sas.business.rule
              - method: DELETE
                rel: delete
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692
              - method: GET
                rel: revisions
                href: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/revisions
                uri: /businessRules/ruleSets/c01375b7-154f-47c8-9e6c-18b27b4be692/revisions
                type: application/vnd.sas.collection
                itemType: application/vnd.sas.business.rule.set
            version: 2
        limit: 10
        version: 2
        links:
          - method: GET
            rel: collection
            href: /businessRules/ruleSets
            uri: /businessRules/ruleSets
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set
          - method: GET
            rel: self
            href: /businessRules/ruleSets?sortBy=modifiedTimeStamp:descending&start=0&limit=10
            uri: /businessRules/ruleSets?sortBy=modifiedTimeStamp:descending&start=0&limit=10
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.summary
          - method: POST
            rel: createRuleSet
            href: /businessRules/ruleSets
            uri: /businessRules/ruleSets
            type: application/vnd.sas.business.rule.set
            responseType: application/vnd.sas.business.rule.set
          - method: GET
            rel: getDefaultRuleSetThumbnail
            href: /businessRules/ruleSets/defaultRuleSetThumbnail.svg
            uri: /businessRules/ruleSets/defaultRuleSetThumbnail.svg
    mappedCodeOfRuleSet:
      description: Generated mapped code for a rule set.
      value:
        code: >
          /* Rule Set ppn_rs1 version 1.0 generated on Mon Jul 01 06:44:38 UTC 2024 */


          DS2_OPTIONS LOGICALEXPR = STANDARD;

          DS2_OPTIONS SCOND = WARNING;

          DS2_OPTIONS MISSING_NOTE;


          /* {PACKAGE_START} */

          package BRM_51_RuleSet_0  / inline;

          	dcl package logger _logger('App.demo');
          	dcl package logger logr_variableTrace('App.TableServices.DS2.Runtime.TraceVariables');
          	dcl varchar(100)  "RULE_NM";
          	dcl varchar(100)  "RULE_SET_NM";
          	dcl varchar(36)   "RULE_SET_ID";
          	dcl varchar(36)   "RULE_SET_VERSION_ID";
          	dcl varchar(36)   "RULE_ID";

          	dcl package hash   ruleFireFlagOffsetHash;
          	dcl integer        ruleFiredFlagPosition;
          	dcl integer        ruleFiredBasePosition;
          	dcl integer        ruleFiredRecordingEnableFlag;

          	method setruleFiredBasePosition(integer newBasePosition);
          		ruleFiredBasePosition = newBasePosition;
          	end;

          	method enableRuleFiredRecording();
          		ruleFiredRecordingEnableFlag = 1;
          	end;

          	method disableRuleFiredRecording();
          		ruleFiredRecordingEnableFlag = 0;
          	end;

          	method initRuleFireHashes();
          		if null(ruleFireFlagOffsetHash) then do;
          			ruleFireFlagOffsetHash = _new_ [this] hash();
          			ruleFireFlagOffsetHash.keys([RULE_ID]);
          			ruleFireFlagOffsetHash.data([RULE_ID ruleFiredFlagPosition]);
          			ruleFireFlagOffsetHash.defineDone();
          			ruleFireFlagOffsetHash.clear();
          		end;
          		ruleFiredFlagPosition = ruleFiredBasePosition;
          		RULE_ID = 'da5a5617-ebc8-4864-a18d-fd6c29acc5be';
          		ruleFireFlagOffsetHash.ref();
          		ruleFiredFlagPosition = ruleFiredFlagPosition+1;
          		RULE_ID = '8d72248c-3e73-4ff7-af18-9015ada4ab8e';
          		ruleFireFlagOffsetHash.ref();
          		ruleFiredFlagPosition = ruleFiredFlagPosition+1;
          	end;

          	/* ---- RULE FIRED FLAG COUNT = 2 ---- */
          	method getRuleFiredFlagCount() returns integer;
          		return 2 ;
          	end;

          	method recordRuleFired(
          		in_out char    ruleFiredFlags,
          		in_out integer rulesFiredForRecordCount,
          		char(36)       this_rule_id);

          		if not(RuleFiredRecordingEnableFlag) then return;
          		if (null(ruleFireFlagOffsetHash) = 0) then do;
          			RULE_ID = this_rule_id;
          			if (ruleFireFlagOffsetHash.find() = 0) then do;
          				if (ruleFiredFlagPosition > 0) then do;
          					substr(ruleFiredFlags,ruleFiredFlagPosition,1) = '1';
          					rulesFiredForRecordCount = sum(rulesFiredForRecordCount,1);
          				end;
          			end;
          		end;
          	end;

          	method DataGrid_Clear(package datagrid aGrid)
          		returns int;
          		aGrid.clear();
          		return 0;
          	end;

          	method DataGrid_toString(package datagrid aGrid)
          		returns varchar;
          		return aGrid.serialize();
          	end;

          	method DataGrid_addRow(package datagrid aGrid)
          		returns int;
          		dcl int res rowCnt;
          		rowCnt = 0;
          		res = aGrid.rowAdd();
          		if (res = 0) then
          		rowCnt = aGrid.rowCount();
          		return rowCnt;
          	end;

          	method DataGrid_addRow(package datagrid aGrid, int numberOfRows)
          		returns int;
          		dcl int res rowCnt;
          		rowCnt = 0;
          		res = aGrid.rowAdd(numberOfRows);
          		if (res = 0) then
          		rowCnt = aGrid.rowCount();
          		return rowCnt;
          	end;

          	method DataGrid_columnExists(package datagrid aGrid,
          		varchar(255) col_name)
          		returns int;
          		if (aGrid.columnExists(col_name)) then do;
          			return aGrid.columnIndex(col_name);
          		end;
          		return 0;
          	end;

          	method DataGrid_addCharacterColumn(package datagrid aGrid,
          		varchar(255) col_name)
          		returns int;
          		return aGrid.columnAddCharType(col_name);
          	end;

          	method DataGrid_Set(package datagrid aGrid,
          		varchar(255) col_name,
          		int          row_index,
          		varchar(32767) value)
          		returns int;
          		return aGrid.setValue(col_name, row_index, value);
          	end;

          	method initRdsp();
          	end;

          	method execute( in_out varchar "r_char",double "r_int",double "r_number",in_out package datagrid "r_dg_out",in_out char "ruleFiredFlags",in_out integer "rulesFiredForRecordCount");
          		dcl double "dg_index";

          		;
          		if ("r_char" = 'Foundation') then do;
          			recordRuleFired(ruleFiredFlags,rulesFiredForRecordCount,'da5a5617-ebc8-4864-a18d-fd6c29acc5be');
          			if (DataGrid_columnExists("r_dg_out",'r1_char_col') = 0) then do;
          				DataGrid_addCharacterColumn("r_dg_out",'r1_found_col');
          			end;
          			dg_index=DataGrid_AddRow(r_dg_out);
          			DataGrid_Set("r_dg_out",'r1_found_col', dg_index,'1 found');
          			goto "end_da5a5617-ebc8-4864-a18d-fd6c29acc5be";
          		end;
          		else do;
          			recordRuleFired(ruleFiredFlags,rulesFiredForRecordCount,'8d72248c-3e73-4ff7-af18-9015ada4ab8e');
          			if (DataGrid_columnExists("r_dg_out",'r1_char_col') = 0) then do;
          				DataGrid_addCharacterColumn("r_dg_out",'r1_found_col');
          			end;
          			dg_index=DataGrid_AddRow(r_dg_out);
          			DataGrid_Set("r_dg_out",'r1_found_col', dg_index,'1 NOT found');
          		end;

          		"end_da5a5617-ebc8-4864-a18d-fd6c29acc5be":

          		rule_end:  /* label for rule RETURN action */
          	end;

          	method term();
          		if (null(ruleFireFlagOffsetHash) = 0) then ruleFireFlagOffsetHash.clear();
          	end;

          	/* {PACKAGE_END} */
          endpackage;


          DS2_OPTIONS LOGICALEXPR = STANDARD;

          DS2_OPTIONS SCOND = WARNING;

          DS2_OPTIONS MISSING_NOTE;


          thread brm_rules_execution_thread  / inline;
          	dcl package BRM_51_ruleset_0 ruleset();
          	dcl integer      "rulesfiredforrecordcount" having label 'Rules Fired Count';
          	dcl char(36)     "_recordCorrelationKey";

          	dcl char(2) "ruleFiredFlags";

          	dcl package datagrid "r_dg_out_grid" ('r_dg_out_grid');
          	dcl varchar(10485760) "r_dg_out";

          	dcl double "r_int";
          	dcl double "r_number";

          	retain "rulesfiredforrecordcount" 0;

          	keep  "rulesfiredforrecordcount" "_recordCorrelationKey" "ruleFiredFlags" "r_dg_out";
          	method resetruleFiredCounts( in_out char "ruleFiredFlags", in_out integer "rulesfiredforrecordcount");
          		ruleFiredFlags = '';

          		"rulesfiredforrecordcount"=0;
          	end;

          	method init();

          		ruleset.enablerulefiredrecording();
          		ruleset.setRuleFiredBasePosition(1);
          		ruleset.initrulefirehashes();
          		resetruleFiredCounts( "ruleFiredFlags", "rulesfiredforrecordcount");

          	end;

          	/* output execution thread code*/
          	method run();
          		dcl int localRC;
          		set "Public"."HMEQ_10" (
          		keep=("LOAN" "REASON" "VALUE" )
          		rename=( "LOAN"="r_number"
          		"VALUE"="r_int"
          		"REASON"="r_char"
          		)      );

          		resetruleFiredCounts("ruleFiredFlags", "rulesfiredforrecordcount");

          		localRC = ruleset.DataGrid_clear("r_dg_out_grid");

          		ruleset.execute(
          		"r_char"
          		, "r_int"
          		, "r_number"
          		, "r_dg_out_grid"
          		, "ruleFiredFlags"

          		, "rulesFiredForRecordCount");
          		"_recordCorrelationKey" = uuidgen();

          		"r_dg_out" = ruleset.DataGrid_toString("r_dg_out_grid");

          		output;
          	end;
          endthread;


          DS2_OPTIONS MSGORDER = STANDARD;

          DS2_OPTIONS LOGICALEXPR = STANDARD;

          DS2_OPTIONS SCOND = WARNING;

          DS2_OPTIONS MISSING_NOTE;


          data "Public"."ppn_rs1_Test_ppn_rs1_2024-07-01_06-44-38_output" (overwrite=yes);

          	dcl thread brm_rules_execution_thread _t;
          	method run();
          		set from _t threads=4;
          		output;
          	end;
          enddata;
        codeType: text/vnd.sas.source.ds2
        outputTableName: ppn_rs1_Test_ppn_rs1_2024-07-01_06-44-38_output
        outputLibraryName: Public
        version: 1
    preConditionRequired:
      description: Pre-condition required.
      value:
        httpStatusCode: 428
        version: 2
    actionConversion:
      description: The request body to convert the action.
      value:
        source:
          term:
            creationTimeStamp: 2024-07-02T15:10:10.261Z
            modifiedTimeStamp: 2024-07-02T15:10:10.261Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 1585a3a4+f659+4d37+7e39+b167fea07777
            name: JMgr
            dataType: string
            direction: none
            description: ""
          expression: JSef
          status: valid
          id: d86fd11d-c9e9-41be-8d1f-b04beb4b519e
          type: assignment
          lastStatus: valid
          statusMessage: ""
        targetType: complex
    function:
      description: Content of a function
      value:
        id: 26674236-bc80-41de-954d-d37b1a19d98d
        categoryId: 85329ae9-52df-444f-8e18-bffb1a523da7
        creationTimeStamp: 2020-08-04T17:46:19.097Z
        modifiedTimeStamp: 2020-08-04T17:47:28.848Z
        createdBy: brmdev
        modifiedBy: brmdev
        version: 2
        name: customadd2
        code: method customAdd2(double a, double b) returns double; return a + b; end;
        returnType: double
        signature:
          - type: double
            name: a
            inOut: false
            nameQuoted: false
          - type: double
            name: b
            inOut: false
            nameQuoted: false
        links:
          - method: GET
            rel: self
            href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            type: application/vnd.sas.business.rule.function
          - method: PUT
            rel: update
            href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            type: application/vnd.sas.business.rule.function
          - method: DELETE
            rel: delete
            href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
          - method: GET
            rel: up
            href: /businessRules/functions
            uri: /businessRules/functions
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.function
          - method: GET
            rel: category
            href: /businessRules/functionCategories/85329ae9-52df-444f-8e18-bffb1a523da7
            uri: /businessRules/functionCategories/85329ae9-52df-444f-8e18-bffb1a523da7
            type: application/vnd.sas.business.rule.function.category
        hidden: false
        nameQuoted: false
    preConditionFailed:
      description: Pre-condition failed.
      value:
        httpStatusCode: 412
        version: 2
    scoreCodeGenerationRequestForRuleSet:
      description: A request to generate score code.
      value:
        scoreDefinitionId: 9f0c13ae-6a27-11e6-8b77-86f30ca893d3
        hints:
          outputLibraryName: public
          tableBaseName: test_outputTable_
          isGeneratingRuleFiredColumn: "true"
          variableCarried: "true"
          traversedPathFlag: "true"
          lookupMode: INLINE
          codeTarget: PROCDS2
          inputLibraryName: public
          inputTableName: output
          filterToBeRecordedFlag: "true"
    collectionOfLegacyVariables:
      description: A collection of legacy variables in a rule set.
      value:
        links:
          - method: GET
            rel: collection
            href: /businessRules/ruleSets
            uri: /businessRules/ruleSets
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set.variable
          - method: GET
            rel: self
            href: /businessRules/ruleSets?filter=and%20(eq(legacy,'true'),eq(ruleSet.ruleSetId,'a4b28f84-98ae-45f5-8a48-938cb672a63e'))&sortBy=createdTimeStamp:ascending&start=0&limit=10
            uri: /businessRules/ruleSets?filter=and%20(eq(legacy,'true'),eq(ruleSet.ruleSetId,'a4b28f84-98ae-45f5-8a48-938cb672a63e'))&sortBy=createdTimeStamp:ascending&start=0&limit=10
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set.variable
        name: ruleLegacyVariables
        start: 0
        count: 2
        items:
          - creationTimeStamp: 2024-07-04T07:43:52.955Z
            modifiedTimeStamp: 2024-07-04T07:43:52.955Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 61e3654e-76d7-429e-82f3-80430629747d
            name: var1
            dataType: string
            description: ""
            generateDataGridColumns: false
            direction: inOut
            legacy: true
          - creationTimeStamp: 2024-07-04T07:43:52.963Z
            modifiedTimeStamp: 2024-07-04T07:43:52.963Z
            createdBy: sasdemo
            modifiedBy: sasdemo
            id: 992efb6c-0044-4313-b58a-183bee53bf8a
            name: var2
            dataType: string
            description: ""
            generateDataGridColumns: false
            direction: inOut
            legacy: true
        limit: 10
        version: 2
    ds2CodeOfRuleSet:
      description: Code generated from a rule set.
      value: >
        /* Rule Set ppn_rs1 version 1.0 generated on Mon Jul 01 06:20:20 UTC 2024 */


        DS2_OPTIONS LOGICALEXPR = STANDARD;

        DS2_OPTIONS SCOND = WARNING;

        DS2_OPTIONS MISSING_NOTE;


        /* {PACKAGE_START} */
          package BRM_51_RuleSet_0  / inline;

              dcl package logger _logger('App.demo');
              dcl package logger logr_variableTrace('App.TableServices.DS2.Runtime.TraceVariables');

                /* ---- RULE FIRED FLAG COUNT = 0 ---- */

        method DataGrid_addRow(package datagrid aGrid)

        returns int;
            dcl int res rowCnt;
            rowCnt = 0;
            res = aGrid.rowAdd();
            if (res = 0) then
            rowCnt = aGrid.rowCount();
            return rowCnt;
        end;


        method DataGrid_addRow(package datagrid aGrid, int numberOfRows)

        returns int;
            dcl int res rowCnt;
            rowCnt = 0;
            res = aGrid.rowAdd(numberOfRows);
            if (res = 0) then
            rowCnt = aGrid.rowCount();
            return rowCnt;
        end;


        method DataGrid_columnExists(package datagrid aGrid,

        varchar(255) col_name)

        returns int;
            if (aGrid.columnExists(col_name)) then do;
                return aGrid.columnIndex(col_name);
            end;
            return 0;
        end;


        method DataGrid_addCharacterColumn(package datagrid aGrid,

        varchar(255) col_name)

        returns int;
            return aGrid.columnAddCharType(col_name);
        end;


        method DataGrid_Set(package datagrid aGrid,

        varchar(255) col_name,

        int          row_index,

        varchar(32767) value)

        returns int;
            return aGrid.setValue(col_name, row_index, value);
        end;

                method initRdsp();
            end;

            method execute( in_out varchar "r_char",double "r_int",double "r_number",in_out package datagrid "r_dg_out");
                dcl double "dg_index";

        ;
                 if ("r_char" = 'Foundation') then do;
                 if (DataGrid_columnExists("r_dg_out",'r1_char_col') = 0) then do;
                                     DataGrid_addCharacterColumn("r_dg_out",'r1_found_col');
                                     end;
                         dg_index=DataGrid_AddRow(r_dg_out);
                         DataGrid_Set("r_dg_out",'r1_found_col', dg_index,'1 found');
        goto "end_da5a5617-ebc8-4864-a18d-fd6c29acc5be";end;
                 else do;
                 if (DataGrid_columnExists("r_dg_out",'r1_char_col') = 0) then do;
                                     DataGrid_addCharacterColumn("r_dg_out",'r1_found_col');
                                     end;
                         dg_index=DataGrid_AddRow(r_dg_out);
                         DataGrid_Set("r_dg_out",'r1_found_col', dg_index,'1 NOT found');
                 end;

                 "end_da5a5617-ebc8-4864-a18d-fd6c29acc5be":

              rule_end:  /* label for rule RETURN action */
            end;

        /* {PACKAGE_END} */
          endpackage;
    notFound:
      description: Not found.
      value:
        httpStatusCode: 404
        version: 2
    referencedResouces:
      description: A collection of referenced resources.
      value:
        links:
          - method: GET
            rel: collection
            href: /businessRules/ruleSets/e335590e-ded8-47da-950c-6dafbdbf9c57/revisions/0bde8adb-5baa-4142-a950-ba4ee780873a/lookups
            uri: /businessRules/ruleSets/e335590e-ded8-47da-950c-6dafbdbf9c57/revisions/0bde8adb-5baa-4142-a950-ba4ee780873a/lookups
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.lookup
        name: referencedResources
        count: 1
        items:
          - id: 6ba098d7-37b9-4ba9-a8c8-5211a55ded82
            existence: found
            version: 2
            name: $LNOQJRVZXXFF2TKGIKII2KXPNQI_K
            realName: hmeq_container_job
            packageName: lnoqjrvzxxff2tkgikii2kxpnqi
            checkout: false
            values: []
        version: 2
    notAcceptable:
      description: Not acceptable.
      value:
        httpStatusCode: 406
        version: 2
    decisionStepCodeOfRuleSet:
      description: Decision step code for a decision flow.
      value:
        creationTimeStamp: 2024-07-01T05:28:53.812Z
        modifiedTimeStamp: 2024-07-01T05:28:54.206Z
        createdBy: sasdemo
        modifiedBy: sasdemo
        id: 1525f975-eb00-4602-bf73-f9d1f020a178
        type: ruleSet
        name: ppn_rs1
        properties:
          versionName: "1.0"
        signature:
          - name: r_number
            dataType: integer
            direction: input
            generateDataGridColumns: false
          - name: r_char
            dataType: string
            direction: input
            generateDataGridColumns: false
          - name: dg_index
            dataType: integer
            direction: none
            generateDataGridColumns: false
          - name: r_int
            dataType: integer
            direction: input
            generateDataGridColumns: false
          - name: r_dg_out
            dataType: dataGrid
            direction: output
            length: 10485760
            generateDataGridColumns: false
        links:
          - method: GET
            rel: self
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            type: application/vnd.sas.business.rule.set
          - method: GET
            rel: alternate
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            type: application/vnd.sas.summary
          - method: GET
            rel: withRules
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            type: application/vnd.sas.business.rule.set.integral
          - method: PUT
            rel: update
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            type: application/vnd.sas.business.rule.set
            responseType: application/vnd.sas.business.rule.set
          - method: DELETE
            rel: delete
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178
          - method: GET
            rel: rules
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/rules
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/rules
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule
          - method: GET
            rel: rulesOrder
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/order
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/order
            type: application/vnd.sas.selection
          - method: GET
            rel: revisions
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set
          - method: POST
            rel: createMinorRevision
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions?revisionType=minor
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions?revisionType=minor
            type: application/vnd.sas.business.rule.set
            responseType: application/vnd.sas.business.rule.set
          - method: POST
            rel: createMajorRevision
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions?revisionType=major
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/revisions?revisionType=major
            type: application/vnd.sas.business.rule.set
            responseType: application/vnd.sas.business.rule.set
          - method: GET
            rel: up
            href: /businessRules/ruleSets
            uri: /businessRules/ruleSets
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set
          - method: GET
            rel: code
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/code
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/code
            type: text/vnd.sas.source.ds2
          - method: POST
            rel: mappedCode
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/mappedCode
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/mappedCode
            type: application/vnd.sas.score.code.generation.request
            responseType: application/vnd.sas.score.mapped.code
          - method: POST
            rel: analysisCode
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/analysisCode
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/analysisCode
            type: application/vnd.sas.score.analysis.code.generation.request
            responseType: application/vnd.sas.score.analysis.code
          - method: GET
            rel: metadataDocuments
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/metadataDocuments
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/metadataDocuments
            type: application/zip
          - method: GET
            rel: legacyVariables
            href: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/legacyVariables
            uri: /businessRules/ruleSets/1525f975-eb00-4602-bf73-f9d1f020a178/legacyVariables
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.set.variable+json
        version: 1
  requestBodies:
    analysisCodeGenerationRequest:
      content:
        application/vnd.sas.score.analysis.code.generation.request+json:
          schema:
            $ref: "#/components/schemas/analysisCodeGenerationRequest"
          examples:
            default:
              $ref: "#/components/examples/analysisCodeGenerationRequestForRuleSet"
        application/json:
          schema:
            $ref: "#/components/schemas/analysisCodeGenerationRequest"
          examples:
            default:
              $ref: "#/components/examples/analysisCodeGenerationRequestForRuleSet"
      description: Information that describes the specific execution to which the analysis code should be applicable (as specified by the scoreExecutionId) and the type of analysis that is to be performed by the code.
      required: true
    scoreCodeGenerationRequest:
      content:
        application/vnd.sas.score.code.generation.request+json:
          schema:
            $ref: "#/components/schemas/scoreCodeGenerationRequest"
          examples:
            default:
              $ref: "#/components/examples/scoreCodeGenerationRequestForRuleSet"
        application/json:
          schema:
            $ref: "#/components/schemas/scoreCodeGenerationRequest"
          examples:
            default:
              $ref: "#/components/examples/scoreCodeGenerationRequestForRuleSet"
      description: The information for the scoreDefinitionId and hints.
      required: true
    unboundScoreCodeGenerationRequest:
      content:
        application/vnd.sas.score.code.generation.request.unbound+json:
          schema:
            $ref: "#/components/schemas/unboundScoreCodeGenerationRequest"
          examples:
            default:
              $ref: "#/components/examples/scoreCodeGenerationRequestUnboundForRuleSet"
      description: The information for the mapping and hints to be used during building the execution code.
      required: true
  schemas:
    scoreCodeGenerationRequest:
      title: Request for Generating Score Code
      description: A request that contains hints to generate the mapped code using the scoring definition by score object.
      required:
        - scoreDefinitionId
      properties:
        scoreDefinitionId:
          type: string
          description: The score definition ID that is used for generating the mapped code. This should be used only if the `scoreDefinition` is not used.
        hints:
          type: object
          description: Hints for generating the mapped code. The mapped code request is forwarded to the score object of the score definition. The score object should be able to understand these hints.
          additionalProperties:
            type: string
        version:
          type: integer
          description: This media type's schema version number. This representation is version 1.
      example:
        scoreDefinitionId: 9f0c13ae-6a27-11e6-8b77-86f30ca893d3
        hints:
          outputLibraryName: PUBLIC
    analysisCodeGenerationRequest:
      title: Request for Generating Analysis Code
      description: A request that contains hints to generate the analysis code using the scoring execution.
      required:
        - analysisType
        - scoreExecutionId
      properties:
        scoreExecutionId:
          type: string
          description: The score execution ID.
        analysisType:
          type: string
          format: enumeration
          enum:
            - ruleFiredDetails
            - ruleFiredSummary
          description: The type of analysis that needs to be done.
        hints:
          type: object
          description: Hints for generating the analysis code.
          additionalProperties:
            type: string
        version:
          type: integer
          description: This media type's schema version number. This representation is version 1.
      example:
        scoreExecutionId: 6f4bced9-5bbd-476c-8ef8-3378678b0702
        analysisType: ruleFiredSummary
        hints:
          outputLibraryName: PUBLIC
    ruleSetCollection:
      title: Rule Set Collection
      description: One page of rule set representations, with optional links to first, prev, next, and last page of the collection.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/ruleSet"
    ruleCollection:
      title: Rule Collection
      description: One page of rule representations with optional links to first, prev, next, and last page of the collection.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/businessRule"
              description: An array that consists of one page of rule resources.
    ruleVariableCollection:
      title: Rule Variable Collection
      description: One page of rule representations with optional links to first, prev, next, and last page of the collection.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/signatureTerm"
              description: An array that consists of one page of rule variable resources.
    errorCollection:
      title: Error Collection
      description: A collection of errors and warnings from the rule validation. No paging is required for this end point.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/error2"
              description: An array that consists of errors from the validation of a rule. The array contains warnings with error code 13741 and errors with error code 13740.
    ruleQueryCollection:
      title: Error Collection
      description: A collection of rules using the query response format.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/businessRuleQuery"
    ruleActionConversion:
      title: Rule Action Conversion
      description: A request to convert a rule action to a different type.
      required:
        - source
        - targetType
      properties:
        links:
          type: array
          description: Zero or more links to related resources or operations.
          items:
            $ref: "#/components/schemas/link"
        source:
          $ref: "#/components/schemas/ruleAction"
        targetType:
          description: The type to convert the action to.
          type: string
          format: enumeration
          enum:
            - assignment
            - return
            - complex
            - lookupValue
        convertedAction:
          $ref: "#/components/schemas/ruleAction"
        version:
          type: integer
          description: This media type's schema version number. This representation is version 1.
    ruleConditionConversion:
      title: Rule Condition Conversion
      description: A request to convert a rule condition to a different type.
      required:
        - source
        - targetType
      properties:
        links:
          type: array
          description: Zero or more links to related resources or operations.
          items:
            $ref: "#/components/schemas/link"
        source:
          $ref: "#/components/schemas/ruleCondition"
        targetType:
          description: The type to convert the condition to.
          type: string
          format: enumeration
          enum:
            - decisionTable
            - lookup
            - complex
        convertedCondition:
          $ref: "#/components/schemas/ruleCondition"
        version:
          type: integer
          description: This media type's schema version number. This representation is version 1.
    functionCategoryCollection:
      title: Function Category Collection
      description: >
        One page of function category representations with optional links to the first, previous, next, and last pages of the collection.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/functionCategory"
              description: >
                An array that consists of one page of function category representations.
    functionCollection:
      title: Function Collection
      description: >
        One page of function representations with optional links to the first, previous, next, and last pages of the collection.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/function"
    lookupCollection:
      title: Lookup Collection
      description: A collection of lookup representations.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/lookup"
    referencedResourceCollection:
      title: Referenced Resources Collection
      description: A collection of referenced resource representations.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                anyOf:
                  - $ref: "#/components/schemas/advancedList"
                  - $ref: "#/components/schemas/lookup"
    termSummaryCollection:
      title: Term Usage Summary Collection
      description: An un-paginated list of term usage summaries.
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/termUsageSummary"
              description: An array that consists of term usage summaries.
    directDependentObjects:
      title: Direct Dependent Objects
      description: The object contains an unpaginated list of URIs of the direct dependents of this rule set.
      required:
        - uri
        - name
        - dependentUris
      properties:
        uri:
          type: string
          description: The URI of a decision.
        name:
          type: string
          description: The name of the decision.
        dependencies:
          type: array
          description: A list of URIs for each direct dependency of this rule set.
          items:
            type: string
    resourceSummaryCollection:
      title: Resource Summary Collection
      description: One page of the objects as resource summary representations, with optional links to the first, previous, next, and last page of the list.
      type: object
      allOf:
        - $ref: "#/components/schemas/baseCollection2"
        - type: object
          required:
            - items
          properties:
            items:
              type: array
              items:
                $ref: "#/components/schemas/summary"
              description: An array, which consists of one page of the objects as summary resources.
    baseCollection2:
      title: Base Collection
      description: This is a base schema used to define paginated collections of resources. This base schema is extended by other schemas in APIs by adding an 'items' array property. These extensions define the application/vnd.sas.collection media type (version 2)
      properties:
        name:
          type: string
          description: The name of the collection.
        start:
          type: integer
          description: The zero-based index of the first item in the collection.
          format: int64
        limit:
          type: integer
          description: The number of items that were requested for the collection.
        count:
          type: integer
          description: If populated indicates the number of items in the collection.
          format: int64
        accept:
          type: string
          description: A space-delimited list of media types from which an `Accept` header may be constructed.
        links:
          type: array
          description: The links that apply to the collection.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: The version number of the collection representation. This representation is version 2.
    signatureTerm:
      title: Signature Term
      description: >
        Business term defined by the user to be used as a variable for usage in expressions and mappings within rule sets or decisions. Terms of type data grid can have their internal structure defined further using extensions, these are fields that are found within each row of a data grid term.
      required:
        - name
        - dataType
        - direction
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object
        name:
          type: string
          description: >
            Name of the term that can be referenced. Term names must be unique within a rule set.
        description:
          type: string
          description: The description of the term.
        defaultValue:
          type: object
          description: The initial value of the term.
        length:
          type: integer
          description: The suggested length for use when generating code.
        createdBy:
          type: string
          description: The user who created the term.
        creationTimeStamp:
          type: string
          format: date-time
          description: The date and time that the term was created.
        modifiedBy:
          type: string
          description: The user ID of the authenticated user who last updated the term.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The date and time that the term was last modified.
        dataType:
          type: string
          description: >
            The type of data that the term is intended to be used with. Terms can be loosely typed with the 'any' type, this type is only assigned by the service when rules are created with 'createVariables=true' and no type can be determined.
          format: enumeration
          enum:
            - string
            - decimal
            - integer
            - date
            - datetime
            - dataGrid
            - boolean
            - any
        direction:
          type: string
          description: >
            Declaration of how the data is to be used during execution. It indicates if the data should be used as input, output, both input and output, or none if the term is only for internal rule set usage.
          format: enumeration
          enum:
            - input
            - output
            - inOut
            - none
        dataGridExtension:
          type: array
          description: >
            Fields that are found within the defined data grid type term. These fields are unique only within the data grid and can overlap with other term names. This member is only applicable for terms of type 'dataGrid'.
          items:
            $ref: "#/components/schemas/signatureTermExtension"
        globalVariableId:
          type: string
          description: The id of the global variable that this term references.
        generateDataGridColumns:
          type: boolean
          description: >
            Each row in a data grid variable usually contains metadata that defines the columns in the data grid and the data for each column. Depending on the data types and number of columns in the data grid, the metadata can increase the size of the data grid considerably. To exclude the metadata from each row in the data grid, set this option to "true" because the application depends on the column definitions that you enter when you define the variable. Ensure that the column definition is correct for each column in the data grid variable. If the column definitions do not match the input data, the application cannot load the data.
        legacy:
          type: boolean
          description: the flag of legacy variable.
    analysisCode:
      title: Analysis Code
      description: Analysis Code generated by a Score Object using Score Execution. This represents application/vnd.sas.score.analysis.code media type (version 1).
      x-sas-media-type:
        name: application/vnd.sas.score.analysis.code
        version: 1
      required:
        - code
        - codeType
        - outputTableName
        - outputLibraryName
        - analysisType
      properties:
        code:
          type: string
          description: Executable code generated by a Score Object.
        codeType:
          type: string
          format: media-type
          description: Type of the code.
        outputTableName:
          type: string
          description: Name of the table that will be generated when the generated code is executed.
        outputLibraryName:
          type: string
          description: Name of the library where the table will be generated when the code is executed.
        analysisType:
          type: string
          description: Type of analysis which the code will perform.
        version:
          type: integer
          description: This media type's schema version number. This representation is version 1.
      example:
        code: /* ds2 code of an object which generates XYZ output table */
        codeType: text/vnd.sas.source.ds2
        outputTableName: XYZ
        outputLibraryName: HPS
        analysisType: ruleFiredSummary
    businessRule:
      title: Rule
      description: The definition of a set of conditions and actions for use within a rule set. The defintion can also contain a rule that references a common rule, reference IDs and mappings. This represents application/vnd.sas.business.rule media type (version 4).
      required:
        - name
        - conditional
        - ruleFiredTrackingEnabled
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object
        name:
          type: string
          description: The name of the rule. Rule names must be unique within a rule set.
        description:
          type: string
          description: The rule description
        createdBy:
          type: string
          description: The user who created the rule.
        creationTimeStamp:
          type: string
          format: date-time
          description: The date and time that the rule was created.
        modifiedBy:
          type: string
          description: The userId of the authenticated user who last updated the rule.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The date and time that the rule was last modified.
        conditional:
          type: string
          description: Determines how the rule is related to this preceding rule. By default all rules are considered 'if' based which means that there logic is executed regardless of the how other rules within the rule set evaluate. However if a user chooses to use 'elseif' or 'or' the rule is only evaluated if the previous rule evaluates to 'false'. In the case of 'or' all actions are determined by the previous if/elseif in the set with actions.  If a rule is a reference to a common rule, its conditional is set to 'ref'.
          format: enumeration
          enum:
            - if
            - elseif
            - or
            - ref
        ruleFiredTrackingEnabled:
          type: boolean
          description: Set to true if you want during executions of this rule for rule fired tracking information to be recorded. False if this rule should not have tracking turned on.
        status:
          type: string
          description: The validation status of the rule. This is set to valid if no conditions or actions have validation errors. Its set to false if there are any validation errors across all its conditions and actions.
          format: enumeration
          enum:
            - valid
            - error
        conditions:
          type: array
          items:
            $ref: "#/components/schemas/ruleCondition"
          description: The list of conditions which all need to be met to execute the rules actions.
        actions:
          type: array
          items:
            $ref: "#/components/schemas/ruleAction"
          description: The list of actions which should be executed if the rule's conditions are all satisfied. This is not applicable for 'filtering' type rule sets as all actions are considered to be removing the current row from the output if it does not match the provided conditions.
        commonRuleSetId:
          type: string
          description: The unique id of the common ruleset that this rules references
        commonRuleSetVersionId:
          type: string
          description: The unique id of the revision of the common ruleset tat this rule references
        ruleMappings:
          type: array
          description: The list of mappings to be used when code is generated to subsitute terms from the rule set to terms from a referenced rule set.
          items:
            $ref: "#/components/schemas/refRuleMapping"
        links:
          type: array
          description: Zero or more links to related resources or operations.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: This media type's schema version number. This representation is version 3.
      example:
        name: Age Requirements
        conditional: if
        ruleFiredTrackingEnabled: true
    function:
      title: Function
      description: A reusable DS2 method with additional metadata.
      required:
        - categoryId
        - code
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object.
        name:
          type: string
          description: >
            A unique name for the function. The name is determined by parsing the method name defined in the function's code.

            Note that if the method identifier is quoted, this name will *NOT* include those quotes, but it will match the casing of the name in the code. If the method identifier is unquoted in the code, its name will be folded to lowercase.
        nameQuoted:
          type: boolean
          description: >
            A boolean indicating if the function's name is quoted in its code.
        hidden:
          type: boolean
          description: >
            A boolean indicating if the function is hidden or not.
        categoryId:
          type: string
          description: >
            The ID of the function's parent category. This can be changed during an update to the function in order to move the function into a different category.
        description:
          type: string
          description: A description of the function.
        code:
          type: string
          description: >
            The DS2 function implementation, starting with the `method my_func();` statement.
        returnType:
          type: string
          description: >
            The type returned from the function is specified after the `returns` keyword in the header of the declaration. This property is omitted if the function does not specify a return type.
        signature:
          type: array
          description: >
            An ordered array of the input parameters to the function determined by parsing the function's code.
          items:
            $ref: "#/components/schemas/functionSignatureTerm"
        createdBy:
          type: string
          description: The user who created the function.
        creationTimeStamp:
          type: string
          format: date-time
          description: The data and time at which the function was created.
        modifiedBy:
          type: string
          description: The user who made the last modification to the function.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The date and time at which the function was last modified.
        testCustomContextUri:
          type: string
          description: The URI of a Custom Context DS2 code file that provides a custom context to this function. Normally, this function's custom context is provided by the decision that utimately utilizes it. For syntax validation purpose, you can specify a testing-only custom context.
        links:
          type: array
          description: Zero or more links to related resources or operations.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: >
            This media type's schema version number. This representation is version 1.
      example:
        creationTimeStamp: 2020-08-04T17:46:19.097Z
        modifiedTimeStamp: 2020-08-04T17:47:28.848Z
        createdBy: brmdev
        modifiedBy: brmdev
        version: 1
        id: 26674236-bc80-41de-954d-d37b1a19d98d
        categoryId: 85329ae9-52df-444f-8e18-bffb1a523da7
        name: customadd2
        code: method customAdd2(double a, double b) returns double; return a + b; end;
        returnType: double
        signature:
          - type: double
            name: a
            inOut: false
            nameQuoted: false
          - type: double
            name: b
            inOut: false
            nameQuoted: false
        links:
          - method: GET
            rel: self
            href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            type: application/vnd.sas.business.rule.function
          - method: PUT
            rel: update
            href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            type: application/vnd.sas.business.rule.function
          - method: DELETE
            rel: delete
            href: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
            uri: /businessRules/functions/26674236-bc80-41de-954d-d37b1a19d98d
          - method: GET
            rel: up
            href: /businessRules/functions
            uri: /businessRules/functions
            type: application/vnd.sas.collection
            itemType: application/vnd.sas.business.rule.function
          - method: GET
            rel: category
            href: /businessRules/functionCategories/85329ae9-52df-444f-8e18-bffb1a523da7
            uri: /businessRules/functionCategories/85329ae9-52df-444f-8e18-bffb1a523da7
            type: application/vnd.sas.business.rule.function.category
        hidden: false
        nameQuoted: false
    summary:
      title: Resource Summary
      type: object
      description: The summarized representation of a resource. Often used in collection responses when more specific details aren't needed.
      x-sas-media-type:
        name: application/vnd.sas.summary
        version: 2
      required:
        - id
        - links
        - version
      properties:
        id:
          type: string
          description: The unique identifier for the resource.
        name:
          type: string
          description: The name of the resource.
        type:
          type: string
          description: The type of the resource.
        description:
          type: string
          description: The description of the resource.
        typeDefName:
          type: string
          description: (version 2) The name of the type definition that describes the contents of this resource.
        iconUri:
          type: string
          description: (version 2) The URI of an icon assigned to this resource, overrides default icons for the type.
        createdBy:
          type: string
          description: The user who created the resource.
        creationTimeStamp:
          type: string
          format: date-time
          description: The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was created.
        modifiedBy:
          type: string
          description: The user who most recently modified the resource.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was last modified.
        links:
          type: array
          description: The links that apply to the resource.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: The version number of the resource. This representation is version 2.
    mappedCode:
      title: Mapped Code
      description: Executable code generated by a score object using a score definition and input data. This represents application/vnd.sas.score.mapped.code media type (version 1).
      required:
        - code
        - codeType
        - outputTableName
        - outputLibraryName
      properties:
        code:
          type: string
          description: The executable code generated by a score object.
        codeType:
          type: string
          format: media-type
          description: The type of code.
        outputTableName:
          type: string
          description: The name of the table that is generated when the code is executed.
        outputLibraryName:
          type: string
          description: The name of the library where the table is generated when the code is executed.
        version:
          type: integer
          readOnly: true
          description: This media type's schema version number. This representation is version 2.
    api:
      title: API
      description: The list of links to top-level resources and operations available from the root of the API.
      x-sas-media-type:
        name: application/vnd.sas.api
        version: 1
      required:
        - version
        - links
      properties:
        version:
          type: integer
          description: The version number of the API representation. This is version 1.
          minimum: 1
        links:
          description: The API's top-level links.
          type: array
          items:
            $ref: "#/components/schemas/link"
    newFunction:
      title: New Function
      description: A new reusable DS2 method with additional metadata.
      required:
        - code
      properties:
        description:
          type: string
          description: A description of the function.
        signature:
          type: array
          description: >
            An ordered array of the input parameters to the function determined by parsing the function's code.
          items:
            $ref: "#/components/schemas/functionSignatureTerm"
        code:
          type: string
          description: >
            The DS2 function implementation, starting with the `method my_func();` statement.
        testCustomContextUri:
          type: string
          description: The URI of a Custom Context DS2 code file that provides a custom context to this function. Normally, this function's custom context is provided by the decision that utimately utilizes it. For syntax validation purpose, you can specify a testing-only custom context.
      example:
        code: >-
          method custom_add(integer bar, double baz, in_out double foo);
            foo = bar + baz;
          end;
        description: Sums two numbers.
    advancedList:
      title: Advanced List in Business Rules
      description: An advanced list that is referenced by a business rule.
      x-sas-media-type:
        name: application/vnd.sas.business.rule.list.advanced
        version: 1
      required:
        - id
        - name
      properties:
        id:
          type: string
          description: The unique ID for this object that is assigned by the system.
        name:
          type: string
          description: A unique name for the list.
        existence:
          type: string
          description: An indicator for whether the list exists. When a list's existence is found, a "listResource" member is carried.
          format: enumeration
          enum:
            - notqueried
            - queried
            - notfound
            - found
        listResource:
          type: object
          description: An object that specifies the key and value columns of the list.
          additionalProperties:
            $ref: "#/components/schemas/dataList"
        version:
          type: integer
          description: The schema version number. This representation is version 1.
      example:
        id: df74cc8d-812e-4b68-8801-6c9e8a771e26
        name: accountInformation
        existence: found
        listResource:
          creationTimeStamp: 2023-02-09T20:44:38.974Z
          modifiedTimeStamp: 2023-02-09T22:27:58.712Z
          createdBy: sasdemo
          modifiedBy: sasdemo
          id: df74cc8d-812e-4b68-8801-6c9e8a771e26
          name: account balance
          description: ""
          state: inactive
          label: ""
          columns:
            - name: balance
              dataType: number
              position: 1
              isKey: false
              keyPosition: 0
            - name: currency
              dataType: string
              position: 2
              isKey: false
              keyPosition: 0
            - name: accountType
              dataType: string
              position: 3
              isKey: true
              keyPosition: 1
            - name: customerId
              dataType: string
              position: 4
              isKey: true
              keyPosition: 2
          version: 1
        version: 1
    revisionSummary:
      title: Revision Resource Summary
      description: The summarized representation of a decisioning revision resource.
      properties:
        id:
          type: string
          description: The unique identifier for the resource.
        name:
          type: string
          description: The name of the resource.
        description:
          type: string
          description: The description of the resource.
        createdBy:
          type: string
          description: The user who created the resource.
        creationTimeStamp:
          type: string
          format: date-time
          description: The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was created.
        modifiedBy:
          type: string
          description: The user who most recently modified the resource.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was last modified.
        majorRevision:
          type: integer
          description: Major version number of the revision being viewed of a resource.
        minorRevision:
          type: integer
          description: Minor version number of the current revision of a resource.
        locked:
          type: boolean
          description: Flag which indicates if the content being viewed is locked or editable.
        sourceRevisionUri:
          type: string
          description: The URI of a resource revision this resource is being created from.
        copyTimeStamp:
          type: string
          format: date-time
          description: The time stamp when the resource revision was copied.
        folderType:
          type: string
          description: Indicates the kind of folder where the resource is housed.
        properties:
          type: object
          description: Properties associated with the revision.
          additionalProperties:
            type: string
        links:
          type: array
          description: The links that apply to the resource.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: The version number of the resource. This representation is version 1.
    link:
      title: Link
      type: object
      description: A link to a related operation or resource.
      required:
        - rel
      properties:
        method:
          type: string
          description: The HTTP method for the link.
        rel:
          type: string
          description: The relationship of the link to the resource.
        uri:
          type: string
          description: The relative URI for the link.
        href:
          type: string
          description: The URL for the link.
        title:
          type: string
          description: The title for the link.
        type:
          type: string
          description: The media type or link type for the link.
        itemType:
          type: string
          description: If this is a link to a container, `itemType` is the media type or link type for the items in the container.
        responseType:
          type: string
          description: The media type or link type of the response body for a `PUT`, `POST`, or `PATCH` operation.
        responseItemType:
          type: string
          description: The media type or link type of the items in the response body for a `PUT`, `POST`, or `PATCH` operation.
    businessRuleQuery:
      title: Rule Query Result
      description: Rule query result representation for displaying rule logic from rule fired tables. This represents application/vnd.sas.business.rule.query.result media type (version 1).
      required:
        - name
        - conditional
        - ruleFiredTrackingEnabled
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object
        name:
          type: string
          description: The name of the rule
        description:
          type: string
          description: The rule description
        createdBy:
          type: string
          description: The user who created the rule.
        creationTimeStamp:
          type: string
          format: date-time
          description: The date and time that the rule was created.
        modifiedBy:
          type: string
          description: The userId of the authenticated user who last updated the rule.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The date and time that the rule was last modified.
        conditional:
          type: string
          description: Determines how the rule is related to this preceding rule. By default all rules are considered 'if' based which means that there logic is executed regardless of the how other rules within the rule set evaluate. However if a user chooses to use 'else' the rule is only evaluated if the previous rule evaluates to 'false'.
          format: enumeration
          enum:
            - if
            - else
        ruleFiredTrackingEnabled:
          type: boolean
          description: Set to true if you want during executions of this rule for rule fired tracking information to be recorded. False if this rule should not have tracking turned on.
        status:
          type: string
          description: The validation status of the rule. This is set to valid if no conditions or actions have validation errors. Its set to false if there are any validation errors across all its conditions and actions.
          format: enumeration
          enum:
            - valid
            - error
        conditionExpressions:
          type: array
          items:
            type: string
          description: The list of conditions serialized into report formatted expression strings.
        actionExpressions:
          type: array
          items:
            type: string
          description: The list of actions serialized into report formatted expression strings.
        ruleSet:
          $ref: "#/components/schemas/ruleSet"
        links:
          type: array
          description: Zero or more links to related resources or operations.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: This media type's schema version number. This representation is version 1.
      example:
        name: Age Requirements
        conditional: if
        ruleFiredTrackingEnabled: true
    functionCategory:
      title: Function Category
      description: A named group to hold a related set of functions.
      required:
        - name
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object.
        name:
          type: string
          description: A unique name for the category.
        description:
          type: string
          description: A description of the category.
        hidden:
          type: boolean
          description: >
            A boolean indicating if the function category is hidden or not.
        createdBy:
          type: string
          description: The user who created the category.
        creationTimeStamp:
          type: string
          format: date-time
          description: The data and time at which the category was created.
        modifiedBy:
          type: string
          description: The user who made the last modification to the category.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The date and time at which the category was last modified.
        links:
          type: array
          description: Zero or more links to related resources or operations.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: >
            This media type's schema version number. This representation is version 1.
      example:
        creationTimeStamp: 2020-06-01T15:38:30.988Z
        modifiedTimeStamp: 2020-06-01T15:38:30.988Z
        createdBy: edmdev
        modifiedBy: edmdev
        id: 4f4bf2a3-5eaa-4899-b238-0e3ebd21ef68
        name: statistical_functions
        description: Functions used to calculate various statistics.
        hidden: true
        links:
          - method: GET
            rel: self
            href: /businessRules/functionCategories/4f4bf2a3-5eaa-4899-b238-0e3ebd21ef68
            uri: /businessRules/functionCategories/4f4bf2a3-5eaa-4899-b238-0e3ebd21ef68
            type: application/vnd.sas.business.rule.function.category
        version: 1
    ruleSet:
      title: Rule Set
      description: >
        The definition of a set of rules and the associated signature for them. This represents the `application/vnd.sas.business.rule.set` media type (version 10).
      required:
        - name
        - signature
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object.
        name:
          type: string
          description: The name of the rule set.
        ruleSetType:
          type: string
          description: >
            The type of rule set. Assignment rule sets enable users to specify variable assignment actions within business rules. Filtering rule sets contain business rules that are only conditions that must be matched for the data to be retained within the resulting output. Assignment is the default if not specified.
          format: enumeration
          enum:
            - assignment
            - filtering
        description:
          type: string
          description: The rule set description
        createdBy:
          type: string
          description: The user who created the rule set.
        creationTimeStamp:
          type: string
          format: date-time
          description: The date and time that the rule set was created.
        modifiedBy:
          type: string
          description: >
            The user ID of the authenticated user who last updated the rule set.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The date and time that the rule set was last modified.
        majorRevision:
          type: integer
          description: >
            Major version number of the revision being viewed of the rule set. This value is assigned by the service, the user only has control on whether the major number or minor number is incremented when creating a new revision. This is a derived field that is generated on PUT/POST.
        minorRevision:
          type: integer
          description: >
            Minor version number of the current revision of the rule set. This value is assigned by the service. The user only has control on whether the major number or minor number is incremented when creating a new revision. This is a derived field that is generated on PUT/POST.
        checkout:
          type: boolean
          description: >
            Flag that indicates that the rule set is a user's working copy of another rule set.
        locked:
          type: boolean
          description: >
            Flag that indicates if the content of the revision being viewed is locked or editable.
        signature:
          type: array
          items:
            $ref: "#/components/schemas/signatureTerm"
          description: >
            The set of terms local to this rule set with input and output behavior.
        folderType:
          type: string
          description: Indicates the type of folder where the rule set is housed.
        sourceRevisionUri:
          type: string
          description: >
            The URI of the rule set revision this rule set is being created from.
        copyTimeStamp:
          type: string
          format: date-time
          description: The time stamp when the ruleset revision was copied.
        testCustomContextUri:
          type: string
          description: The URI of a Custom Context DS2 code file that provides a custom context to this rule set. The ruleset's custom context is usually provided by the decision that uses it. For syntax validation of rule expressions and for testing purposes, you can specify a testing-only custom context.
        links:
          type: array
          description: Zero or more links to related resources or operations.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: >
            This media type's schema version number. This representation is version 10.
      example:
        name: Loan Score Approval
        signature:
          - name: customerName
            dataType: string
            direction: input
          - name: creditScore
            dataType: decimal
            direction: input
          - name: approved
            dataType: boolean
            direction: output
    termUsageSummary:
      title: Term Usage Summary
      description: A summary representation of a term and it's usage.
      required:
        - parentName
        - parentUri
        - name
        - dataType
        - direction
      type: object
      properties:
        parentName:
          type: string
          readOnly: true
          description: The name of the parent resource that contains the term.
        parentUri:
          type: string
          readOnly: true
          description: The uri of the parent resource that contains the term.
        name:
          type: string
          readOnly: true
          description: The name of the term.
        dataType:
          type: string
          readOnly: true
          description: The data type of the term.
          format: enumeration
          enum:
            - string
            - decimal
            - integer
            - date
            - datetime
            - dataGrid
        direction:
          type: string
          readOnly: true
          description: >
            Declaration of how the term is to be used during execution. It indicates if the term should be used as input, output, both input and output, or none if the term is only used internally.
          format: enumeration
          enum:
            - input
            - output
            - inOut
            - none
    lookup:
      title: Lookup
      description: A business rule lookup.
      x-sas-media-type:
        name: application/vnd.sas.business.rule.lookup
        version: 2
      required:
        - name
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object.
        name:
          type: string
          description: A unique name for the lookup.
        realName:
          type: string
          description: The derived real name for the lookup.
        packageName:
          type: string
          description: The derived DS2 package name for the lookup.
        values:
          type: array
          description: The array of key-value lookup pairs.
          items:
            $ref: "#/components/schemas/lookupValue"
        existence:
          type: string
          description: An indicator for whether the lookup exists.
          format: enumeration
          enum:
            - notqueried
            - queried
            - notfound
            - found
        version:
          type: integer
          description: The schema version number. This representation is version 2.
      example:
        id: 96d6bce8-eea0-45ce-bb7b-517304371b51
        name: $LS3LLZ2HOUBC45O33KFZQINY3KE_K
        realName: Currency Codes
        packageName: ls3llz2houbc45o33kfzqiny3ke
        values:
          - key: usd
            value: US Dollar
            version: 1
          - key: gbp
            value: Great British Pound
            version: 1
        version: 1
    ruleSetIntegral:
      title: Rule Set With Rules
      description: >
        The definition of a set of rules and the associated signature for them. This represents the `application/vnd.sas.business.rule.set.integral` media type (version 2).
      allOf:
        - $ref: "#/components/schemas/ruleSet"
        - type: object
          required:
            - rules
          properties:
            rules:
              type: array
              items:
                $ref: "#/components/schemas/businessRule"
              description: The set of rules
            version:
              type: integer
              description: >
                This media type's schema version number. This representation is version 2.
      example:
        name: Loan Score Approval
        rules:
          - name: Age Requirements
            conditional: if
            ruleFiredTrackingEnabled: true
            conditions:
              - type: decisionTable
                expression: age > 10
              - type: decisionTable
                expression: height > 123.00
            actions:
              - type: assignment
                expression: approved = 'Y'
        signature:
          - name: age
            dataType: integer
            direction: input
          - name: height
            dataType: decimal
            direction: input
          - name: approved
            dataType: boolean
            direction: output
    error2:
      title: Error
      type: object
      description: The representation of an error.
      x-sas-media-type:
        name: application/vnd.sas.error
        version: 2
      required:
        - httpStatusCode
        - version
      properties:
        message:
          type: string
          description: The message for the error.
        id:
          type: string
          description: The string ID for the error.
        errorCode:
          type: integer
          description: The numeric ID for the error.
        httpStatusCode:
          type: integer
          description: The HTTP status code for the error.
        details:
          type: array
          description: Messages that provide additional details about the cause of the error.
          items:
            type: string
        remediation:
          type: string
          description: A message that describes how to resolve the error.
        errors:
          type: array
          description: Any additional errors that occurred.
          items:
            $ref: "#/components/schemas/error2"
        links:
          type: array
          description: The links that apply to the error.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: The version number of the error representation. This representation is version 2.
    decisionStepCode:
      title: Decision Step Code
      description: Contains the structure of code that is needed to generate the decision code.
      x-sas-media-type:
        name: application/vnd.sas.decision.step.code
        version: 2
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object.
        name:
          type: string
          description: The name of the object used in decision step.
        description:
          type: string
          description: The description of the object used in decision step.
        createdBy:
          type: string
          description: The user who created the object used in decision step.
        creationTimeStamp:
          type: string
          format: date-time
          description: The date and time that the object used in the decision step was created.
        modifiedBy:
          type: string
          description: The user ID of the authenticated user who last updated the object used in the decision step.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The date and time that the object used in the decision step was last modified.
        code:
          type: string
          description: The code of the object used in the decision step.
        type:
          type: string
          description: The object type of the object used in the decision step.
        signature:
          type: array
          description: Signature variables of the object used in the decision step.
          items:
            $ref: "#/components/schemas/decisionStepCodeSignatureTerm"
        links:
          type: array
          description: Zero or more links to related resources or operations.
          items:
            $ref: "#/components/schemas/link"
        version:
          type: integer
          description: This media type's schema version number. This representation is version 1.
    ruleAction:
      title: Rule Action
      description: Action that is performed if a rule evaluated to true.
      required:
        - type
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object
        type:
          type: string
          description: >
            The type of action that should be performed. The fields required within this element will depend on the type specified. Below is a description of each type possible... <ul> <li>`assignment` - assign a term the value of the provided expression</li> <li>`return` - stop executing the rule and return immediately</li> <li>`complex` - execute an arbitrary piece of DS2 code</li> <li>`lookupValue` - assign the value field for the corresponding domain entry found based on evaluating the expression as a key within the provided reference data domain lookup</li> </ul>
          format: enumeration
          enum:
            - assignment
            - return
            - complex
            - lookupValue
        expression:
          type: string
          description: Expression used for the action. When of type assignment this expression is evaluated and the result is assigned to the term associated with the action. If the type is complex then the expression is treated as arbitrary code that is executed within the context of the rule. For actions of type lookup, this expression is evaluated as the key to lookup and the value found is assigned to the associated term. Expression is only valid only for types lookup, assignment and complex.
        lookup:
          $ref: "#/components/schemas/lookupReference"
        term:
          $ref: "#/components/schemas/signatureTerm"
        status:
          type: string
          description: The validation status of the action. If there are validation issues with the action this will be set to error and provide a message to explain the error to the user.
          format: enumeration
          enum:
            - valid
            - error
        statusMessage:
          type: string
          description: Validation message for any errors within the action.
    unboundScoreCodeGenerationRequest:
      title: Unbound Code Generation Request
      description: Request containing hints and mappings to generate Mapped Code not bound to a score definition.
      properties:
        mappings:
          type: array
          description: Array of mappings between Score Object variables and the table the code will be executed against.
          items:
            $ref: "#/components/schemas/termMapping"
        hints:
          type: object
          description: Hints for generating the code. Hints are specific to the type of object which the code is being requested for.
          additionalProperties:
            type: string
        version:
          type: integer
          readOnly: true
          description: This media type's schema version number. This representation is version 1.
    ruleCondition:
      title: Rule Condition
      description: Conditional that evaluates to true or false.
      required:
        - type
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object
        type:
          type: string
          description: >
            Type of condition that is being used, the fields that are applicable within the object will depend on the type provided. <ul> <li>`decisionTable` - Evaluate if the term meets the provided decision table expression. Valid syntax for a decisionTable expression is 'operator value' so an example would be '= abs(10)'.</li> <li>`lookup` - Determine if the term provided exists within the provided Reference Data domain lookup.</li> <li>`complex` - Execute an arbitrary piece of DS2 code which must evaluate to true or false. Example of valid syntax here is "x > 10 and substr(y, 0, 1) = 'p'".</li> </ul>
          format: enumeration
          enum:
            - decisionTable
            - lookup
            - complex
        expression:
          type: string
          description: Conditional expression used for this condition. Valid only for complex or decisionTable.
        lookup:
          $ref: "#/components/schemas/lookupReference"
        term:
          $ref: "#/components/schemas/signatureTerm"
        status:
          type: string
          description: The validation status of the condition. If there are validation issues with the condition this will be set to error and provide a message to explain the error to the user.
          format: enumeration
          enum:
            - valid
            - error
        statusMessage:
          type: string
          description: Validation message for any errors within the condition.
    selection:
      title: Selection
      description: Identifies a set of resources.
      x-sas-media-type:
        name: application/vnd.sas.selection
        version: 1
      required:
        - version
        - resources
      properties:
        version:
          description: The schema version number of this media type. This representation is version 1.
          type: integer
        template:
          description: 'A URI template in which the {id} parameter can be replaced with a value from the "resources" array in order to yield the URI of the identified resource. '
          type: string
        type:
          description: >-
            Specifies whether the resources array contains IDs, URIs, or both. 

            <dl>

            <dt>"id"</dt><dd>the array contains resource identifiers only. This is the default if "type" is omitted.</dd>

            <dt>"uri"</dt><dd>the array contains resource URIs</dd>

            <dt>"mixed"</dt><dd>the array contains a mixture of identifiers and URIs.</dd>

            </dl>
          type: string
          enum:
            - id
            - uri
            - mixed
        resources:
          description: An array of resource IDs or URIs
          type: array
          items:
            type: string
        links:
          type: array
          description: An array of links to related resources and actions.
          items:
            $ref: "#/components/schemas/link"
    lookupReference:
      title: Lookup Reference
      description: A reference to a lookup within a condition or action of a rule.
      required:
        - id
      properties:
        id:
          type: string
          description: The UUID of the lookup that is being referenced by the rule condition or action.
        name:
          type: string
          description: Name of the lookup. Populated on the users behalf for convenience.
    functionSignatureTerm:
      title: Function Signature Term
      description: An input parameter to a user-defined function.
      required:
        - name
      properties:
        name:
          type: string
          description: The name of the input parameter.
        type:
          type: string
          description: The DS2 type of the parameter.
        dataType:
          type: string
          description: The type of data that the term is intended to be used with. Terms can be loosely typed with the 'any' type, this type is only assigned by the service when rules POST'ed with 'createVariables=true' and no type can be determined.
          format: enumeration
          enum:
            - string
            - decimal
            - integer
            - date
            - datetime
            - dataGrid
            - any
        inOut:
          type: boolean
          description: >
            A boolean indicating if the parameter was preceded with the `in_out` keyword.
        direction:
          type: string
          description: Declaration of how the data is to be used during execution as input, output, both input and output or none if the term is for internal rule set usage only.
          format: enumeration
          enum:
            - input
            - output
            - inOut
            - none
        nameQuoted:
          type: boolean
          description: >
            A boolean indicating if the parameter name is quoted in the function's code.
        defaultValue:
          type: object
          description: The initial value of the term.
        length:
          type: integer
          description: Suggested length for use when using the function.
        dataGridExtension:
          type: array
          description: Fields that are found within the defined data grid type term. These fields are unique only within the data grid and can overlap with other term names. This member is only applicable for terms of type 'dataGrid'.
          items:
            $ref: "#/components/schemas/functionSignatureTermDataGridExtension"
        createdBy:
          type: string
          description: The user who created the term.
        creationTimeStamp:
          type: string
          format: date-time
          description: The date and time that the term was created.
        modifiedBy:
          type: string
          description: The userId of the authenticated user who last updated the term.
        modifiedTimeStamp:
          type: string
          format: date-time
          description: The date and time that the term was last modified.
        dataGridMaxRowCount:
          type: integer
          description: Specifies the maximum number of rows that are allowed in each column of a data grid that is generated from table columns whose names follow the format "column_name[index]" where "column_name" is identical for all columns. If the input data contains more entries for a data grid column than the specified row count allows, the input data for that column is truncated during score execution.
    dataList:
      title: List Data
      description: A list of multiple key and value columns
      x-sas-media-type:
        name: application/vnd.sas.data.list
        version: 1
      required:
        - name
        - state
        - columns
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object.
        name:
          type: string
          description: A unique name for the list.
        state:
          type: string
          description: An indicator for whether the list can be used by deployed artifacts. A list can be either active or inactive. Only inactive lists can be deleted.
          format: enumeration
          enum:
            - inactive
            - active
        description:
          type: string
          description: A textual description of the list.
        isImmutable:
          type: boolean
          description: An indicator for whether the list's contents can be altered after it is imported.
        columns:
          type: array
          description: A collection of objects that define the structure of the list's content.
          items:
            $ref: "#/components/schemas/dataListColumn"
        label:
          type: string
          description: A short textual label, which is appropriate for client UIs.
        version:
          type: integer
          description: The schema version number. This representation is version 1.
      example:
        id: 3659ea38-2618-4474-aeac-0bf6cfd3c322
        creationTimeStamp: 2022-03-01T20:18:32Z
        modifiedTimeStamp: 2022-03-01T20:18:32Z
        createdBy: appUser1
        modifiedBy: appUser1
        name: list-a
        description: The A-list users
        state: inactive
        columns:
          - name: userId
            dataType: string
            position: 1
            isKey: true
            keyPosition: 1
          - name: firstName
            dataType: string
            position: 2
            isKey: false
            keyPosition: 0
          - name: lastName
            dataType: string
            position: 3
            isKey: false
            keyPosition: 0
          - name: salary
            dataType: number
            position: 4
            isKey: false
            keyPosition: 0
            dataMask:
              name: MaskStart
              regularExpression: .(....$)|.
              replace: "*$1"
              example: "****1234"
        label: corporate marketing
        version: 1
    decisionStepCodeSignatureTerm:
      title: Decision Step Code Signature Term
      description: Terms that are a part of the signature for the object that is used in a decision step.
      required:
        - name
        - dataType
        - direction
      properties:
        name:
          type: string
          description: The name of the object used in a decision step.
        dataType:
          type: string
          description: Data type of the term.
          enum:
            - string
            - decimal
            - integer
            - dataGrid
            - date
            - datetime
            - unknown
        direction:
          type: string
          description: Direction of the term.
        length:
          type: integer
          description: Length of the term.
        dataGridExtension:
          type: array
          items:
            $ref: "#/components/schemas/decisionStepCodeSignatureTermDataGridExtension"
          description: Metadata information about data grid columns.
    refRuleMapping:
      title: Reference Rule Mapping
      description: Describes the substitution of local rule set signature terms for signature terms from the referenced common rule set version.
      required:
        - refRuleId
        - rulesetTermName
        - mappedRulesetTermName
        - direction
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object
        rulesetTermName:
          type: string
          description: >
            The name of the term within the common rule set that is being mapped.
        mappedRulesetTermName:
          type: string
          description: >
            The name of the term withing the local rule that is being mapped to.
        refRuleId:
          type: string
          description: >
            The id of the rule that this mapping is associated with.  This id is for the reference rule rather than the common rule that the reference rule refers to.
        direction:
          type: string
          description: >
            Declaration of how the data is to be used during execution. It indicates if the data should be used as input, output or both input and output. set usage.
          format: enumeration
          enum:
            - input
            - output
            - inOut
    termMapping:
      title: Mapping
      description: Assigning Input Data column to a variable of the generated Mapped Code of Score Object. This doesn't represent any top-level media type.
      required:
        - variableName
        - mappingType
      properties:
        variableName:
          type: string
          description: Name of the Score Object's variable.
        mappingType:
          description: The mapping type.
          type: string
          format: enumeration
          enum:
            - datasource
            - static
            - expected
        mappingValue:
          anyOf:
            - type: integer
            - type: number
            - type: array
            - type: boolean
            - type: object
            - type: string
          description: Value that is assigned to Score Object's variable. If the mappingType is dataSource then this should be column name of the Input Data. If the mappingType is static then this should be a constant value. If the mappingType is expected then this is the expected value of the output and it is always constant. Required if the mappingType is datasource.
    advancedListRuleAction:
      title: Rule Advanced List Action
      description: Action referencing an Advanced List that is performed if a rule evaluated to true.
      required:
        - type
        - terms
        - expressionUnits
        - advancedList
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object
        type:
          type: string
          description: The type of action that should be performed.
          format: enumeration
          enum:
            - listQuery
        terms:
          type: array
          description: One or more terms to be assigned values.
          items:
            $ref: "#/components/schemas/signatureTerm"
        expressionUnits:
          type: array
          description: The parts from which the total expression used to search an Advanced List is constructed.
          items:
            $ref: "#/components/schemas/advancedListExpressionUnit"
        advancedList:
          $ref: "#/components/schemas/advancedListReference"
        expression:
          type: string
          description: The action expressed in terms of the rule set terms to be assigned values from the row obtained by searching the specified list for rule terms matching values in the list's key columns.
        status:
          type: string
          description: The validation status of the action. If there is validation issue with the action this will be set to "error".
          format: enumeration
          enum:
            - valid
            - error
        statusMessage:
          type: string
          description: Validation message for an error in the action.
    lookupValue:
      title: Lookup Value
      description: A business rule lookup value.
      x-sas-media-type:
        name: application/vnd.sas.business.rule.lookup.value
        version: 1
      required:
        - key
        - value
      properties:
        key:
          type: string
          description: The unique key that identifies the lookup value.
        value:
          type: string
          description: The lookup value.
        version:
          type: integer
          description: The schema version number. This representation is version 1.
      example:
        key: usd
        value: US Dollar
        version: 1
    signatureTermExtension:
      title: Signature Term Extension
      description: >
        The signature term extension is used to store the column information of a data grid variable.
      required:
        - name
        - dataType
      properties:
        id:
          type: string
          description: The system-assigned unique ID for this object.
        name:
          type: string
          description: >
            The name of the extension that can be referenced from rule logic. The extension must be unique within a data grid.
        length:
          type: integer
          description: The suggested length for use when generating code.
        autoPopulate:
          type: boolean
          description: >
            When this flag is set to true, the code that is generated by the application calls the appropriate data function to create the new column that you added to the metadata at runtime.
        dataType:
          type: string
          description: >
            The type of data that the extension is intended to be used with.
          format: enumeration
          enum:
            - string
            - decimal
            - integer
    advancedListExpressionUnit:
      title: Advanced List Expression Unit
      description: A unit of the total expression. Each unit is logically AND'ed together.
      required:
        - term
      properties:
        term:
          $ref: "#/components/schemas/signatureTerm"
        expressionTermMapping:
          $ref: "#/components/schemas/expressionTermMapping"
    dataListColumn:
      title: List Column
      description: A list column
      x-sas-media-type:
        name: application/vnd.sas.data.list.column
        version: 1
      required:
        - name
        - dataType
        - position
      properties:
        name:
          type: string
          description: A unique name for the column.
        dataType:
          type: string
          description: The type of data stored.
          format: enumeration
          enum:
            - string
            - number
        isKey:
          type: boolean
          description: An indicator for whether the column is a key column.
        position:
          type: integer
          description: The position of the column in the list. The first position is 1.
        keyPosition:
          type: integer
          description: The position of the column among the keys of the list. The first position is 1.
        dataMask:
          description: A restriction or redaction on the presentation of a column's value when retrieving a list's contents.
          additionalProperties:
            $ref: "#/components/schemas/dataListColumnMask"
        version:
          type: integer
          description: The schema version number. This representation is version 1.
      example:
        name: salary
        dataType: number
        position: 4
        isKey: false
        keyPosition: 0
        dataMask:
          name: MaskStart
          regularExpression: .(....$)|.
          replace: "*$1"
          example: "****1234"
    functionSignatureTermDataGridExtension:
      title: Function Signature Term DataGrid Extension
      description: Function Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
      required:
        - name
        - dataType
      properties:
        name:
          type: string
          description: Name of the dataGrid column.
        length:
          type: integer
          description: Length of the value in the dataGrid column. Valid for dataType string.
        dataType:
          type: string
          description: Data type of the dataGrid column.
          format: enumeration
          enum:
            - string
            - decimal
            - integer
            - date
            - datetime
    advancedListReference:
      title: Advanced List Reference
      description: A reference to an Advanced List within an action of a rule.
      required:
        - id
        - name
      properties:
        id:
          type: string
          description: UUID of the Advanced List that is being referenced by the rule action.
        name:
          type: string
          description: Name of the Advanced List.
    decisionStepCodeSignatureTermDataGridExtension:
      title: Decision Step Code Signature Term DataGrid Extension
      description: Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
      required:
        - name
        - dataType
      properties:
        name:
          type: string
          description: Name of the dataGrid column.
        length:
          type: integer
          description: Length of the value in the dataGrid column. Valid for dataType string.
        autoPopulate:
          type: boolean
          description: >
            When this flag value is set to true, the code that is generated by the application calls the appropriate data function to create the new column that you added to the metadata at runtime.
        dataType:
          type: string
          description: Data type of the dataGrid column.
          format: enumeration
          enum:
            - string
            - decimal
            - integer
            - date
            - datetime
    expressionTermMapping:
      title: Expression Term Mapping
      description: Describes the substitution of a local rule set signature term for a term of an expression.
      required:
        - expressionTermName
      properties:
        expressionTermName:
          type: string
          description: The name of a list's key column that is being mapped.
    dataListColumnMask:
      title: List Column Data Mask
      description: A restriction or redaction on the presentation of a column's value when retrieving a list's contents.
      x-sas-media-type:
        name: application/vnd.sas.data.list.column.mask
        version: 1
      required:
        - name
        - regularExpression
        - example
        - replace
      properties:
        name:
          type: string
          description: A unique name for the mask.
        regularExpression:
          type: string
          description: The regular expression for the data mask where members of the group are displayed.
        example:
          type: string
          description: An example of the expected output of a redacted record.
        replace:
          type: string
          description: The replace expression for the groups that result from the regularExpression property.
      example:
        name: mask start
        example: "***123456"
        regularExpression: .(..$)|.
        replace: "*$1"
