NAV Navbar
Home icon
SAS Viya REST APIs
shell javascript python go
  • Decision Management
  • Decision Management

    Model Management

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Model Management API provides basic resources for monitoring performance, comparing models, and running workflow processes.

    Usage Notes

    Overview

    The Model Management API consists of functions that integrate with the Model Repository API.

    Here are the functions that this API provides:

    For more information, see SAS Model Manager: User's Guide.

    Terminology

    performance task definition

    is a definition that includes performance data that is used to monitor the performance of models over a period of time in order to determine when to retrain a model. The performance task definition can be run multiple times and generates a new performance job each time it is run.

    performance job

    job execution results that includes the code, log, and job status (state).

    workflow process

    a business process that is managed by the Workflow service.

    workflow association

    an association of a solution object (such as a model project) to a workflow process.

    workflow task

    a step or action in a workflow process that associates executable logic with an event such as a status change or timer event.

    workflow prompt

    a description of data that must be provided by a user for a workflow task before that task can be completed.

    Error Codes

    HTTP Status Code Error Code Description
    400 21300 You must specify a model ID.
    400 21301 The model does not meet the requirements for performance monitoring.
    400 21302 One or more required parameters are missing for the performance monitor task definition.
    400 21303 The value of the model's target level must be either "binary" or "interval".
    400 21304 The model must be associated with a project.
    400 21305 The value for the model's score code type is not valid for performance monitoring.
    400 74051 The workflow process could not be retrieved.
    400 74080 The workflow process could not be started.
    409 74050 An active association already exists between a model and a workflow process.

    Operations

    Performance Jobs

    Contains the operations for the Performance Jobs resource.

    Get a list of jobs for a performance task

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /performanceTasks/{taskId}/performanceJobs

    Returns a list of the jobs and the performance results that are associated with a specified task ID.

    Parameters
    Name In Type Required Description
    taskId path string true The identifier of the task.
    start query integer(int64) false The index of the first performance task to return.
    limit query integer(int32) false The maximum number of performance tasks to return.
    filter query string(string) false The criteria for filtering the performance jobs. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the performance jobs. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "code": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "state": "string",
          "jobReqId": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. performanceJobCollection
    404 Not Found No performance task exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get performance job results

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /performanceTasks/{taskId}/performanceJobs/{jobId}

    Returns the performance results that are associated with the specified task ID and job ID.

    Parameters
    Name In Type Required Description
    taskId path string true The identifier of the task.
    jobId path string true The identifier of the performance job.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "code": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "state": "string",
          "jobReqId": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. performanceJobCollection
    404 Not Found No performance task or job exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Delete a performance job

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /performanceTasks/{taskId}/performanceJobs/{jobId}

    Deletes the specified performance job.

    Parameters
    Name In Type Required Description
    taskId path string true The identifier of the task.
    jobId path string true The identifier of the performance job.
    Responses
    Status Meaning Description Schema
    204 No Content The performance job was deleted. None
    404 Not Found No performance task exists at the requested path. None

    Get the state of a performance job

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/state \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/plain'
    
    
    
    const headers = {
      'Accept':'text/plain'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/state',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/plain'
    }
    
    r = requests.get('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/state', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/plain"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/state", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /performanceTasks/{taskId}/performanceJobs/{jobId}/state

    Returns the state of the specified performance job.

    Parameters
    Name In Type Required Description
    taskId path string true The identifier of the task.
    jobId path string true The identifier of the performance job.

    Example responses

    200 Response

    {"code":"string","createdBy":"string","creationTimeStamp":"2019-08-24T14:15:22Z","modifiedBy":"string","modifiedTimeStamp":"2019-08-24T14:15:22Z","state":"string","jobReqId":"string"}
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. performanceJob
    404 Not Found No performance job exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get the performance job code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/code \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/vnd.sas.source.sas'
    
    
    
    const headers = {
      'Accept':'text/vnd.sas.source.sas'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/code',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/vnd.sas.source.sas'
    }
    
    r = requests.get('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/code', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/vnd.sas.source.sas"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/code", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /performanceTasks/{taskId}/performanceJobs/{jobId}/code

    Returns the performance job execution code for a performance task.

    Parameters
    Name In Type Required Description
    taskId path string true The identifier of the task.
    jobId path string true The identifier of the performance job.

    Example responses

    200 Response

    {"code":"string","createdBy":"string","creationTimeStamp":"2019-08-24T14:15:22Z","modifiedBy":"string","modifiedTimeStamp":"2019-08-24T14:15:22Z","state":"string","jobReqId":"string"}
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. performanceJob
    404 Not Found No performance job exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a performance job log

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/log \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/plain'
    
    
    
    const headers = {
      'Accept':'text/plain'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/log',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/plain'
    }
    
    r = requests.get('https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/log', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/plain"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/performanceTasks/{taskId}/performanceJobs/{jobId}/log", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /performanceTasks/{taskId}/performanceJobs/{jobId}/log

    Returns the execution log for a performance job.

    Parameters
    Name In Type Required Description
    taskId path string true The identifier of the task.
    jobId path string true The identifier of the performance job.

    Example responses

    200 Response

    {"code":"string","createdBy":"string","creationTimeStamp":"2019-08-24T14:15:22Z","modifiedBy":"string","modifiedTimeStamp":"2019-08-24T14:15:22Z","state":"string","jobReqId":"string"}
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. performanceJob
    404 Not Found No performance job exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get the performance report data

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/performanceTasks/{taskId}/performanceReportData \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.models.performance.task.report.data.lift+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.models.performance.task.report.data.lift+json'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}/performanceReportData',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.models.performance.task.report.data.lift+json'
    }
    
    r = requests.get('https://example.com/modelManagement/performanceTasks/{taskId}/performanceReportData', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.models.performance.task.report.data.lift+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/performanceTasks/{taskId}/performanceReportData", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /performanceTasks/{taskId}/performanceReportData

    Retrieves the performance monitoring report data associated with the specified task ID.

    Parameters
    Name In Type Required Description
    taskId path string true The identifier of the performance task.
    Accept-Item header string true The desired performance report data representation.
    The Accept-Item options are:
    • application/vnd.sas.models.performance.task.report.data.lift+json
    • application/vnd.sas.models.performance.task.report.data.variable.summary+json
    • application/vnd.sas.models.performance.task.report.data.variable.deviation+json
    • application/vnd.sas.models.performance.task.report.data.roc+json
    • application/vnd.sas.models.performance.task.report.data.ks.cumulative+json
    • application/vnd.sas.models.performance.task.report.data.ks.statistic+json
    • application/vnd.sas.models.performance.task.report.data.mse+json
    If this header is not specified a 400 bad request HTTP Status code is returned.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.models.performance.task.report.data.lift+json
    Accept-Item application/vnd.sas.models.performance.task.report.data.variable.summary+json
    Accept-Item application/vnd.sas.models.performance.task.report.data.variable.deviation+json
    Accept-Item application/vnd.sas.models.performance.task.report.data.roc+json
    Accept-Item application/vnd.sas.models.performance.task.report.data.ks.cumulative+json
    Accept-Item application/vnd.sas.models.performance.task.report.data.ks.statistic+json
    Accept-Item application/vnd.sas.models.performance.task.report.data.mse+json

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": []
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. workflowTask
    404 Not Found No performance task exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Performance Tasks

    Contains the operations for the Performance Tasks resource.

    Get a list of performance tasks

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/performanceTasks \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelManagement/performanceTasks', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/performanceTasks", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /performanceTasks

    Returns a list of performance tasks.

    Parameters
    Name In Type Required Description
    projectId query string false The server-generated identifier for the project.
    start query integer(int64) false The index of the first performance task to return.
    limit query integer(int32) false The maximum number of performance tasks to return.
    filter query string(string) false The criteria for filtering the performance task definitions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the performance task definitions. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "assessAlert": "string",
          "assessWarn": "string",
          "characteristicAlert": "string",
          "characteristicWarn": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "dataLibrary": "string",
          "dataPrefix": "string",
          "id": "string",
          "inputVariables": [
            "string"
          ],
          "maxBins": 0,
          "modelId": [
            "string"
          ],
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "outputVariables": [
            "string"
          ],
          "performanceResultSaved": true,
          "resultLibrary": "string",
          "scoreExecutionRequired": true,
          "stabilityAlert": "string",
          "stabilityWarn": "string",
          "includeAllData": true,
          "loadPerformanceResult": true,
          "championMonitored": true,
          "challengerMonitored": true,
          "traceOn": true,
          "version": 0
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. performanceTaskCollection

    Create a performance task definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelManagement/performanceTasks \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.performance.task+json' \
      -H 'Accept: application/vnd.sas.models.performance.task+json'
    
    
    const inputBody = '{
      "assessAlert": "string",
      "assessWarn": "string",
      "characteristicAlert": "string",
      "characteristicWarn": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "dataLibrary": "string",
      "dataPrefix": "string",
      "id": "string",
      "inputVariables": [
        "string"
      ],
      "maxBins": 0,
      "modelId": [
        "string"
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "outputVariables": [
        "string"
      ],
      "performanceResultSaved": true,
      "resultLibrary": "string",
      "scoreExecutionRequired": true,
      "stabilityAlert": "string",
      "stabilityWarn": "string",
      "includeAllData": true,
      "loadPerformanceResult": true,
      "championMonitored": true,
      "challengerMonitored": true,
      "traceOn": true,
      "version": 0
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.performance.task+json',
      'Accept':'application/vnd.sas.models.performance.task+json'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.performance.task+json',
      'Accept': 'application/vnd.sas.models.performance.task+json'
    }
    
    r = requests.post('https://example.com/modelManagement/performanceTasks', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.performance.task+json"},
            "Accept": []string{"application/vnd.sas.models.performance.task+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelManagement/performanceTasks", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /performanceTasks

    Creates a performance task definition.

    Body parameter

    {
      "assessAlert": "string",
      "assessWarn": "string",
      "characteristicAlert": "string",
      "characteristicWarn": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "dataLibrary": "string",
      "dataPrefix": "string",
      "id": "string",
      "inputVariables": [
        "string"
      ],
      "maxBins": 0,
      "modelId": [
        "string"
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "outputVariables": [
        "string"
      ],
      "performanceResultSaved": true,
      "resultLibrary": "string",
      "scoreExecutionRequired": true,
      "stabilityAlert": "string",
      "stabilityWarn": "string",
      "includeAllData": true,
      "loadPerformanceResult": true,
      "championMonitored": true,
      "challengerMonitored": true,
      "traceOn": true,
      "version": 0
    }
    
    Parameters
    Name In Type Required Description
    body body performanceTask true The definition of the performance task.

    Example responses

    201 Response

    {
      "assessAlert": "string",
      "assessWarn": "string",
      "characteristicAlert": "string",
      "characteristicWarn": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "dataLibrary": "string",
      "dataPrefix": "string",
      "id": "string",
      "inputVariables": [
        "string"
      ],
      "maxBins": 0,
      "modelId": [
        "string"
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "outputVariables": [
        "string"
      ],
      "performanceResultSaved": true,
      "resultLibrary": "string",
      "scoreExecutionRequired": true,
      "stabilityAlert": "string",
      "stabilityWarn": "string",
      "includeAllData": true,
      "loadPerformanceResult": true,
      "championMonitored": true,
      "challengerMonitored": true,
      "traceOn": true,
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The performance task definition was created. performanceTask
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 ETag string A tag that identifies the revision of this performance task definition.
    201 Location string uri The URL of the performance task definition.

    Create performance job history

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelManagement/performanceTasks/@defaultTask/performanceJobs \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.performance.job+json' \
      -H 'Accept: application/vnd.sas.models.performance.job+json'
    
    
    const inputBody = '{
      "code": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "state": "string",
      "jobReqId": "string"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.performance.job+json',
      'Accept':'application/vnd.sas.models.performance.job+json'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/@defaultTask/performanceJobs',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.performance.job+json',
      'Accept': 'application/vnd.sas.models.performance.job+json'
    }
    
    r = requests.post('https://example.com/modelManagement/performanceTasks/@defaultTask/performanceJobs', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.performance.job+json"},
            "Accept": []string{"application/vnd.sas.models.performance.job+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelManagement/performanceTasks/@defaultTask/performanceJobs", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /performanceTasks/@defaultTask/performanceJobs

    Creates the performance job history.

    Body parameter

    {
      "code": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "state": "string",
      "jobReqId": "string"
    }
    
    Parameters
    Name In Type Required Description
    body body performanceJob true The definition of the performance job.

    Example responses

    201 Response

    {
      "code": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "state": "string",
      "jobReqId": "string"
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The performance job was created. performanceJob
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string uri The URL of the performance job.

    Get a performance task definition

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/performanceTasks/{taskId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.performance.task+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.performance.task+json'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.performance.task+json'
    }
    
    r = requests.get('https://example.com/modelManagement/performanceTasks/{taskId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.performance.task+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/performanceTasks/{taskId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /performanceTasks/{taskId}

    Returns the performance task definition.

    Parameters
    Name In Type Required Description
    taskId path string true Identifier of the task.
    start query integer(int64) false The index of the first performance task to return.
    limit query integer(int32) false The maximum number of performance tasks to return.

    Example responses

    200 Response

    {
      "code": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "state": "string",
      "jobReqId": "string"
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. performanceJob
    404 Not Found No performance task definition exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.

    Execute a performance task

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelManagement/performanceTasks/{taskId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.performance.task+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.performance.task+json'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}',
    {
      method: 'POST',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.performance.task+json'
    }
    
    r = requests.post('https://example.com/modelManagement/performanceTasks/{taskId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.performance.task+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelManagement/performanceTasks/{taskId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /performanceTasks/{taskId}

    Executes a performance task job.

    Parameters
    Name In Type Required Description
    taskId path string true Identifier of the task.

    Example responses

    201 Response

    {
      "code": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "state": "string",
      "jobReqId": "string"
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The performance task was executed. performanceJob
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 ETag string A tag that identifies the revision of this object.
    201 Location string uri The URL of the performance task.

    Update a performance task definition

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelManagement/performanceTasks/{taskId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.performance.task+json' \
      -H 'Accept: application/vnd.sas.models.performance.task+json' \
      -H 'Etag: string'
    
    
    const inputBody = '{
      "assessAlert": "string",
      "assessWarn": "string",
      "characteristicAlert": "string",
      "characteristicWarn": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "dataLibrary": "string",
      "dataPrefix": "string",
      "id": "string",
      "inputVariables": [
        "string"
      ],
      "maxBins": 0,
      "modelId": [
        "string"
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "outputVariables": [
        "string"
      ],
      "performanceResultSaved": true,
      "resultLibrary": "string",
      "scoreExecutionRequired": true,
      "stabilityAlert": "string",
      "stabilityWarn": "string",
      "includeAllData": true,
      "loadPerformanceResult": true,
      "championMonitored": true,
      "challengerMonitored": true,
      "traceOn": true,
      "version": 0
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.performance.task+json',
      'Accept':'application/vnd.sas.models.performance.task+json',
      'Etag':'string'
    };
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.performance.task+json',
      'Accept': 'application/vnd.sas.models.performance.task+json',
      'Etag': 'string'
    }
    
    r = requests.put('https://example.com/modelManagement/performanceTasks/{taskId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.performance.task+json"},
            "Accept": []string{"application/vnd.sas.models.performance.task+json"},
            "Etag": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelManagement/performanceTasks/{taskId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /performanceTasks/{taskId}

    Updates the performance task definition associated with the specified task ID.

    Body parameter

    {
      "assessAlert": "string",
      "assessWarn": "string",
      "characteristicAlert": "string",
      "characteristicWarn": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "dataLibrary": "string",
      "dataPrefix": "string",
      "id": "string",
      "inputVariables": [
        "string"
      ],
      "maxBins": 0,
      "modelId": [
        "string"
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "outputVariables": [
        "string"
      ],
      "performanceResultSaved": true,
      "resultLibrary": "string",
      "scoreExecutionRequired": true,
      "stabilityAlert": "string",
      "stabilityWarn": "string",
      "includeAllData": true,
      "loadPerformanceResult": true,
      "championMonitored": true,
      "challengerMonitored": true,
      "traceOn": true,
      "version": 0
    }
    
    Parameters
    Name In Type Required Description
    Etag header string true If-Match
    taskId path string true The identifier of the task.
    body body performanceTask true The task contents for updating the task.

    Example responses

    200 Response

    {
      "assessAlert": "string",
      "assessWarn": "string",
      "characteristicAlert": "string",
      "characteristicWarn": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "dataLibrary": "string",
      "dataPrefix": "string",
      "id": "string",
      "inputVariables": [
        "string"
      ],
      "maxBins": 0,
      "modelId": [
        "string"
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "outputVariables": [
        "string"
      ],
      "performanceResultSaved": true,
      "resultLibrary": "string",
      "scoreExecutionRequired": true,
      "stabilityAlert": "string",
      "stabilityWarn": "string",
      "includeAllData": true,
      "loadPerformanceResult": true,
      "championMonitored": true,
      "challengerMonitored": true,
      "traceOn": true,
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. performanceTask
    400 Bad Request The request was invalid. errorResponse
    412 Precondition Failed The If-Match request header did not match the resource's entity tag (ETag). Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string A tag that identifies the revision of this object.

    Delete a performance task definition

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelManagement/performanceTasks/{taskId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/modelManagement/performanceTasks/{taskId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/modelManagement/performanceTasks/{taskId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelManagement/performanceTasks/{taskId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /performanceTasks/{taskId}

    Deletes a performance task definition.

    Parameters
    Name In Type Required Description
    taskId path string true The identifier of the task.
    deleteTask query boolean false Indicates whether to delete the task.
    deleteTable query boolean false Indicates whether to delete the table.
    Responses
    Status Meaning Description Schema
    204 No Content The performance task was deleted. None
    404 Not Found No performance task exists at the requested path. None

    Workflow Associations

    Contains the operations for the Workflow Associations resource.

    Get all workflow object associations

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/workflowAssociations \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelManagement/workflowAssociations',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelManagement/workflowAssociations', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/workflowAssociations", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /workflowAssociations

    Returns a list of all workflow process associations to a model object.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first workflow process association to return.
    limit query integer(int32) false The maximum number of workflow process associations to return.
    filter query string(string) false The criteria for filtering the workflow process associations. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the workflow process associations. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "id": "string",
      "processId": "string",
      "processName": "string",
      "parentProcessId": "string",
      "objectType": "string",
      "solutionObjectId": "string",
      "solutionObjectName": "string",
      "solutionObjectUri": "string",
      "solutionObjectMediaType": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. workflowAssociation
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Create a workflow association

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelManagement/workflowAssociations \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.workflow.object.association+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.workflow.object.association+json'
    };
    
    fetch('https://example.com/modelManagement/workflowAssociations',
    {
      method: 'POST',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.workflow.object.association+json'
    }
    
    r = requests.post('https://example.com/modelManagement/workflowAssociations', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.workflow.object.association+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelManagement/workflowAssociations", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /workflowAssociations

    Creates an association between a workflow process and a Model Repository object. This association is readable by SAS Model Manager so that it can understand when a model object, such as a project, is being used in a workflow process. SAS Model Manager can change its behavior for an object when that object is being used by a workflow process.

    Example responses

    201 Response

    {
      "id": "string",
      "processId": "string",
      "processName": "string",
      "parentProcessId": "string",
      "objectType": "string",
      "solutionObjectId": "string",
      "solutionObjectName": "string",
      "solutionObjectUri": "string",
      "solutionObjectMediaType": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A new association between a workflow process and a model object was created. workflowAssociation
    400 Bad Request The request was invalid. errorResponse
    409 Conflict The requested workflow association conflicts with an existing resource. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 409

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string uri The URL of the workflow association.

    Get a workflow object association

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/workflowAssociations/{associationId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.workflow.object.association+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.workflow.object.association+json'
    };
    
    fetch('https://example.com/modelManagement/workflowAssociations/{associationId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.workflow.object.association+json'
    }
    
    r = requests.get('https://example.com/modelManagement/workflowAssociations/{associationId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.workflow.object.association+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/workflowAssociations/{associationId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /workflowAssociations/{associationId}

    Returns a specific association for a workflow process to model object.

    Parameters
    Name In Type Required Description
    associationId path string true The ID of the workflow object association.

    Example responses

    200 Response

    {
      "id": "string",
      "processId": "string",
      "processName": "string",
      "parentProcessId": "string",
      "objectType": "string",
      "solutionObjectId": "string",
      "solutionObjectName": "string",
      "solutionObjectUri": "string",
      "solutionObjectMediaType": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. workflowAssociation
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No association ID exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Workflow Processes

    Contains the operations for the Workflow Processes resource.

    Get all workflow processes

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/workflowProcesses \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelManagement/workflowProcesses',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelManagement/workflowProcesses', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/workflowProcesses", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /workflowProcesses

    Returns all workflow processes that are associated with SAS Model Manager. The workflow processes are managed using the Workflow service. The processes in this list are defined in the Workflow service with the client registration ID for SAS Model Manager.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first workflow process to return.
    limit query integer(int32) false The maximum number of workflow processes to return.
    filter query string(string) false The criteria for filtering the workflow processes. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the workflow processes. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "id": "string",
      "parentId": "string",
      "name": "string",
      "createdTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "state": "string",
      "description": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. workflowProcess
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a workflow process

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/workflowProcesses/{processId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.workflow.object.process+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.workflow.object.process+json'
    };
    
    fetch('https://example.com/modelManagement/workflowProcesses/{processId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.workflow.object.process+json'
    }
    
    r = requests.get('https://example.com/modelManagement/workflowProcesses/{processId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.workflow.object.process+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/workflowProcesses/{processId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /workflowProcesses/{processId}

    Returns a specific workflow process that has been associated with SAS Model Manager. The workflow is managed and authorized in the Workflow service. The process is available only if it has a client registration ID for SAS Model Manager.

    Parameters
    Name In Type Required Description
    processId path string true The ID of the workflow process.

    Example responses

    200 Response

    {
      "id": "string",
      "parentId": "string",
      "name": "string",
      "createdTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "state": "string",
      "description": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. workflowProcess
    400 Bad Request The request was invalid. errorResponse
    404 Not Found The process ID was not found. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Workflow Tasks

    Contains the operations for the Workflow Tasks resource.

    Get active workflow tasks

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/workflowTasks \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelManagement/workflowTasks',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelManagement/workflowTasks', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/workflowTasks", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /workflowTasks

    Returns active workflow tasks that are associated with SAS Model Manager. These are tasks where the authenticated user is either the owner or a potential owner. The tasks are managed using the Workflow service.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first workflow tasks to return.
    limit query integer(int32) false The maximum number of workflow tasks to return.

    Example responses

    200 Response

    {
      "id": "string",
      "processId": "string",
      "processTaskId": "string",
      "name": "string",
      "definitionName": "string",
      "actualOwner": "string",
      "state": "string",
      "stateTimeStamp": "2019-08-24T14:15:22Z",
      "taskDueTimeStamp": "2019-08-24T14:15:22Z",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "associations": [
        {
          "id": "string",
          "processId": "string",
          "processName": "string",
          "parentProcessId": "string",
          "objectType": "string",
          "solutionObjectId": "string",
          "solutionObjectName": "string",
          "solutionObjectUri": "string",
          "solutionObjectMediaType": "string",
          "version": 0,
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "resourceCollection": [
        {
          "name": "string",
          "start": 0,
          "limit": 0,
          "count": 0,
          "accept": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0,
          "items": []
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. workflowTask
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a workflow task

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/workflowTasks/{taskId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.workflow.object.task+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.workflow.object.task+json'
    };
    
    fetch('https://example.com/modelManagement/workflowTasks/{taskId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.workflow.object.task+json'
    }
    
    r = requests.get('https://example.com/modelManagement/workflowTasks/{taskId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.workflow.object.task+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/workflowTasks/{taskId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /workflowTasks/{taskId}

    Returns an active task for a workflow process that is associated with a project in SAS Model Manager. The tasks that are returned have the authorized user as the owner or a potential owner.

    Parameters
    Name In Type Required Description
    taskId path string true The ID of a task from the tasks collection.

    Example responses

    200 Response

    {
      "id": "string",
      "processId": "string",
      "processTaskId": "string",
      "name": "string",
      "definitionName": "string",
      "actualOwner": "string",
      "state": "string",
      "stateTimeStamp": "2019-08-24T14:15:22Z",
      "taskDueTimeStamp": "2019-08-24T14:15:22Z",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "associations": [
        {
          "id": "string",
          "processId": "string",
          "processName": "string",
          "parentProcessId": "string",
          "objectType": "string",
          "solutionObjectId": "string",
          "solutionObjectName": "string",
          "solutionObjectUri": "string",
          "solutionObjectMediaType": "string",
          "version": 0,
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "resourceCollection": [
        {
          "name": "string",
          "start": 0,
          "limit": 0,
          "count": 0,
          "accept": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0,
          "items": []
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. workflowTask
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No task with the specified ID exists at the requested path. None
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a list of workflow task prompts

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/workflowTasks/{taskId}/prompts \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelManagement/workflowTasks/{taskId}/prompts',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelManagement/workflowTasks/{taskId}/prompts', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/workflowTasks/{taskId}/prompts", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /workflowTasks/{taskId}/prompts

    Returns a list of all prompts that are associated with a workflow user task. The prompts are part of the workflow definition.

    Parameters
    Name In Type Required Description
    taskId path string true The ID of a task from the tasks collection.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "variableType": "string",
      "variableName": "string",
      "values": [
        {
          "id": "string",
          "name": "string",
          "value": "string"
        }
      ],
      "required": "string",
      "defaultValueId": "string",
      "actualValue": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. taskPrompt
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No task with the specified ID exists at the requested path. None
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a workflow task prompt

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/workflowTasks/{taskId}/prompts/{promptId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.workflow.object.task.prompt+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.workflow.object.task.prompt+json'
    };
    
    fetch('https://example.com/modelManagement/workflowTasks/{taskId}/prompts/{promptId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.workflow.object.task.prompt+json'
    }
    
    r = requests.get('https://example.com/modelManagement/workflowTasks/{taskId}/prompts/{promptId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.workflow.object.task.prompt+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/workflowTasks/{taskId}/prompts/{promptId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /workflowTasks/{taskId}/prompts/{promptId}

    Returns a specific prompt associated with a workflow user task. The prompts are part of the workflow definition.

    Parameters
    Name In Type Required Description
    taskId path string true The ID of a task from the tasks collection.
    promptId path string true The ID of a prompt from the prompts collection.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "variableType": "string",
      "variableName": "string",
      "values": [
        {
          "id": "string",
          "name": "string",
          "value": "string"
        }
      ],
      "required": "string",
      "defaultValueId": "string",
      "actualValue": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. taskPrompt
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No task or prompt with the specified ID exists at the requested path. None
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Code

    Contains the operation for generating code for models.

    Generate mapped model score code

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelManagement/models/{modelId}/mappedCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/modelManagement/models/{modelId}/mappedCode',
    {
      method: 'POST',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/modelManagement/models/{modelId}/mappedCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelManagement/models/{modelId}/mappedCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models/{modelId}/mappedCode

    Generates mapped score code for a model that is wrapped for use with the Score Execution service. The model is managed in the common model repository by the Model Repository API. For more information, see the Model Repository API.

    Parameters
    Name In Type Required Description
    modelId path string true The ID of a model in the common model repository.

    Example responses

    201 Response

    {
      "code": "/* DS2 code of an object, which generates an XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS"
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model exists at the requested path. None
    Response Schema

    Status Code 201

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 1.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Model Comparison Reports

    Contains the operations for a generating model comparison reports.

    Create a model comparison report

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelManagement/reports \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.report.comparison.request+json' \
      -H 'Accept: application/vnd.sas.models.report.comparison.model+json'
    
    
    const inputBody = '{
      "name": "string",
      "description": "string",
      "modelUris": [
        "string"
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.report.comparison.request+json',
      'Accept':'application/vnd.sas.models.report.comparison.model+json'
    };
    
    fetch('https://example.com/modelManagement/reports',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.report.comparison.request+json',
      'Accept': 'application/vnd.sas.models.report.comparison.model+json'
    }
    
    r = requests.post('https://example.com/modelManagement/reports', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.report.comparison.request+json"},
            "Accept": []string{"application/vnd.sas.models.report.comparison.model+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelManagement/reports", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /reports

    Creates a model comparison report.

    Body parameter

    {
      "name": "string",
      "description": "string",
      "modelUris": [
        "string"
      ]
    }
    
    Parameters
    Name In Type Required Description
    body body reportRequest true The definition of the report request.

    Example responses

    201 Response

    {
      "parentId": "string",
      "modelIds": [
        "string"
      ],
      "comparedModels": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetLevel": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ],
      "allInputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "allOutputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "allProperties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A model comparison report was created. reportResponse
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Publish Models

    Contains the operations for publishing models.

    Publish models

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelManagement/publish \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.publishing.request.asynchronous+json' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    const inputBody = '{
      "contents": {},
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "databaseServer": {
        "authenticationDomain": "string",
        "casServerName": "string",
        "configDir": "string",
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "credentialUri": "string",
        "databaseCasLibrary": "string",
        "databaseSchema": "string",
        "databaseType": "string",
        "description": "string",
        "hdfsDir": "string",
        "host": "string",
        "id": "string",
        "library": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "name": "string",
        "password": "string",
        "port": 0,
        "restPort": 0,
        "table": "string",
        "type": "string",
        "user": "string",
        "version": 0
      },
      "description": "string",
      "destinationName": "string",
      "modelContents": [
        {
          "astoreUri": "string",
          "code": "string",
          "codeDescription": "string",
          "codeScope": "string",
          "codeType": "string",
          "codeUri": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "format": "string",
          "formatUri": "string",
          "modelId": "string",
          "modelName": "string",
          "modelVersionId": "string",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "principalId": "string",
          "projectId": "string",
          "publishLevel": "string",
          "publishNotes": "string",
          "sourceUri": "string",
          "variableXml": "string"
        }
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "notes": "string",
      "properties": {
        "property1": "string",
        "property2": "string"
      },
      "targetServer": {
        "authenticationDomain": "string",
        "casServerName": "string",
        "configDir": "string",
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "credentialUri": "string",
        "databaseCasLibrary": "string",
        "databaseSchema": "string",
        "databaseType": "string",
        "description": "string",
        "hdfsDir": "string",
        "host": "string",
        "id": "string",
        "library": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "name": "string",
        "password": "string",
        "port": 0,
        "restPort": 0,
        "table": "string",
        "type": "string",
        "user": "string",
        "version": 0
      },
      "targetServerLibraryUri": "string",
      "targetServerName": "string",
      "targetServerPassword": "string",
      "targetServerUri": "string",
      "type": "string",
      "verified": true,
      "version": 0
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.publishing.request.asynchronous+json',
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelManagement/publish',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.publishing.request.asynchronous+json',
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.post('https://example.com/modelManagement/publish', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.publishing.request.asynchronous+json"},
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelManagement/publish", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /publish

    Publish a model to a CAS, Hadoop, Teradata, or SAS Micro Analytic Service publishing destination.

    Body parameter

    {
      "contents": {},
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "databaseServer": {
        "authenticationDomain": "string",
        "casServerName": "string",
        "configDir": "string",
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "credentialUri": "string",
        "databaseCasLibrary": "string",
        "databaseSchema": "string",
        "databaseType": "string",
        "description": "string",
        "hdfsDir": "string",
        "host": "string",
        "id": "string",
        "library": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "name": "string",
        "password": "string",
        "port": 0,
        "restPort": 0,
        "table": "string",
        "type": "string",
        "user": "string",
        "version": 0
      },
      "description": "string",
      "destinationName": "string",
      "modelContents": [
        {
          "astoreUri": "string",
          "code": "string",
          "codeDescription": "string",
          "codeScope": "string",
          "codeType": "string",
          "codeUri": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "format": "string",
          "formatUri": "string",
          "modelId": "string",
          "modelName": "string",
          "modelVersionId": "string",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "principalId": "string",
          "projectId": "string",
          "publishLevel": "string",
          "publishNotes": "string",
          "sourceUri": "string",
          "variableXml": "string"
        }
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "notes": "string",
      "properties": {
        "property1": "string",
        "property2": "string"
      },
      "targetServer": {
        "authenticationDomain": "string",
        "casServerName": "string",
        "configDir": "string",
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "credentialUri": "string",
        "databaseCasLibrary": "string",
        "databaseSchema": "string",
        "databaseType": "string",
        "description": "string",
        "hdfsDir": "string",
        "host": "string",
        "id": "string",
        "library": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "name": "string",
        "password": "string",
        "port": 0,
        "restPort": 0,
        "table": "string",
        "type": "string",
        "user": "string",
        "version": 0
      },
      "targetServerLibraryUri": "string",
      "targetServerName": "string",
      "targetServerPassword": "string",
      "targetServerUri": "string",
      "type": "string",
      "verified": true,
      "version": 0
    }
    
    Parameters
    Name In Type Required Description
    force query boolean false force
    body body publishRequest true The representation of a publish request.

    Example responses

    201 Response

    {
      "accept": "string",
      "count": 0,
      "items": [
        {}
      ],
      "limit": 0,
      "name": "string",
      "start": 0
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The models were published successfully. resourceCollection
    400 Bad Request The request was invalid. Errors might of been caused by the model that was published, a snapshot that could not be created, the destination was not specified, or there are no models provided by the "modelContents". Inline
    404 Not Found No model score code exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1performanceTasks/post/responses/400/content/application~1vnd.sas.models.performance.task%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Root

    Contains the operations for the Root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelManagement/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/modelManagement/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/modelManagement/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelManagement/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns a list of links to the top-level resources that are surfaced through the API.

    Example responses

    200 Response

    {
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.

    Check API availability

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelManagement/
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/modelManagement/',
    {
      method: 'HEAD'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.head('https://example.com/modelManagement/')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelManagement/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /

    Returns the headers for the API. Also used to determine whether the service provided by the API is available.

    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.
    200 Last-Modified string date-time The last modified timestamp of this object.

    Schemas

    performanceJob

    {
      "code": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "state": "string",
      "jobReqId": "string"
    }
    
    

    Performance Job

    Properties
    Name Type Required Restrictions Description
    code string false none The performance job SAS code.
    createdBy string false none The user who created the job.
    creationTimeStamp string(date-time) false none The timestamp for when the job was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedBy string false none The user who most recently modified the job.
    modifiedTimeStamp string(date-time) false none The timestamp for when the job was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    state string false none The performance job state (running
    jobReqId string false none The identifier for a job request.

    performanceTask

    {
      "assessAlert": "string",
      "assessWarn": "string",
      "characteristicAlert": "string",
      "characteristicWarn": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "dataLibrary": "string",
      "dataPrefix": "string",
      "id": "string",
      "inputVariables": [
        "string"
      ],
      "maxBins": 0,
      "modelId": [
        "string"
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "outputVariables": [
        "string"
      ],
      "performanceResultSaved": true,
      "resultLibrary": "string",
      "scoreExecutionRequired": true,
      "stabilityAlert": "string",
      "stabilityWarn": "string",
      "includeAllData": true,
      "loadPerformanceResult": true,
      "championMonitored": true,
      "challengerMonitored": true,
      "traceOn": true,
      "version": 0
    }
    
    

    Performance Task

    Properties
    Name Type Required Restrictions Description
    assessAlert string false none The assessment measurements alert condition.
    assessWarn string false none The assessment measurements warning condition.
    characteristicAlert string false none The characteristic measurements alert condition.
    characteristicWarn string false none The characteristic measurements warning condition.
    createdBy string false none The user who created the task.
    creationTimeStamp string(date-time) false none The timestamp for when the task was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    dataLibrary string false none The performance table library URI.
    dataPrefix string false none The performance data table prefix.
    id string false none The identifier for a performance task.
    inputVariables [string] false none The input variables for the performance task.
    maxBins integer(int32) false none The maximum bins number.
    modelId [string] false none The modelId for the performance task.
    modifiedBy string false none The user who most recently modified the task.
    modifiedTimeStamp string(date-time) false none The timestamp for when the job was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    outputVariables [string] false none The output variables for the performance task.
    performanceResultSaved boolean false none Indicates whether the performance results are saved.
    resultLibrary string false none The performance output table library URI.
    scoreExecutionRequired boolean false none Indicates whether the scoring task execution is required.
    stabilityAlert string false none The stability measurements alert condition.
    stabilityWarn string false none The stability measurements warning condition.
    includeAllData boolean false none Indicates whether to run a performance job against all the data tables in a library.
    loadPerformanceResult boolean false none Indicates to load performance result data.
    championMonitored boolean false none Indicates to monitor the project champion model.
    challengerMonitored boolean false none Indicates to monitor challenger models.
    traceOn boolean false none Indicates whether to turn on tracing.
    version integer false none The version number of application/vnd.sas.models.performance.task+json.

    performanceTaskCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "assessAlert": "string",
          "assessWarn": "string",
          "characteristicAlert": "string",
          "characteristicWarn": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "dataLibrary": "string",
          "dataPrefix": "string",
          "id": "string",
          "inputVariables": [
            "string"
          ],
          "maxBins": 0,
          "modelId": [
            "string"
          ],
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "outputVariables": [
            "string"
          ],
          "performanceResultSaved": true,
          "resultLibrary": "string",
          "scoreExecutionRequired": true,
          "stabilityAlert": "string",
          "stabilityWarn": "string",
          "includeAllData": true,
          "loadPerformanceResult": true,
          "championMonitored": true,
          "challengerMonitored": true,
          "traceOn": true,
          "version": 0
        }
      ]
    }
    
    

    Performance Task Collection

    Properties
    Name Type Required Restrictions Description
    Performance Task Collection any false none The performance task representations.

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [link] false none The links that apply to the collection.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [performanceTask] true none An array consisting of performance task resources.

    performanceJobCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "code": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "state": "string",
          "jobReqId": "string"
        }
      ]
    }
    
    

    Performance Job Collection

    Properties
    Name Type Required Restrictions Description
    Performance Job Collection any false none The performance job representations.

    allOf

    Name Type Required Restrictions Description
    anonymous performanceTaskCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [performanceJob] true none An array consisting of performance task resources.

    publishRequest

    {
      "contents": {},
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "databaseServer": {
        "authenticationDomain": "string",
        "casServerName": "string",
        "configDir": "string",
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "credentialUri": "string",
        "databaseCasLibrary": "string",
        "databaseSchema": "string",
        "databaseType": "string",
        "description": "string",
        "hdfsDir": "string",
        "host": "string",
        "id": "string",
        "library": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "name": "string",
        "password": "string",
        "port": 0,
        "restPort": 0,
        "table": "string",
        "type": "string",
        "user": "string",
        "version": 0
      },
      "description": "string",
      "destinationName": "string",
      "modelContents": [
        {
          "astoreUri": "string",
          "code": "string",
          "codeDescription": "string",
          "codeScope": "string",
          "codeType": "string",
          "codeUri": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "format": "string",
          "formatUri": "string",
          "modelId": "string",
          "modelName": "string",
          "modelVersionId": "string",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "principalId": "string",
          "projectId": "string",
          "publishLevel": "string",
          "publishNotes": "string",
          "sourceUri": "string",
          "variableXml": "string"
        }
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "notes": "string",
      "properties": {
        "property1": "string",
        "property2": "string"
      },
      "targetServer": {
        "authenticationDomain": "string",
        "casServerName": "string",
        "configDir": "string",
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "credentialUri": "string",
        "databaseCasLibrary": "string",
        "databaseSchema": "string",
        "databaseType": "string",
        "description": "string",
        "hdfsDir": "string",
        "host": "string",
        "id": "string",
        "library": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "name": "string",
        "password": "string",
        "port": 0,
        "restPort": 0,
        "table": "string",
        "type": "string",
        "user": "string",
        "version": 0
      },
      "targetServerLibraryUri": "string",
      "targetServerName": "string",
      "targetServerPassword": "string",
      "targetServerUri": "string",
      "type": "string",
      "verified": true,
      "version": 0
    }
    
    

    Publish Request

    Properties
    Name Type Required Restrictions Description
    contents object false none contents
    createdBy string false none The user who published the models.
    creationTimeStamp string(date-time) false none The timestamp for when the models were published, in the format of 'YYYY-MM-DDThh:mm:ss.sssZ'.
    databaseServer targetServer false none Information about the target server.
    description string false none The description for the destination.
    destinationName string false none The name of the destination.
    modelContents [publishContent] false none The models to be published.
    modifiedBy string false none The user who most recently modified the publish request definition.
    modifiedTimeStamp string(date-time) false none The timestamp for when the publish request definition was last modified, in the format of 'YYYY-MM-DDThh:mm:ss.sssZ'.
    name string false none Published name
    notes string false none Notes
    properties object false none Properties
    » additionalProperties string false none none
    targetServer targetServer false none Information about the target server.
    targetServerLibraryUri string false none The URI for the target server library.
    targetServerName string false none The name of the target server.
    targetServerPassword string false none The password for the target server.
    targetServerUri string false none The URI for the target server.
    type string false none The destination type.
    verified boolean false none Indicates whether the target service has been verified.
    version integer(int32) false none This media type's schema version number.

    targetServer

    {
      "authenticationDomain": "string",
      "casServerName": "string",
      "configDir": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "credentialUri": "string",
      "databaseCasLibrary": "string",
      "databaseSchema": "string",
      "databaseType": "string",
      "description": "string",
      "hdfsDir": "string",
      "host": "string",
      "id": "string",
      "library": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "password": "string",
      "port": 0,
      "restPort": 0,
      "table": "string",
      "type": "string",
      "user": "string",
      "version": 0
    }
    
    

    Target Server

    Properties
    Name Type Required Restrictions Description
    authenticationDomain string false none The authentication domain that is used to retrieve the Teradata database or Hadoop credentials.
    casServerName string false none The name of the CAS server.
    configDir string false none The Hadoop configuration and JAR file directories. Separate the two directory pathnames with a colon (:). These names must match the names that you specified when creating the Hadoop global caslib.
    createdBy string false none The user who created the target server.
    creationTimeStamp string(date-time) false none The timestamp for when the server was created, in the format of 'YYYY-MM-DDThh:mm:ss.sssZ'.
    credentialUri string false none The URI credentials.
    databaseCasLibrary string false none The caslib that contains the external database options.
    databaseSchema string false none The connection option that names the Teradata database to use to qualify the Teradata tables.
    databaseType string false none The name of the database type (cas, hadoop, microAnalyticService, or teradata) for the target server.
    description string false none The description of the target server.
    hdfsDir string false none The root HDFS folder where the model directory is to be created.
    host string false none The host name for the server
    id string false none The identifier for the target server.
    library string false none The name of the CAS library.
    links [object] false none The links that apply to the target server.
    » Link object false none A link to a related operation or resource.
    »» method string false none The HTTP method for the link.
    »» rel string true none The relationship of the link to the resource.
    »» uri string false none The relative URI for the link.
    »» href string false none The URL for the link.
    »» title string false none The title for the link.
    »» type string false none The media type or link type for the link.
    »» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    modifiedBy string false none The user who most recently modified the server.
    modifiedTimeStamp string(date-time) false none The timestamp for when the server was last modified, in the format of 'YYYY-MM-DDThh:mm:ss.sssZ'.
    name string false none The name of the server.
    password string false none The password for the user ID that is entered.
    port integer(int32) false none The port number for the database.
    restPort integer(int32) false none The port number for REST
    table string false none The name of the CAS or Teradata model table.
    type string false none The target server type.
    user string false none The user ID that has permission to access database content.
    version integer(int32) false none This media type's schema version number.

    publishContent

    {
      "astoreUri": "string",
      "code": "string",
      "codeDescription": "string",
      "codeScope": "string",
      "codeType": "string",
      "codeUri": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "format": "string",
      "formatUri": "string",
      "modelId": "string",
      "modelName": "string",
      "modelVersionId": "string",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "principalId": "string",
      "projectId": "string",
      "publishLevel": "string",
      "publishNotes": "string",
      "sourceUri": "string",
      "variableXml": "string"
    }
    
    

    Published Model Content

    Properties
    Name Type Required Restrictions Description
    astoreUri string false none The URI point to the analytic store in the CAS library.
    code string false none The model score code.
    codeDescription string false none The description of the code.
    codeScope string false none The scope of the code.
    codeType string false none The code type can be "datastep" or "ds2".
    codeUri string false none codeUri
    createdBy string false none The user who created the published content.
    creationTimeStamp string(date-time) false none The timestamp for when the publish content was created, in the format of 'YYYY-MM-DDThh:mm:ss.sssZ'..
    format string false none The format used to determine how the values of a variable should be written or displayed.
    formatUri string false none formatUri
    modelId string false none The model ID can be used by the client to find their published model.
    modelName string false none The name of the model.
    modelVersionId string false none The model version ID.
    modifiedBy string false none The user who most recently modified the publish content.
    modifiedTimeStamp string(date-time) false none The timestamp for when the publish content was last modified, in the format of 'YYYY-MM-DDThh:mm:ss.sssZ'.
    principalId string false none The principal ID.
    projectId string false none The project ID.
    publishLevel string false none The publish level.
    publishNotes string false none The publishing notes.
    sourceUri string false none The source URI represents where the model is located.
    variableXml string false none The variables in XML format.

    workflowAssociation

    {
      "id": "string",
      "processId": "string",
      "processName": "string",
      "parentProcessId": "string",
      "objectType": "string",
      "solutionObjectId": "string",
      "solutionObjectName": "string",
      "solutionObjectUri": "string",
      "solutionObjectMediaType": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Workflow Association

    Properties
    Name Type Required Restrictions Description
    id string false none The unique identifier for the association.
    processId string false none The identifier of the workflow process.
    processName string false none The name of workflow process.
    parentProcessId string false none The identifier of the main workflow process. It is populated if the associated process is a sub-process.
    objectType string false none The type of solution object associated with the workflow process. This type is specified by the solution.
    solutionObjectId string false none The identifier of the solution object.
    solutionObjectName string false none The name of the solution object.
    solutionObjectUri string false none The URI of the solution object.
    solutionObjectMediaType string false none The media type of the solution object.
    version integer(int32) false none The version number for this media type's schema.
    links [link] false none The links that apply to the workflow association.

    workflowProcess

    {
      "id": "string",
      "parentId": "string",
      "name": "string",
      "createdTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "state": "string",
      "description": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Workflow Process

    Properties
    Name Type Required Restrictions Description
    id string false none The unique identifier of the workflow process.
    parentId string false none The identifier of the main workflow process. That is populated if this process is a sub-process.
    name string false none The name of the workflow process.
    createdTimeStamp string(date-time) false none The timestamp for when this definition revision was created, in the format of 'YYYY-MM-DDThh:mm:ss.sssZ'.
    createdBy string false none The user ID that created this workflow.
    state string false none The current processing state(In Progress
    description string false none The description of the process.
    version integer(int32) false none The version number for this media type's schema.
    links [link] false none The links that apply to the workflow process.

    workflowTask

    {
      "id": "string",
      "processId": "string",
      "processTaskId": "string",
      "name": "string",
      "definitionName": "string",
      "actualOwner": "string",
      "state": "string",
      "stateTimeStamp": "2019-08-24T14:15:22Z",
      "taskDueTimeStamp": "2019-08-24T14:15:22Z",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "associations": [
        {
          "id": "string",
          "processId": "string",
          "processName": "string",
          "parentProcessId": "string",
          "objectType": "string",
          "solutionObjectId": "string",
          "solutionObjectName": "string",
          "solutionObjectUri": "string",
          "solutionObjectMediaType": "string",
          "version": 0,
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "resourceCollection": [
        {
          "name": "string",
          "start": 0,
          "limit": 0,
          "count": 0,
          "accept": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0,
          "items": []
        }
      ]
    }
    
    

    Workflow Task

    Properties
    Name Type Required Restrictions Description
    id string false none The unique identifier of the workflow task.
    processId string false none The identifier of the associated workflow process.
    processTaskId string false none The identifier of the task in the Workflow service.
    name string false none The name of the task.
    definitionName string false none The name of the definition that defines the process.
    actualOwner string false none The user ID of the owner of the task.
    state string false none The state (Started
    stateTimeStamp string(date-time) false none The timestamp of the last state change for the task.
    taskDueTimeStamp string(date-time) false none The timestamp of when the task is due to be completed.
    creationTimeStamp string(date-time) false none The timestamp of when this definition revision was created.
    createdBy string false none The user ID that created this workflow.
    associations [workflowAssociation] false none Collection of projects that are associated with this task.
    links [link] false none The links that apply to the workflow task.
    resourceCollection [allOf] false none The array of resource representations.
    » Collection object false none A collection of zero or more resource representations. Collections are often paginated and the items array contains one page of representations.

    allOf

    Name Type Required Restrictions Description
    »» anonymous performanceTaskCollection false none 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)

    and

    Name Type Required Restrictions Description
    »» anonymous object false none none
    »»» items array false none Array consisting API resource representations, normally a page worth.

    taskPrompt

    {
      "id": "string",
      "name": "string",
      "variableType": "string",
      "variableName": "string",
      "values": [
        {
          "id": "string",
          "name": "string",
          "value": "string"
        }
      ],
      "required": "string",
      "defaultValueId": "string",
      "actualValue": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Workflow Task Prompt

    Properties
    Name Type Required Restrictions Description
    id string false none The unique identifier of the prompt.
    name string false none The name of the prompt.
    variableType string false none The type of the variable associated with the prompt.
    variableName string false none The name of the variable associated with the prompt.
    values [promptValue] false none An optional collection of values that can be set on the associated variable.
    required string false none A flag that determines whether a value must be provided for this prompt. Valid values [true, false].
    defaultValueId string false none The identifier of the prompt value, which defines the default value.
    actualValue string false none The actual value that has been specified for this prompt.
    version integer(int32) false none This media type's schema version number.
    links [link] false none The links that apply to the workflow process.

    promptValue

    {
      "id": "string",
      "name": "string",
      "value": "string"
    }
    
    

    Workflow Task Prompt Value

    Properties
    Name Type Required Restrictions Description
    id string false none The identifier of the prompt value.
    name string false none The name of the prompt value.
    value string false none The value that has been specified for this prompt.

    reportRequest

    {
      "name": "string",
      "description": "string",
      "modelUris": [
        "string"
      ]
    }
    
    

    Report Request

    Properties
    Name Type Required Restrictions Description
    name string false none The name of the report.
    description string false none The description of the report.
    modelUris [string] false none Collection of model URIs, which are used to perform a model comparison.

    uriReference

    {
      "name": "string",
      "uri": "string",
      "uriType": "string",
      "mediaType": "string",
      "contentType": "string"
    }
    
    

    URI Reference

    Properties
    Name Type Required Restrictions Description
    name string false none The name of the URI reference.
    uri string false none The value of the URI.
    uriType string false none The child or reference of the URI.
    mediaType string false none The media type of this URI.
    contentType string false none The content type that the URI points to.

    variable

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    

    Variable

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the variable.
    modifiedBy string false none The user that last modified the variable.
    creationTimeStamp string(date-time) false none The timestamp for when the variable was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string(date-time) false none The timestamp for when the variable was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    name string false none The name of the variable.
    description string false none The description of this variable.
    role string false none The role of the variable. Valid values are: input, output, target
    type string false none The type of variable. Valid values are: string, decimal, integer, boolean, date, datetime
    level string false none The measurement level of the variable. Valid values are: binary, interval, nominal, ordinal
    format string false none The format of the variable. An example is int32.
    length integer false none The length of the variable.
    version integer false none The variable representation version. The version is 2.

    modelProperty

    {
      "name": "string",
      "value": "string",
      "type": "string"
    }
    
    

    Model Property

    Properties
    Name Type Required Restrictions Description
    name string false none The name of the property.
    value string false none The value for the property.
    type string false none The data type for the property. Valid values: string, decimal, integer, date, datetime

    model

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetLevel": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    

    Model

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the model.
    modifiedBy string false none The user that last modified the model.
    creationTimeStamp string(date-time) false none The timestamp for when the model was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string(date-time) false none The timestamp for when the model was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    id string false none The unique identifier for the model.
    name string false none The name of the model.
    description string false none The description of the model.
    function string false none The function of the model. Valid values: analytical, classification, cluster, forecasting, prediction, Text analytics, transformation
    algorithm string false none The name of model algorithm.
    tool string false none The name of the model tool.
    modeler string false none This is the user that created or built the model.
    scoreCodeType string false none The score code type for the model.
    trainTable string false none The train data table.
    eventProbVar string false none The name of the event probability variable.
    targetEvent string false none The target event value.
    champion boolean false none Indicates whether the project has champion model or not.
    role string false none The role of the model. Valid values: plain, champion, challenger
    location string false none The location of this model.
    targetLevel string false none The level of the target.
    targetVariable string false none The name of the target variable.
    projectId string false none The unique identifier for the project that contains the model.
    projectName string false none The name of the project that contains the model.
    projectVersionId string false none The unique identifier for the project version that contains the model.
    projectVersionName string false none The display name of the project version that contains the model
    folderId string false none The unique identifier for the folder that contains the model
    repositoryId string false none The unique identifier for the repository that contains the model.
    championStartTime string false none The time at which the model was set as the project champion model.
    championEndTime string false none The time at which the model was unset (cleared) as the project champion model.
    suggestedChampion boolean false none Indicates the model that was suggested as the champion model at import time.
    retrainable boolean false none Indicates whether the model can be retrained or not.
    immutable boolean false none Indicates whether the model can be changed or not.
    modelVersionName string false none The display name for a model version.
    dataUris [uriReference] false none The URI reference point to an analytic report. It can have zero or multiple URI references.
    properties [modelProperty] false none The properties for the model.
    inputVariables [variable] false none The input variables for the model.
    outputVariables [variable] false none The output variables for the model.
    version integer false none The model representation version. The version is 2.

    reportResponse

    {
      "parentId": "string",
      "modelIds": [
        "string"
      ],
      "comparedModels": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetLevel": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ],
      "allInputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "allOutputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "allProperties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ]
    }
    
    

    Report Response

    Properties
    Name Type Required Restrictions Description
    parentId string false none The unique identifier of the parent project.
    modelIds [string] false none The collection of model IDs.
    comparedModels [model] false none The collection of models being compared.
    allInputVariables [variable] false none The collection of input variables.
    allOutputVariables [variable] false none The collection of output variables.
    allProperties [modelProperty] false none The collection of model properties.

    resourceCollection

    {
      "accept": "string",
      "count": 0,
      "items": [
        {}
      ],
      "limit": 0,
      "name": "string",
      "start": 0
    }
    
    

    Resource Collection

    Properties
    Name Type Required Restrictions Description
    accept string false none media type
    count integer(int64) false none The total number of items.
    items [object] false none none
    limit integer(int32) false none The maximum number of items to return in this request.
    name string false none item name
    start integer(int64) false none The 0-based start index of a paginated request. Default is 0.

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    application/vnd.sas.models.performance.task

    The application/vnd.sas.models.performance.task media type describes a performance monitor task definition.

    application/vnd.sas.models.performance.task+json

    Here is an example of the JSON representation of this media type.

    
     {
        "creationTimeStamp": "2017-08-08T20:42:28.112Z",
        "modifiedTimeStamp": "2017-08-08T20:42:28.113Z",
        "createdBy": "bob",
        "modifiedBy": "bob",
        "links": [
            {
                "method": "GET",
                "rel": "self",
                "href": "/modelManagement/performanceTasks/69ab3d14-0fc9-4873-9db7-bd89d8f74b58",
                "uri": "/modelManagement/performanceTasks/69ab3d14-0fc9-4873-9db7-bd89d8f74b58"
            }
        ],
        "version": 2,
        "id": "69ab3d14-0fc9-4873-9db7-bd89d8f74b58",
        "modelIds":["ae57f85c-8450-4361-8b36-a135bc7ed11d"],
        "outputVariables": [
            "EM_EVENTPROBABILITY"
        ],
        "inputVariables": [
            "REASON",
            "VALUE",
            "YOJ"
        ],
        "scoreExecutionRequired": false,
        "performanceResultSaved": false,
        "traceOn": false,
        "maxBins": 10,
        "resultLibrary": "ModelPerformanceData",
        "dataLibrary": "Public",
        "casServerId":"cas-shared-default",
        "dataPrefix": "hmeq_scored_"
    }
    
    application/vnd.sas.models.performance.job

    The application/vnd.sas.models.performance.job media type describes a performance monitor job.

    application/vnd.sas.models.performance.job+json

    Here is an example of the JSON representation of this media type.

    
     {
        "creationTimeStamp": "2017-10-28T20:32:38.110Z",
        "modifiedTimeStamp": "2017-10-28T20:32:38.116Z",
        "createdBy": "bob",
        "modifiedBy": "bob",
        "links": [
            {
                "method": "GET",
                "rel": "self",
                "href": "/modelManagement/performanceTasks/c38c2ea9-a49b-412a-8c27-d87038723c5e/performanceJobs/5908b2b0-d6d4-4d84-9762-2e91d5e54117",
                "uri": "/modelManagement/performanceTasks/c38c2ea9-a49b-412a-8c27-d87038723c5e/performanceJobs/5908b2b0-d6d4-4d84-9762-2e91d5e54117"
            }
        ],
        "version": 2,
        "id": "e1636c4f-37dc-4b1c-9774-3e7b1b24cd14",
        "taskId":"6f8e3b8c-be53-4a14-88a3-8e36335f7f1a",
        "task":"user score single",
        "code": "options cashost='greenrpm-6.edm.sashq-r.openstack.sas.com' casport=5570;\ncas _mmcas_;\ncaslib _all_ assign;\n%let _M.....",
        "state": "running",
        "prefix":"",
        "model":"reg1",
        "dataLibrary":"Public",
        "resultLibrary":"ModelPerformanceData",
        "modelId":"ae57f85c-8450-4361-8b36-a135bc7ed11d",
        "startTime":"2018-05-04T15:12:16.347Z",
        "stopTime":"2018-05-04T15:12:50.542Z",
        "dataTable":"HMEQ-SCORE_1_Q1",
        "projectVersion":"Version 1",
        "projectId":"ce3a3bdd-bdb0-4477-8a38-17c866eb414e",
        "jobReqId":"5908b2b0-d6d4-4d84-9762-2e91d5e53453"
    }
    
    application/vnd.sas.workflow.object.task

    The workflow object task media type describes a task that the authorized user can work on. The schema is at application/vnd.sas.workflow.object.task.

    application/vnd.sas.workflow.object.task+json
    
     {
        "creationTimeStamp": "2017-10-11T18:05:50.000Z",
        "createdBy": "bob",
        "id": "8ae8973b5eff22b9015f0c9d34300027",
        "processId": "WF221d19c8-484e-45f9-95a5-2a25a0be30d9",
        "processTaskId": "WF444c6b58-268f-4fee-af9a-2d841247e47c",
        "definitionTaskId": "WF94999806-B56B-469C-8C7B-E9E63E452B8A",
        "name": "User Task",
        "definitionName": "Model Processing Flow",
        "state": "Started",
        "stateTimeStamp": "2017-10-11T18:05:49.997Z",
        "associations": [
            {
                "solutionObjectType": "MM_Project",
                "solutionObjectName": "Project 2",
                "solutionObjectId": "891c2dc3-0e4a-4dca-9248-b8b8d3d8422a",
                "solutionObjectUri": "/modelRepository/projects/891c2dc3-0e4a-4dca-9248-b8b8d3d8422a"
            }
        ],
        "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/modelManagement/workflowTasks/8ae8973b5eff22b9015f0c9d34300027",
              "uri": "/modelManagement/workflowTasks/8ae8973b5eff22b9015f0c9d34300027"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/workflow/processes/WF221d19c8-484e-45f9-95a5-2a25a0be30d9/tasks/WF444c6b58-268f-4fee-af9a-2d841247e47c",
              "uri": "/workflow/processes/WF221d19c8-484e-45f9-95a5-2a25a0be30d9/tasks/WF444c6b58-268f-4fee-af9a-2d841247e47c"
            }
        ]
    }
    
    application/vnd.sas.workflow.object.prompt

    The workflow object prompt media type describes a prompt that is associated with a workflow task. The schema is at application/vnd.sas.workflow.object.prompt.

    application/vnd.sas.workflow.object.prompt+json
    
     {
      "id": "WFAD7ACD60-8B6B-4B58-A558-9A91B067442A",
      "name": "What is your name?",
      "variableType": "string",
      "variableName": "userName",
      "required": "false",
      "version": 0,
      "actualValue": "false",
      "links": [{
        "method": "GET",
        "rel": "self",
        "href": "/modelManagement/workflowTasks/WF9b2fe3df-6ff4-4f84-b98f-f4e26ee8349f/prompts/WFAD7ACD60-8B6B-4B58-A558-9A91B067442A",
        "uri": "/modelManagement/workflowTasks/WF9b2fe3df-6ff4-4f84-b98f-f4e26ee8349f/prompts/WFAD7ACD60-8B6B-4B58-A558-9A91B067442A",
        "type": "application/vnd.sas.workflow.object.prompt"
      },
      {
        "method": "GET",
        "rel": "up",
        "href": "/modelManagement/workflowTasks/WF9b2fe3df-6ff4-4f84-b98f-f4e26ee8349f/prompts",
        "uri": "/modelManagement/workflowTasks/WF9b2fe3df-6ff4-4f84-b98f-f4e26ee8349f/prompts",
        "type": "application/vnd.sas.collection"
      },
      {
        "method": "GET",
        "rel": "task",
        "href": "/modelManagement/workflowTasks/WF9b2fe3df-6ff4-4f84-b98f-f4e26ee8349f",
        "uri": "/modelManagement/workflowTasks/WF9b2fe3df-6ff4-4f84-b98f-f4e26ee8349f",
        "type": "application/vnd.sas.workflow.object.task"
      }]
    }
    
    application/vnd.sas.workflow.object.association

    The workflow object association media type describes an association between a workflow process and a solution object, such as model project. The schema is at application/vnd.sas.workflow.object.association.

    application/vnd.sas.workflow.object.association+json

    Here is an example of the JSON representation for this media type.

    
     {
        "creationTimeStamp": "2017-10-18T22:33:29.112Z",
        "createdBy": "bob",
        "id": "8ae8973b5eff22b9015eff3d21510019",
        "processId": "WFfcd3e296-2faa-463f-8ed0-dfd012574671",
        "processName": "Workflow_1",
        "objectType": "MM_Project",
        "solutionObjectName": "Project 2_GJC",
        "solutionObjectId": "32754f10-6a12-4a35-b8b7-03835424e257",
        "solutionObjectUri": "/modelRepository/projects/32754f10-6a12-4a35-b8b7-03835424e257",
        "links": [
            {
                "method": "GET",
                "rel": "self",
                "href": "/modelManagement/workflowAssociations/8ae8973b5eff22b9015eff3d21510019",
                "uri": "/modelManagement/workflowAssociations/8ae8973b5eff22b9015eff3d21510019"
            },
            {
                "method": "GET",
                "rel": "process",
                "href": "/modelManagement/workflowProcesses/WFfcd3e296-2faa-463f-8ed0-dfd012574671",
                "uri": "/modelManagement/workflowProcesses/WFfcd3e296-2faa-463f-8ed0-dfd012574671"
            },
            {
                "method": "GET",
                "rel": "projects",
                "href": "/modelRepository/projects/32754f10-6a12-4a35-b8b7-03835424e257",
                "uri": "/modelRepository/projects/32754f10-6a12-4a35-b8b7-03835424e257"
            }        
        ]
    }
    
    application/vnd.sas.workflow.object.process

    Provides information about a workflow process, managed by the Workflow service, that is associated with SAS Model Manager. The schema is at application/vnd.sas.workflow.object.process.

    application/vnd.sas.workflow.object.process+json

    Here is an example of the JSON representation of this media-type:

    
     {
        "id": "WF634702f1-8970-4131-aa9b-c9a64e3f6e54",
        "name": "Workflow_1",
        "createdTimeStamp": "2017-10-09T03:00:01.664Z",
        "createdBy": "bob",
        "state": "In Progress",
        "description": "",
        "links": [
            {
                "method": "GET",
                "rel": "self",
                "href": "/modelManagement/workflowProcesses/WF634702f1-8970-4131-aa9b-c9a64e3f6e54",
                "uri": "/modelManagement/workflowProcesses/WF634702f1-8970-4131-aa9b-c9a64e3f6e54"
            },
            {
                "method": "GET",
                "rel": "alternate",
                "href": "/workflow/processes/WF634702f1-8970-4131-aa9b-c9a64e3f6e54",
                "uri": "/workflow/processes/WF634702f1-8970-4131-aa9b-c9a64e3f6e54"
            }
        ]
    }
    
    application/vnd.sas.score.mapped.code

    This type is used to generate code that is mapped to specific data, based on the request.

    The codeType returned within the mappedCode depends on the score code type that is specified for the model in the Model Repository API.

    See application/vnd.sas.score.mapped.code

    application/vnd.sas.models.publishing.model

    Contains details about publishing a model to a destination server.

    The schema is at publishModel.

    application/vnd.sas.models.publishing.model+json

    Here is an example of the JSON representation of this media type.

    
     {
       "creationTimeStamp":"2017-08-18T18:34:50.173Z",
       "modifiedTimeStamp":"2017-08-18T18:34:50.173Z",
       "createdBy":"userId",
       "modifiedBy":"userId",
       "version":1,
       "id":"04d65048-78a9-441c-98df-d4aa7b014687",
       "publishName":"reg1",
       "publishType":"casModel",
       "verified":false,
       "destinationName": "casDestination",
       "codeType":"dataStep",
       "analyticStoreUri":[
         "/dataTables/dataSources/cas~fs~cas-shared-default~fs~Public/tables/HMEQ"
       ],
       "sourceUri":"/modelRepository/models/dscodeModelId/code",
       "note":"testing publish a model",
       "properties":{
          "property2":"anyValue",
          "property1":"anyValue"
       },
       "links":[
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelPublisher/models/04d65048-78a9-441c-98df-d4aa7b014687",
             "uri":"/modelPublisher/models/04d65048-78a9-441c-98df-d4aa7b014687",
             "type":"application/vnd.sas.models.publishing.model"
          }
       ]
    }
    
    application/vnd.sas.models.publishing.request.asynchronous

    Describes publishing a model to a predefined destination.

    The schema is at publishRequest.

    application/vnd.sas.models.publishing.request.asynchronous+json

    Here is an example of the JSON representation of this media type.

    which publishes models to CAS at the model level:

    
     {
      "name" : "Published model DS2EP",
      "notes" : "Publish models",
      "modelContents" : [{
          "modelName" : "DS2EP",
          "sourceUri" : "/modelRepository/models/5aff81e6-9d07-41cc-a112-efe65a1fa737",
          "publishLevel" : "model"
        }
      ],
      "destinationName" : "_CAS_PUBLIC_"
    }
    
    application/vnd.sas.models.report.comparison.request

    The model comparison request object media type that is used to generate models comparison report. The schema is at application/vnd.sas.models.report.comparison.request.

    application/vnd.sas.models.report.comparison.request+json

    Here is an example of the JSON representation for this media type.

    
     {
        "name":"compareModels",
        "description":"",
        "modelUris":[
            "/modelRepository/models/1997700c-f3f0-493b-9a7d-67a6fca07f56",
            "/modelRepository/models/65f01d3e-aa1f-45cd-8327-0391aa7e3702"
        ]
    }
    
    application/vnd.sas.models.performance.task.report.data.lift+json

    The lift media type represents a data point in the performance report. The schema is at application/vnd.sas.models.performance.task.report.data.lift.

    application/vnd.sas.models.performance.task.report.data.variable.summary+json

    The variable summary media type represents a data point in the performance report. The schema is at application/vnd.sas.models.performance.task.report.data.variable.summary.

    application/vnd.sas.models.performance.task.report.data.variable.deviation+json

    The variable deviation media type represents a data point in the performance report. The schema is at application/vnd.sas.models.performance.task.report.data.variable.deviation.

    application/vnd.sas.models.performance.task.report.data.roc+json

    The ROC media type represents a data point in the performance report. The schema is at application/vnd.sas.models.performance.task.report.data.roc.

    application/vnd.sas.models.performance.task.report.data.ks.cumulative+json

    The KS cumulative media type represents a data point in the performance report. The schema is at application/vnd.sas.models.performance.task.report.data.ks.cumulative.

    application/vnd.sas.models.performance.task.report.data.ks.statistic+json

    The KS statistic media type represents a data point in the performance report. The schema is at application/vnd.sas.models.performance.task.report.data.ks.statistic.

    application/vnd.sas.models.performance.task.report.data.mse+json

    The MSE statistic media type represents a data point in the performance report. The schema is at application/vnd.sas.models.performance.task.report.data.mse.

    application/vnd.sas.models.performance.task.report.data.gini+json

    The Gini statistic media type represents a data point in the performance report. The schema is at application/vnd.sas.models.performance.task.report.data.gini.

    Collection Resources
    Path: /performanceTasks

    This API provides collections of performance task definitions. Members of the /performanceJob collection are folders, /performanceJob/{id}.

    Path: /peformanceTasks/{taskId}/performanceJobs

    This API provides collections of performance jobs. Members of the /peformanceTasks/{taskId}/performanceJobs collection are performance jobs, /peformanceTasks/{taskId}/performanceJobs/{jobId}.

    Single Item Resources
    Path: /performanceTasks/{taskId}

    A specific performance task definition.

    Path: /performanceTasks/{taskId}/performanceJobs/{jobId}

    A specific performance job.

    Path: /performanceTasks/{taskId}/@defaultTask/performanceJobs

    This API provides a single performance job response object performanceJob.

    The performanceJob representation is application/vnd.sas.models.performance.job+json.

    The response includes the following links:

    Relation Method Description
    create POST Creates a new performance job.
    Request type: application/vnd.sas.models.performance.job+json.
    Response type: application/vnd.sas.models.performance.job+json.
    Workflow Associations
    Path: /workflowAssociations

    This API provides collections of workflow object associations.

    The association collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.workflow.object.association.

    The response includes the following links:

    Relation Method Description
    create POST Creates a new workflow association.
    Request type: application/vnd.sas.workflow.object.association.
    Response type: application/vnd.sas.workflow.object.association.
    self GET Returns the current page from the collection.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection. This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection. This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    Filtering and sorting uses the members of the workflowAssociation:

    Workflow Association
    Path: /workflowAssociations/{associationId}

    This API provides a single workflow object association.

    The workflowAssociation representation is application/vnd.sas.workflow.object.association.

    The response includes the following links:

    Relation Method Description
    self GET Returns the association by ID.
    Response type: application/vnd.sas.workflow.object.association.
    process GET Returns the workflow process that is referenced by the association.
    Response type: application/vnd.sas.workflow.process.
    object GET Returns the object that is referenced by the association.
    Response type is based on the media type of the associated object. From the user interface, it is a model project, but it can be any object in the system.
    delete DELETE Deletes the association by ID.
    Workflow Processes
    /workflowProcesses

    This API provides collections of workflow object processes that have a Client Reference ID of SAS Model Manager.

    The processes collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.workflow.object.process.

    The response includes the following links:

    Relation Method Description
    self GET Returns the current page from the collection.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection. This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection. This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    Filtering and sorting use the members of the workflowProcess:

    Workflow Process
    Path: /workflowProcesses/{processId}

    This API provides a single workflow object process.

    The workflowProcess representation is application/vnd.sas.workflow.object.process.

    The response includes the following links:

    Relation Method Description
    self GET Returns the process by ID.
    Response type: application/vnd.sas.workflow.object.process.
    alternate GET Returns the workflow process that is referenced by an association.
    Response type: application/vnd.sas.workflow.process.
    Workflow Tasks
    /workflowTasks

    This API provides collections of workflow object tasks that have a client reference ID of SAS Model Manager, and where the current user is an owner or potential owner.

    The workflowTask representation is application/vnd.sas.workflow.object.task.

    The response includes the following links:

    Relation Method Description
    self GET Returns the association by ID.
    Response type: application/vnd.sas.workflow.object.task.
    prev GET Returns the previous page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection. This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection. This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Workflow Task
    /workflowTasks/{taskId}

    This API provides a single workflow object task.

    The response includes the following links:

    Relation Method Description
    self GET Returns the task by ID.
    Response type: application/vnd.sas.workflow.object.task.
    alternate GET Returns the workflow task that is referenced by an association.
    Response type: [`application/
    Task Prompts
    /workflowTasks/{taskId}/prompts

    This API provides collections of prompts for the specified workflow task. Prompts are references to data that a user needs to provide before completing a task.

    The prompts collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.workflow.object.prompt.

    The response includes the following links:

    Relation Method Description
    self GET Returns the current page from the collection.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection. This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection. This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Task Prompt
    /workflowTasks/{taskId}/prompts/{promptId}

    This API provides a single prompt.

    The response includes the following links:

    Relation Method Description
    self GET Returns the task by ID.
    Response type: application/vnd.sas.workflow.object.prompt.
    task GET Returns the workflow task that is associated with a prompt.
    Response type: application/vnd.sas.workflow.object.task.
    up GET Returns the collection of prompts for a workflow task.
    Response type: application/vnd.sas.collection.
    Mapped Code

    Path: /models/{modelId}/mappedCode

    Responds with a fully executable program based on application/vnd.sas.score.code.generation.request, which is provided within the request.

    The mappedCode response representation is application/vnd.sas.score.mapped.code, which contains the generated code.

    Model Report
    Path: /reports

    This API provides a single report response object comparisonModel.

    The comparisonModel representation is application/vnd.sas.models.report.comparison.model.

    The response includes the following links:

    Relation Method Description
    create POST Creates a new model comparison report.
    Request type: application/vnd.sas.models.report.comparison.request.
    Response type: application/vnd.sas.models.report.comparison.model.
    Publish Models
    Path: /publish

    This API provides collections of published models.

    Default page size is 20.

    The publish collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.models.publishing.model resources. (These types apply to the response for the self, prev, next, first, and last links below.)

    The response includes the following links:

    Relation Method Description
    self GET Returns the current page from the collection.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection. This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection. This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    publishedModels POST Publishes a model to a destination server.
    Request type: application/vnd.sas.models.publishing.model.
    Response type: application/vnd.sas.models.publishing.model.

    Model Repository

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Model Repository API provides support for registering, organizing, and managing models within a common model repository.

    Usage Notes

    Overview

    The Model Repository API provides access to a common model repository and provides support for registering, organizing, and managing models.

    Here are the functions that this API provides:

    Models that are located within projects can also be monitored for performance and scored.

    The operations of the Model Repository API can be called by other APIs. Here are some examples:

    For more information, see the SAS Model Manager software product support page.

    Terminology

    champion model

    a model that is the best predictive model chosen from a pool of candidate models within a model project. A project can have only one champion model. This is the model that is selected to solve the problem in the production scoring environment.

    challenger model

    a model that is compared and assessed against the project's champion model. This provides model comparison for the purpose of selecting a better champion model in the production scoring environment. A model project can contain zero or more challenger models.

    model

    a formula or algorithm that computes outputs from inputs. An example is a predictive model that derives information about the conditional distribution of the target variables, given the input variables.

    model content

    a set of model files and metadata. The Model Repository service requires analytical models to have a score.sas source file. It can be considered as a main program in other programming languages. The score.sas code can reference other content files, either by using a SAS LIBNAME engine or filename engine.

    model input

    a set of input variables that are required by a model and are used to predict the value of one or more target variables.

    model output

    a set of output variables that are produced by a model in a data mining process. A variable that is computed from the input variables as a prediction of the value of a target variable.

    model project

    a project that contains a collection of models and is meant to solve a specific business problem. It defines available input (project input variables) that can be used to solve the business problem by providing specific output (project output variables). A model building tool, such as Model Studio can be used to create models that can solve the problem defined in the project.

    model version

    a version or snapshot of a model's contents taken at a specific point in time that includes a list of model files and metadata information. Only the latest model version is editable.

    project input

    a set of input variables that a model project provides for a modeler to use when building a model.

    project output

    a set of output variables that a model project requires a model to produce.

    project version

    a versioned container of models. A version is a sequential number that increments by plus one each time you add a new version. A project can contain multiple editable versions. A project version is used to differentiate collections of models that are meant to solve the project's problem over time-boundaries.

    repository folder

    a hierarchical container within the common model repository. It provides a way to store and organize model information, and can contain projects, models, and subfolders.

    variable

    a column in either a SAS data set or a database table.

    Error Codes

    HTTP Status Code Error Code Description
    400 21200 A table with the specified name was not found.
    409 21201 The project name or model name is already in use in the selected folder. Enter a unique name.
    400 21202 You must delete all of the projects and models within a repository before you can delete it.
    400 21203 You must specify a name.
    400 21204 The name is too long.
    409 21205 The name already exists at the same level.
    400 21206 The specified ID is not valid.
    400 21207 The model is already set as the project champion model.
    400 21208 The project output variables must be a subset of the champion model output variables.
    400 21209 You cannot set the champion model as a challenger model.
    400 21210 A model has not been set as the project champion.
    400 21211 The file is not associated with the project.
    400 21212 The value for enum is invalid.
    400 21213 No project versions exist for the project.
    400 21214 You specified values for both the projectId and the folderId parameters. You can specify only one.
    400 21215 You must specify all of the required parameters.
    400 21216 The JSON file contains invalid content.
    400 21217 An error occurred during model import. Please check the error log for details.
    400 21218 No enum constant name.
    400 21219 A model must be associated with a repository.
    400 21221 The analytic store file contains invalid content.

    Operations

    Root

    Contains the operations for the root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/modelRepository/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/modelRepository/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns a list of links to the top-level resources that are surfaced through this API.

    Example responses

    200 Response

    {
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. A list of top-level link objects was returned. Inline
    404 Not Found No root resource exists at the requested path. Check the URI for errors. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Check API availability

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/modelRepository/',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.head('https://example.com/modelRepository/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /

    Returns whether the model repository service is available.

    Example responses

    200 Response

    {
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The service is running and available. Inline
    404 Not Found No root resource exists at the requested path. Check the URI for errors. Inline
    Response Schema

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Models

    Contains operations for searching and managing models.

    Check if models exist

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/models \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.head('https://example.com/modelRepository/models', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /models

    Returns header information for a list of models that are within the common model repository. Also used to determine whether models exist.

    Parameters
    Name In Type Required Description
    name query string(sort-criteria) false A query string that allows a search by name for a model.
    parentId query string(sort-criteria) false A query string that allows a search for models in a folder or project.
    start query integer(int32) false The starting index for the first item in a page. The index is 0-based. See Pagination in REST APIsfor more information about how pagination is applied to collections.
    limit query integer(int32) false The maximum number of items to return in the request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs
    sortBy query string false The criteria for sorting the models. For more information, see Sorting in REST APIs

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelCollection

    Get a list of models

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/models', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models

    Returns a list of models that are within the common model repository.

    Parameters
    Name In Type Required Description
    name query string(sort-criteria) false A query string that allows a search by name for a model.
    parentId query string(sort-criteria) false A query string that allows a search for models in a folder or project.
    start query integer(int32) false The starting index for the first item in a page. The index is 0-based. For more information about how pagination is applied to collections, see Pagination in REST APIs.
    limit query integer(int32) false The maximum number of items to return in the request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the models. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The models were returned. modelCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Create a model

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/models \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.model' \
      -H 'Accept: application/vnd.sas.models.model'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.model',
      'Accept':'application/vnd.sas.models.model'
    };
    
    fetch('https://example.com/modelRepository/models',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.model',
      'Accept': 'application/vnd.sas.models.model'
    }
    
    r = requests.post('https://example.com/modelRepository/models', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.model"},
            "Accept": []string{"application/vnd.sas.models.model"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models

    Creates a model into a project or folder using a model JSON object.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    body body model false If the model is defined craftily, then this information is mandatory. The following fields are ignored from the input: id, createdBy, modifiedBy

    Example responses

    201 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A model was created. model
    400 Bad Request The request was invalid. errorResponse
    409 Conflict The request could not be completed due to a conflict with the current state of the resource. The model already exists. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 409

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/models/{modelId}
    201 ETag string A tag that identifies this revision of this object.

    Import models into a model project

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/models#Project \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.project.request' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    const inputBody = '{
      "name": "string",
      "description": "string",
      "function": "string",
      "externalProjectId": "string",
      "versionOption": "string",
      "modelList": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.project.request',
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models#Project',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.project.request',
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.post('https://example.com/modelRepository/models#Project', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.project.request"},
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/models#Project", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models#Project

    Imports one or more models from the project request object. The model contains project properties and a list of model links.

    Body parameter

    Parameters
    Name In Type Required Description
    body body projectRequest false none

    Example responses

    201 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The models were imported. modelCollection
    400 Bad Request The request was invalid. errorResponse
    409 Conflict The request could not be completed due to a conflict with the current state of the resource. The model already exists. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 409

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/models/{modelId}

    Import a model into a folder

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/models#CommonModel \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.model.request' \
      -H 'Accept: application/vnd.sas.models.model'
    
    
    const inputBody = '{
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "toolVersion": "string",
      "modeler": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "scoreCodeUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "trainCodeUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "targetEvent": "string",
      "nondeterministic": true,
      "dataSourceUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "dataSourceNotes": "string",
      "externalModelId": "string",
      "trainTableSummaryUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "fitStatUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "sasOptions": "string",
      "dataPlanUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "rocDataUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "liftDataUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "partitionLevels": {
        "name": "string",
        "start": 0,
        "limit": 0,
        "count": 0,
        "accept": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "version": 0,
        "items": [
          {
            "dataRole": "string",
            "value": "string"
          }
        ]
      },
      "eventLevels": {
        "name": "string",
        "start": 0,
        "limit": 0,
        "count": 0,
        "accept": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "version": 0,
        "items": [
          {
            "variableName": "string",
            "eventValue": "string"
          }
        ]
      },
      "modelTransformation": {
        "inputVariables": [
          {
            "createdBy": "string",
            "modifiedBy": "string",
            "creationTimeStamp": "2019-08-24T14:15:22Z",
            "modifiedTimeStamp": "2019-08-24T14:15:22Z",
            "name": "string",
            "description": "string",
            "role": "string",
            "type": "string",
            "level": "string",
            "format": "string",
            "length": 0,
            "version": 2
          }
        ],
        "outputVariables": [
          {
            "createdBy": "string",
            "modifiedBy": "string",
            "creationTimeStamp": "2019-08-24T14:15:22Z",
            "modifiedTimeStamp": "2019-08-24T14:15:22Z",
            "name": "string",
            "description": "string",
            "role": "string",
            "type": "string",
            "level": "string",
            "format": "string",
            "length": 0,
            "version": 2
          }
        ],
        "steps": [
          {
            "name": "string",
            "start": 0,
            "limit": 0,
            "count": 0,
            "accept": "string",
            "links": [
              {
                "method": "string",
                "rel": "string",
                "uri": "string",
                "href": "string",
                "title": "string",
                "type": "string",
                "itemType": "string",
                "responseType": "string",
                "responseItemType": "string"
              }
            ],
            "version": 0,
            "items": [
              {
                "sequence": 0,
                "type": "string",
                "stepUri": {
                  "name": "string",
                  "uri": "string",
                  "uriType": "string",
                  "mediaType": "string",
                  "contentType": "string"
                }
              }
            ]
          }
        ]
      },
      "trainInputs": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.model.request',
      'Accept':'application/vnd.sas.models.model'
    };
    
    fetch('https://example.com/modelRepository/models#CommonModel',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.model.request',
      'Accept': 'application/vnd.sas.models.model'
    }
    
    r = requests.post('https://example.com/modelRepository/models#CommonModel', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.model.request"},
            "Accept": []string{"application/vnd.sas.models.model"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/models#CommonModel", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models#CommonModel

    Imports a model into a folder within the common model repository.

    Body parameter

    Parameters
    Name In Type Required Description
    folderId query string false The unique identifier for the folder that contains the model.
    body body modelRequest false none

    Example responses

    201 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A model was imported. model
    400 Bad Request The request was invalid. errorResponse
    409 Conflict The request could not be completed due to a conflict with the current state of the resource. The model already exists. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 409

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/models/{modelId}
    201 ETag string A tag that identifies the revision of this object.

    Import a model from an SPK file

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/models#MultipartFormData?name=string&type=SPK \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: multipart/form-data' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    const inputBody = '{
      "files": "string"
    }';
    const headers = {
      'Content-Type':'multipart/form-data',
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models#MultipartFormData?name=string&type=SPK',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'multipart/form-data',
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.post('https://example.com/modelRepository/models#MultipartFormData', params={
      'name': 'string',  'type': 'SPK'
    }, headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"multipart/form-data"},
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/models#MultipartFormData", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models#MultipartFormData

    Imports a model from a SAS package (SPK) file. Select an SPK file from a local machine and then import it. The folder ID or project version ID is required. If importing a model into a folder, use folder ID. Otherwise, use project version ID.

    Body parameter

    files: string
    
    
    Parameters
    Name In Type Required Description
    name query string true The name of the model.
    type query string(sort-criteria) true The type of model. The value must be "SPK".
    folderId query string(sort-criteria) false The unique identifier for the folder. The folderId or projectVersionId parameter must be specified.
    projectVersionId query string(sort-criteria) false The unique identifier for the project version. The folderId or projectVersionId parameter must be specified.
    function query string(sort-criteria) false The function of the model.
    description query string(sort-criteria) false The description of the model.
    body body object false none
    » files body string(binary) true Select an SPK file from your local client machine.

    Example responses

    201 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The model was imported. modelCollection
    400 Bad Request The request was invalid. errorResponse
    409 Conflict The request could not be completed due to a conflict with the current state of the resource. The model already exists. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 409

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string The location of this model.
    201 ETag string A tag that identifies this revision of this object.

    Import a model through an octet stream

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/models#octetStream?name=string&type=SPK \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/octet-stream' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    const inputBody = 'string';
    const headers = {
      'Content-Type':'application/octet-stream',
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models#octetStream?name=string&type=SPK',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/octet-stream',
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.post('https://example.com/modelRepository/models#octetStream', params={
      'name': 'string',  'type': 'SPK'
    }, headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/octet-stream"},
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/models#octetStream", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models#octetStream

    Imports a model through input stream. The folder ID or project version ID is required. If the model should be imported into a folder, use the folder ID. Otherwise, use project version ID.

    Body parameter

    string
    
    
    Parameters
    Name In Type Required Description
    name query string true The model name.
    type query string(sort-criteria) true The value for type can be SPK, ZIP, or CAS.
    folderId query string(sort-criteria) false You must specify a folder ID or project version ID.
    projectVersionId query string(sort-criteria) false You must specify a folder ID or project version ID.
    projectName query string(sort-criteria) false The model is imported into this project.
    versionOption query string(sort-criteria) false This parameter indicates to create a new version, use the latest version, or use an existing version to import the model into. Valid values are NEW, LATEST, or a number.
    function query string(sort-criteria) false The function of the model.
    description query string(sort-criteria) false The description of the model.
    body body string(binary) true Select a model content from your local machine to import a model.

    Example responses

    201 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The model was imported. modelCollection
    400 Bad Request The request was invalid. errorResponse
    409 Conflict The request could not be completed due to a conflict with the current state of the resource. The model already exists. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 409

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string The location of the model.
    201 ETag string The entity tag for the model.

    Get a model

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}

    Returns the model information for the specified model ID.

    Parameters
    Name In Type Required Description
    modelId path string true none

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The model information is returned. model
    404 Not Found Not found Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.

    Check if a model exists

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/models/{modelId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model'
    }
    
    r = requests.head('https://example.com/modelRepository/models/{modelId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/models/{modelId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /models/{modelId}

    Returns the header information for the specified model ID. Also used to determine whether a model exists.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The model information was returned. model
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the model.

    Update a model

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/models/{modelId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.model' \
      -H 'Accept: application/vnd.sas.models.model' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.model',
      'Accept':'application/vnd.sas.models.model',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.model',
      'Accept': 'application/vnd.sas.models.model',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/models/{modelId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.model"},
            "Accept": []string{"application/vnd.sas.models.model"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/models/{modelId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /models/{modelId}

    Updates the model information for the model that matches the specified criteria and model ID.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    If-Match header string true Client needs to specify the previously pulled ETag as If-Matchheader.
    modelId path string true none
    body body model false If the model is defined, then this information is mandatory.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The model was updated. model
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag for the model.

    Delete a model

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/models/{modelId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/modelRepository/models/{modelId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/modelRepository/models/{modelId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/models/{modelId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /models/{modelId}

    Deletes the model with the specified ID from the model repository.

    Parameters
    Name In Type Required Description
    modelId path string true none
    Responses
    Status Meaning Description Schema
    204 No Content The model was deleted. None
    404 Not Found No model exists at the requested path for the specified model ID. None

    Get a list of model analytic stores

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/analyticStore \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/analyticStore',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/analyticStore', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/analyticStore", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/analyticStore

    Returns a list of metadata for analytic stores (application/vnd.sas.models.analytic.store) that are associated with the model. Note that this does not allow retrieval of the analytic store, only the metadata.

    Parameters
    Name In Type Required Description
    modelId path string true none

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "string",
          "uri": "string",
          "key": "string",
          "caslib": "string",
          "location": "string",
          "errorCode": "string",
          "host": "string",
          "fullPath": "string",
          "state": "string",
          "version": 1,
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The collection of analytic stores for the model was returned. The collection contains application/vnd.sas.models.analytic.store. analyticStoreCollection
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Copy analytic stores for a model

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/models/{modelId}/analyticStore \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection' \
      -H 'If-Match: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/analyticStore',
    {
      method: 'PUT',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/models/{modelId}/analyticStore', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/models/{modelId}/analyticStore", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /models/{modelId}/analyticStore

    Copies all of the analytic stores for a model to the pre-defined server location (/config/data/modelsvr/astore) that is used for integration with Event Stream Processing and others. This request invokes an asynchronous call to copy the analytic store files. Check the individual analytic store uris to get the completion state: pending, copying, success, failure. Please review the full Model Manager documentation before using. Returns a collection of application/vnd.sas.models.analytic.store.

    Parameters
    Name In Type Required Description
    If-Match header string false The client must specify the previously pulled ETag as an If-Match header.
    modelId path string true none

    Example responses

    202 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "string",
          "uri": "string",
          "key": "string",
          "caslib": "string",
          "location": "string",
          "errorCode": "string",
          "host": "string",
          "fullPath": "string",
          "state": "string",
          "version": 1,
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    202 Accepted The analytic store copy request has been accepted for processing, but the processing has not been completed. The collection contains application/vnd.sas.models.analytic.store. analyticStoreCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get an analytic store

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/analyticStore/{analyticStoreName} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.model.analytic.store'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.model.analytic.store'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/analyticStore/{analyticStoreName}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.model.analytic.store'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/analyticStore/{analyticStoreName}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.model.analytic.store"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/analyticStore/{analyticStoreName}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/analyticStore/{analyticStoreName}

    Returns the detailed metadata for an analytic store that is associated with the model.

    Parameters
    Name In Type Required Description
    modelId path string true none
    analyticStoreName path string true none

    Example responses

    200 Response

    {
      "name": "string",
      "uri": "string",
      "key": "string",
      "caslib": "string",
      "location": "string",
      "errorCode": "string",
      "host": "string",
      "fullPath": "string",
      "state": "string",
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The collection of analytic stores for the model was returned. analyticStore
    404 Not Found No model or analytic store name exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Copy an analytic store for a model

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/models/{modelId}/analyticStore/{analyticStoreName} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.model.analytic.store' \
      -H 'If-Match: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.model.analytic.store',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/analyticStore/{analyticStoreName}',
    {
      method: 'PUT',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.model.analytic.store',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/models/{modelId}/analyticStore/{analyticStoreName}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.model.analytic.store"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/models/{modelId}/analyticStore/{analyticStoreName}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /models/{modelId}/analyticStore/{analyticStoreName}

    Copy one of the analytic stores for this model to the pre-defined server location (/config/data/modelsvr/astore) that is used for integration with SAS Event Stream Processing and others. This request invokes an asynchronous call to copy the analytic store file. Access the URI again to get the completion state: pending, copying, success, or failure. Please review the SAS Model Manager documentation before using this operation.

    Parameters
    Name In Type Required Description
    If-Match header string false The client must specify the previously pulled ETag as an If-Match header.
    modelId path string true none
    analyticStoreName path string true none

    Example responses

    202 Response

    {
      "name": "string",
      "uri": "string",
      "key": "string",
      "caslib": "string",
      "location": "string",
      "errorCode": "string",
      "host": "string",
      "fullPath": "string",
      "state": "string",
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    202 Accepted The analytic store copy request has been accepted for processing, but the processing has not been completed. analyticStore
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model or analytic store name exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get model score code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/code \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/vnd.sas.models.score.code.ds2package'
    
    
    
    const headers = {
      'Accept':'text/vnd.sas.models.score.code.ds2package'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/code',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/vnd.sas.models.score.code.ds2package'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/code', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/vnd.sas.models.score.code.ds2package"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/code", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/code

    Returns the model score code for the specified model ID.

    Parameters
    Name In Type Required Description
    modelId path string true none

    Example responses

    200 Response

    "string"
    
    "string"
    
    Responses
    Status Meaning Description Schema
    200 OK The model score code was returned. string
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get model contents

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/contents \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/contents',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/contents', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/contents", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/contents

    Returns the contents of a model for the specified model ID.

    Parameters
    Name In Type Required Description
    modelId path string true none
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "modelId": "string",
          "fileUri": "string",
          "role": "string",
          "key": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The contents of the model was returned. modelContentCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Add model contents

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/models/{modelId}/contents \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/contents',
    {
      method: 'POST',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.post('https://example.com/modelRepository/models/{modelId}/contents', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/models/{modelId}/contents", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models/{modelId}/contents

    Adds the specified model contents to the model associated with the specified model ID.

    Parameters
    Name In Type Required Description
    modelId path string true none

    Example responses

    201 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "modelId": "string",
          "fileUri": "string",
          "role": "string",
          "key": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The model contents were added successfully. modelContentCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/models/{modelId}/contents
    201 ETag string A tag that identifies the revision of this object.

    Get model content metadata

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model.content'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model.content'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/contents/{contentId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model.content'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model.content"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/contents/{contentId}

    Returns the metadata information for the model content that is associated with the specified model ID and content ID.

    Parameters
    Name In Type Required Description
    modelId path string true none
    contentId path string true none

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "modelId": "string",
      "fileUri": "string",
      "role": "string",
      "key": "string",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The model content and its metadata information was returned. modelContent
    404 Not Found No model content exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the model content.

    Check if model content exists

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/models/{modelId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model.content'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model.content'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/contents/{contentId}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model.content'
    }
    
    r = requests.head('https://example.com/modelRepository/models/{modelId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model.content"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/models/{modelId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /models/{modelId}/contents/{contentId}

    Returns the metadata and header information for the model content that is associated with the specified model ID and content ID. Also used to determine whether model content exists.

    Parameters
    Name In Type Required Description
    modelId path string true none
    contentId path string true none

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "modelId": "string",
      "fileUri": "string",
      "role": "string",
      "key": "string",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The metadata information for the model content was returned. modelContent
    404 Not Found No model content exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the model content.

    Update model content metadata

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/models/{modelId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model.content' \
      -H 'If-Match: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model.content',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/contents/{contentId}',
    {
      method: 'PUT',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model.content',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/models/{modelId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model.content"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/models/{modelId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /models/{modelId}/contents/{contentId}

    Updates the metadata information for the model content that is associated with the specified model ID and content ID.

    Parameters
    Name In Type Required Description
    If-Match header string false The client must specify the previously pulled ETag as an If-Match header.
    modelId path string true none
    contentId path string true none

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "modelId": "string",
      "fileUri": "string",
      "role": "string",
      "key": "string",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The metadata information for the model content was updated. modelContent
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model or content exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag for the model content.

    Delete model content

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/models/{modelId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/contents/{contentId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/modelRepository/models/{modelId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/models/{modelId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /models/{modelId}/contents/{contentId}

    Deletes the model content that is associated with the specified model ID and content ID.

    Parameters
    Name In Type Required Description
    modelId path string true none
    contentId path string true none

    Example responses

    404 Response

    Responses
    Status Meaning Description Schema
    204 No Content The model content was deleted. None
    404 Not Found No model content exits at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get model content

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/contents/{contentId}/content \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/plain'
    
    
    
    const headers = {
      'Accept':'text/plain'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/contents/{contentId}/content',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/plain'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/contents/{contentId}/content', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/plain"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/contents/{contentId}/content", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/contents/{contentId}/content

    Returns the model content that is associated with the specified model ID and content ID.

    Parameters
    Name In Type Required Description
    modelId path string true none
    contentId path string true none

    Example responses

    404 Response

    {"message":"string","id":"string","errorCode":0,"httpStatusCode":0,"details":["string"],"remediation":"string","errors":[null],"links":[{"method":"string","rel":"string","uri":"string","href":"string","title":"string","type":"string","itemType":"string","responseType":"string","responseItemType":"string"}],"version":0}
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The model content was returned. None
    404 Not Found No model or content exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the model content.

    Update model content

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/models/{modelId}/contents/{contentId}/content \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model.content' \
      -H 'If-Match: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model.content',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/contents/{contentId}/content',
    {
      method: 'PUT',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model.content',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/models/{modelId}/contents/{contentId}/content', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model.content"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/models/{modelId}/contents/{contentId}/content", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /models/{modelId}/contents/{contentId}/content

    Updates the model content that is associated with the specified model ID and content ID.

    Parameters
    Name In Type Required Description
    If-Match header string true The entity tag obtained from the most recent ETag response header must match the current entity tag for the model content.
    modelId path string true none
    contentId path string true none

    Example responses

    400 Response

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The model content was updated. None
    400 Bad Request The request was invalid. errorResponse
    404 Not Found The model content could not be found. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag for the model content.

    Get a list of model versions

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/modelVersions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/modelVersions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/modelVersions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/modelVersions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/modelVersions

    Returns a list of model versions for the specified model ID.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "classificationEventProbabilityVariableName": "string",
          "classificationTargetEventValue": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The list of model versions was returned. modelVersionCollection
    404 Not Found The model could not be found. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Check if model versions exist

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/models/{modelId}/modelVersions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/modelVersions',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.head('https://example.com/modelRepository/models/{modelId}/modelVersions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/models/{modelId}/modelVersions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /models/{modelId}/modelVersions

    Returns the header information for the model versions that are associated with the specified model ID. Also used to determine whether model versions exist.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "classificationEventProbabilityVariableName": "string",
          "classificationTargetEventValue": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The list of model versions was returned. modelVersionCollection
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Create a model version

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/models/{modelId}/modelVersions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.model.version' \
      -H 'Accept: application/vnd.sas.models.model.version'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "classificationEventProbabilityVariableName": "string",
      "classificationTargetEventValue": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.model.version',
      'Accept':'application/vnd.sas.models.model.version'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/modelVersions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.model.version',
      'Accept': 'application/vnd.sas.models.model.version'
    }
    
    r = requests.post('https://example.com/modelRepository/models/{modelId}/modelVersions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.model.version"},
            "Accept": []string{"application/vnd.sas.models.model.version"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/models/{modelId}/modelVersions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models/{modelId}/modelVersions

    Creates a new model version for the specified model ID.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "classificationEventProbabilityVariableName": "string",
      "classificationTargetEventValue": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    modelId path string true You must specify a valid model ID.
    body body modelVersion false The new model version.

    Example responses

    201 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "classificationEventProbabilityVariableName": "string",
      "classificationTargetEventValue": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A new model version was created. modelVersion
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string The location of the model version.
    201 ETag string The entity tag for the model version.

    Get a model version

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model.version'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model.version'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model.version'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model.version"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/modelVersions/{versionId}

    Returns the model version that is associated with the specified model ID and version ID.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    versionId path string true The unique identifier for the model version.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "classificationEventProbabilityVariableName": "string",
      "classificationTargetEventValue": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The model version was returned. modelVersion
    404 Not Found No model version exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the model version.

    Get the contents of a model version

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/modelVersions/{versionId}/contents

    Returns the contents for the model version that is associated with the specified model ID and version ID. The contents of a model version includes a list of model contents and metadata information.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    versionId path string true The unique identifier for the model version.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "modelId": "string",
          "fileUri": "string",
          "role": "string",
          "key": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The contents of the model version was returned. modelContentCollection
    404 Not Found No model version exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get metadata for model version content

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents/{contentId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/modelVersions/{versionId}/contents/{contentId}

    Returns the metadata information for the model version content that is associated with the specified model ID, version ID, and content ID.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    versionId path string true The unique identifier for the model version.
    contentId path string true The unique identifier for the model version content.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "modelId": "string",
      "fileUri": "string",
      "role": "string",
      "key": "string",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The metadata information for the model version content was returned. modelContent
    404 Not Found No model version exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the model version content.

    Get model version content

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents/{contentId}/content \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/plain'
    
    
    
    const headers = {
      'Accept':'text/plain'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents/{contentId}/content',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/plain'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents/{contentId}/content', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/plain"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/modelVersions/{versionId}/contents/{contentId}/content", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/modelVersions/{versionId}/contents/{contentId}/content

    Returns the model version content that is associated with the specified model ID, version ID, and content ID.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    versionId path string true The unique identifier for the model version.
    contentId path string true The unique identifier for the model version content.

    Example responses

    404 Response

    {"message":"string","id":"string","errorCode":0,"httpStatusCode":0,"details":["string"],"remediation":"string","errors":[null],"links":[{"method":"string","rel":"string","uri":"string","href":"string","title":"string","type":"string","itemType":"string","responseType":"string","responseItemType":"string"}],"version":0}
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The model version content was returned. None
    404 Not Found No model version content exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get model variables

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/variables \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/variables',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/variables', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/variables", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/variables

    Returns the input variables and output variables that are associated with the specified model ID.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The list of model input variables and output variables was returned. variableCollection
    404 Not Found No model variables exist at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the model variable collection.

    Add model variables

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/models/{modelId}/variables \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.model.variable' \
      -H 'Accept: application/vnd.sas.models.model.variable'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.model.variable',
      'Accept':'application/vnd.sas.models.model.variable'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/variables',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.model.variable',
      'Accept': 'application/vnd.sas.models.model.variable'
    }
    
    r = requests.post('https://example.com/modelRepository/models/{modelId}/variables', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.model.variable"},
            "Accept": []string{"application/vnd.sas.models.model.variable"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/models/{modelId}/variables", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models/{modelId}/variables

    Adds one or more variables to the model that is associated with the specified model ID.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    body body variable true The representation of the variable.

    Example responses

    201 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A new model variable was created. variable
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string The location of the model variable.
    201 ETag string The entity tag for the model variable.

    Get a model variable

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/variables/{variableId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model.variable'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model.variable'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/variables/{variableId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model.variable'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/variables/{variableId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model.variable"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/variables/{variableId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/variables/{variableId}

    Returns the model variable associated with the specified model ID and variable ID.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    variableId path string true The unique identifier for the model variable.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. A model input variable or output variable was returned. variable
    404 Not Found No model variable exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the model variable.

    Update a model variable

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/models/{modelId}/variables/{variableId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.model.variable' \
      -H 'Accept: application/vnd.sas.models.model.variable' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.model.variable',
      'Accept':'application/vnd.sas.models.model.variable',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/variables/{variableId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.model.variable',
      'Accept': 'application/vnd.sas.models.model.variable',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/models/{modelId}/variables/{variableId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.model.variable"},
            "Accept": []string{"application/vnd.sas.models.model.variable"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/models/{modelId}/variables/{variableId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /models/{modelId}/variables/{variableId}

    Updates the model variable that is associated with the specified model ID and variable ID.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    If-Match header string false The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the model variable.
    modelId path string true The unique identifier for the model. You must specify a valid model ID.
    variableId path string true The unique identifier for the variable. You must specify a valid variable ID.
    body body variable false The representation of a new model variable.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The model variable was updated. variable
    400 Bad Request The request was invalid. errorResponse
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag for the model variable.

    Delete a model variable

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/models/{modelId}/variables/{variableId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/variables/{variableId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/modelRepository/models/{modelId}/variables/{variableId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/models/{modelId}/variables/{variableId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /models/{modelId}/variables/{variableId}

    Deletes the model variable associated with the specified model ID and variable ID.

    Parameters
    Name In Type Required Description
    modelId path string true none
    variableId path string true none

    Example responses

    404 Response

    Responses
    Status Meaning Description Schema
    204 No Content The model variable was deleted. None
    404 Not Found No variable exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a model's score resource files

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/{modelId}/scoreResources \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/scoreResources',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/models/{modelId}/scoreResources', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/{modelId}/scoreResources", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{modelId}/scoreResources

    Returns the model files that have a file role of score resource, which are used for scoring.

    Parameters
    Name In Type Required Description
    modelId path string true The unique identifier for the model.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "modelId": "string",
          "fileUri": "string",
          "role": "string",
          "key": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Model score resources were returned. modelContentCollection
    404 Not Found No score resource exists at the requessted path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Move the score resources to Compute server

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/models/{modelId}/scoreResources \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'If-Match: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/models/{modelId}/scoreResources',
    {
      method: 'PUT',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/models/{modelId}/scoreResources', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/models/{modelId}/scoreResources", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /models/{modelId}/scoreResources

    Moves a model's score resources to Compute server.

    Parameters
    Name In Type Required Description
    If-Match header string false The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the model variable.
    modelId path string true The unique identifier for the model.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "modelId": "string",
          "fileUri": "string",
          "role": "string",
          "key": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Model score resources were moved. modelContentCollection
    400 Bad Request The request was invalid. errorResponse
    406 Not Acceptable Score resources files cannot be moved. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. None
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 406

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag for the model variable.

    Get all model user-defined properties

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/models/userProperties \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/models/userProperties',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/models/userProperties', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/models/userProperties", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/userProperties

    Returns all distinct user-defined properties at the model-level.

    Parameters
    Name In Type Required Description
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    [
      "string"
    ]
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    Response Schema

    Projects

    Contains operations for searching and managing projects.

    Check if projects exist

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/projects \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.head('https://example.com/modelRepository/projects', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/projects", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /projects

    Returns a paginated list of header information for projects that are within the common model repository. Also used to determine whether projects exist.

    Parameters
    Name In Type Required Description
    name query string(sort-criteria) false A query string that allows a search by name to find projects.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "location": "string",
          "repositoryId": "string",
          "folderId": "string",
          "championModelName": "string",
          "candidateChampionName": "string",
          "externalProjectId": "string",
          "candidateChampionHonored": true,
          "variables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "testTable": "string",
          "scoreInputTable": "string",
          "scoreOutputTable": "string",
          "performanceTable": "string",
          "trainTable": "string",
          "targetVariable": "string",
          "targetEventValue": "string",
          "predictionVariable": "string",
          "segmentationVariable": "string",
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "challengerModels": [
            "string"
          ],
          "classTargetValues": "string",
          "targetLevel": "string",
          "eventProbabilityVariable": "string",
          "latestVersion": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelProjectCollection

    Get a list of projects

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects

    Returns a paginated list of projects that are within the common model repository.

    Parameters
    Name In Type Required Description
    name query string(sort-criteria) false A query string that allows a search by name to find projects.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "location": "string",
          "repositoryId": "string",
          "folderId": "string",
          "championModelName": "string",
          "candidateChampionName": "string",
          "externalProjectId": "string",
          "candidateChampionHonored": true,
          "variables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "testTable": "string",
          "scoreInputTable": "string",
          "scoreOutputTable": "string",
          "performanceTable": "string",
          "trainTable": "string",
          "targetVariable": "string",
          "targetEventValue": "string",
          "predictionVariable": "string",
          "segmentationVariable": "string",
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "challengerModels": [
            "string"
          ],
          "classTargetValues": "string",
          "targetLevel": "string",
          "eventProbabilityVariable": "string",
          "latestVersion": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelProjectCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Create a project

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/projects \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.project' \
      -H 'Accept: application/vnd.sas.models.project'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "location": "string",
      "repositoryId": "string",
      "folderId": "string",
      "championModelName": "string",
      "candidateChampionName": "string",
      "externalProjectId": "string",
      "candidateChampionHonored": true,
      "variables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "testTable": "string",
      "scoreInputTable": "string",
      "scoreOutputTable": "string",
      "performanceTable": "string",
      "trainTable": "string",
      "targetVariable": "string",
      "targetEventValue": "string",
      "predictionVariable": "string",
      "segmentationVariable": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "challengerModels": [
        "string"
      ],
      "classTargetValues": "string",
      "targetLevel": "string",
      "eventProbabilityVariable": "string",
      "latestVersion": "string",
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.project',
      'Accept':'application/vnd.sas.models.project'
    };
    
    fetch('https://example.com/modelRepository/projects',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.project',
      'Accept': 'application/vnd.sas.models.project'
    }
    
    r = requests.post('https://example.com/modelRepository/projects', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.project"},
            "Accept": []string{"application/vnd.sas.models.project"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/projects", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /projects

    Creates a project associated with the specified path or folder.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "location": "string",
      "repositoryId": "string",
      "folderId": "string",
      "championModelName": "string",
      "candidateChampionName": "string",
      "externalProjectId": "string",
      "candidateChampionHonored": true,
      "variables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "testTable": "string",
      "scoreInputTable": "string",
      "scoreOutputTable": "string",
      "performanceTable": "string",
      "trainTable": "string",
      "targetVariable": "string",
      "targetEventValue": "string",
      "predictionVariable": "string",
      "segmentationVariable": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "challengerModels": [
        "string"
      ],
      "classTargetValues": "string",
      "targetLevel": "string",
      "eventProbabilityVariable": "string",
      "latestVersion": "string",
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    body body modelProject false The representation of a new project.

    Example responses

    201 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "location": "string",
      "repositoryId": "string",
      "folderId": "string",
      "championModelName": "string",
      "candidateChampionName": "string",
      "externalProjectId": "string",
      "candidateChampionHonored": true,
      "variables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "testTable": "string",
      "scoreInputTable": "string",
      "scoreOutputTable": "string",
      "performanceTable": "string",
      "trainTable": "string",
      "targetVariable": "string",
      "targetEventValue": "string",
      "predictionVariable": "string",
      "segmentationVariable": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "challengerModels": [
        "string"
      ],
      "classTargetValues": "string",
      "targetLevel": "string",
      "eventProbabilityVariable": "string",
      "latestVersion": "string",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A project was created. modelProject
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/projects/{projectId}
    201 ETag string The entity tag for the project.

    Get a project

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.project'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.project'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.project'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.project"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}

    Returns the project information for the specified project ID.

    Parameters
    Name In Type Required Description
    projectId path string true none

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "location": "string",
      "repositoryId": "string",
      "folderId": "string",
      "championModelName": "string",
      "candidateChampionName": "string",
      "externalProjectId": "string",
      "candidateChampionHonored": true,
      "variables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "testTable": "string",
      "scoreInputTable": "string",
      "scoreOutputTable": "string",
      "performanceTable": "string",
      "trainTable": "string",
      "targetVariable": "string",
      "targetEventValue": "string",
      "predictionVariable": "string",
      "segmentationVariable": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "challengerModels": [
        "string"
      ],
      "classTargetValues": "string",
      "targetLevel": "string",
      "eventProbabilityVariable": "string",
      "latestVersion": "string",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project information was returned. modelProject
    404 Not Found No project exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the project.

    Update a project

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/projects/{projectId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.project' \
      -H 'Accept: application/vnd.sas.models.project' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "location": "string",
      "repositoryId": "string",
      "folderId": "string",
      "championModelName": "string",
      "candidateChampionName": "string",
      "externalProjectId": "string",
      "candidateChampionHonored": true,
      "variables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "testTable": "string",
      "scoreInputTable": "string",
      "scoreOutputTable": "string",
      "performanceTable": "string",
      "trainTable": "string",
      "targetVariable": "string",
      "targetEventValue": "string",
      "predictionVariable": "string",
      "segmentationVariable": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "challengerModels": [
        "string"
      ],
      "classTargetValues": "string",
      "targetLevel": "string",
      "eventProbabilityVariable": "string",
      "latestVersion": "string",
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.project',
      'Accept':'application/vnd.sas.models.project',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.project',
      'Accept': 'application/vnd.sas.models.project',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/projects/{projectId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.project"},
            "Accept": []string{"application/vnd.sas.models.project"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/projects/{projectId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /projects/{projectId}

    Updates the information for the project that matches the specified criteria and project ID.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "location": "string",
      "repositoryId": "string",
      "folderId": "string",
      "championModelName": "string",
      "candidateChampionName": "string",
      "externalProjectId": "string",
      "candidateChampionHonored": true,
      "variables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "testTable": "string",
      "scoreInputTable": "string",
      "scoreOutputTable": "string",
      "performanceTable": "string",
      "trainTable": "string",
      "targetVariable": "string",
      "targetEventValue": "string",
      "predictionVariable": "string",
      "segmentationVariable": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "challengerModels": [
        "string"
      ],
      "classTargetValues": "string",
      "targetLevel": "string",
      "eventProbabilityVariable": "string",
      "latestVersion": "string",
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    If-Match header string false The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the project.
    projectId path string true none
    body body modelProject false The representation of the updates for a project.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "location": "string",
      "repositoryId": "string",
      "folderId": "string",
      "championModelName": "string",
      "candidateChampionName": "string",
      "externalProjectId": "string",
      "candidateChampionHonored": true,
      "variables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "testTable": "string",
      "scoreInputTable": "string",
      "scoreOutputTable": "string",
      "performanceTable": "string",
      "trainTable": "string",
      "targetVariable": "string",
      "targetEventValue": "string",
      "predictionVariable": "string",
      "segmentationVariable": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "challengerModels": [
        "string"
      ],
      "classTargetValues": "string",
      "targetLevel": "string",
      "eventProbabilityVariable": "string",
      "latestVersion": "string",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project was updated. modelProject
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No project exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag for the project.

    Delete a project

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/projects/{projectId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/modelRepository/projects/{projectId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/projects/{projectId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /projects/{projectId}

    Deletes the project with the specified ID from the common model repository.

    Parameters
    Name In Type Required Description
    projectId path string true none

    Example responses

    404 Response

    Responses
    Status Meaning Description Schema
    204 No Content The project was deleted. None
    404 Not Found No project exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get the project champion model

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/champion \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/champion',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/champion', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/champion", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/champion

    Returns the champion model for the specified project ID. If a project champion has not been set, an error message is returned. The error message is "No model is currently set as the project champion."

    Parameters
    Name In Type Required Description
    projectId path string true none

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project champion model was returned. model
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the project champion model.

    Set a project champion model

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/projects/{projectId}/champion \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/champion',
    {
      method: 'POST',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model'
    }
    
    r = requests.post('https://example.com/modelRepository/projects/{projectId}/champion', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/projects/{projectId}/champion", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /projects/{projectId}/champion

    Sets the model role to champion for the specified project ID and model ID.

    Parameters
    Name In Type Required Description
    projectId path string true none
    modelId query string false The unique identifier for the model.

    Example responses

    201 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The model was set as the project champion. model
    400 Bad Request The request was invalid. errorResponse
    404 Not Found If there is not a champion set for the project. The error message is "No model is currently set as the project champion." If there is invalid project ID, the error message is "The project ID is not valid." Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/models/{modelId}
    201 ETag string The entity tag for the model.

    Clear a project champion model

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/projects/{projectId}/champion \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/champion',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/modelRepository/projects/{projectId}/champion', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/projects/{projectId}/champion", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /projects/{projectId}/champion

    Clears the champion model for the specified project ID.

    Parameters
    Name In Type Required Description
    projectId path string true none

    Example responses

    400 Response

    Responses
    Status Meaning Description Schema
    204 No Content The project champion model was cleared. None
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get the champion model score code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/champion/code \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/vnd.sas.models.score.code.ds2package'
    
    
    
    const headers = {
      'Accept':'text/vnd.sas.models.score.code.ds2package'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/champion/code',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/vnd.sas.models.score.code.ds2package'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/champion/code', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/vnd.sas.models.score.code.ds2package"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/champion/code", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/champion/code

    Returns the score code for the project champion model.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.

    Example responses

    200 Response

    "string"
    
    "string"
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The champion model score code was returned. string
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model score code exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the model score code.

    Get a list of challenger models

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/challengers \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/challengers',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/challengers', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/challengers", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/challengers

    Returns a list of models for the specified project ID that have a model role of challenger.

    Parameters
    Name In Type Required Description
    projectId path string true none
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The list of project challenger models was returned successfully. modelCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No challenger models exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Set a model as a challenger

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/projects/{projectId}/challengers \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.model'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.model'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/challengers',
    {
      method: 'POST',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.model'
    }
    
    r = requests.post('https://example.com/modelRepository/projects/{projectId}/challengers', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.model"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/projects/{projectId}/challengers", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /projects/{projectId}/challengers

    Sets the model role as challenger for the model that is associated with the specified project ID and model ID. A project can have no challengers, as well as one or more challengers. The challenger will be added to challengers list.

    Parameters
    Name In Type Required Description
    projectId path string true none
    modelId query string false description

    Example responses

    201 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The request succeeded. The model was set as a project challenger model. model
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No model exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/models/{modelId}
    201 ETag string The entity tag for the model.

    Clear project challenger models

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/projects/{projectId}/challengers \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/challengers',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/modelRepository/projects/{projectId}/challengers', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/projects/{projectId}/challengers", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /projects/{projectId}/challengers

    Clears the challenger models for the specified project ID.

    Parameters
    Name In Type Required Description
    projectId path string true none

    Example responses

    400 Response

    Responses
    Status Meaning Description Schema
    204 No Content The project challenger models were cleared. None
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No project challenger models exits at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Check if models exist within a project

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/projects/{projectId}/models \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/models',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.head('https://example.com/modelRepository/projects/{projectId}/models', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/projects/{projectId}/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /projects/{projectId}/models

    Returns a list of header information for models associated with the specified project ID. Also used to determine whether models exist.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    name query string(sort-criteria) false A query string that allows a search by name to find models in a project.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelCollection

    Get a list of models within a project

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/models \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/models',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/models', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/models

    Returns a list of models for the specified project ID.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    name query string(sort-criteria) false A query string that allows a search by name to find models in a project.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Check if project versions exist

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/projects/{projectId}/projectVersions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/projectVersions',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.head('https://example.com/modelRepository/projects/{projectId}/projectVersions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/projects/{projectId}/projectVersions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /projects/{projectId}/projectVersions

    Returns a list of header information for the project versions that are associated with the specified project ID. Also used to determine whether project versions exist.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    name query string(sort-criteria) false A query string that allows a search by name to find models in a project.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelProjectCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a list of project versions

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/projectVersions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/projectVersions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/projectVersions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/projectVersions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/projectVersions

    Returns a list of project versions for the specified project ID.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    name query string(sort-criteria) false A query string that allows a search by name to find models in a project.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "versionNumber": "string",
          "parentId": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelProjectVersionCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Create a project version

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/projects/{projectId}/projectVersions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.project.version' \
      -H 'Accept: application/vnd.sas.models.project.version'
    
    
    const inputBody = '{
      "id": "string",
      "name": "string",
      "description": "string",
      "parentId": "string",
      "notes": "string",
      "sourceVersionId": "string",
      "minorVersion": 0
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.project.version',
      'Accept':'application/vnd.sas.models.project.version'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/projectVersions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.project.version',
      'Accept': 'application/vnd.sas.models.project.version'
    }
    
    r = requests.post('https://example.com/modelRepository/projects/{projectId}/projectVersions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.project.version"},
            "Accept": []string{"application/vnd.sas.models.project.version"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/projects/{projectId}/projectVersions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /projects/{projectId}/projectVersions

    Creates a new project version for the specified project ID.

    Body parameter

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "parentId": "string",
      "notes": "string",
      "sourceVersionId": "string",
      "minorVersion": 0
    }
    
    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    body body versionInformation false The representation of a new project version.

    Example responses

    201 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "parentId": "string",
      "notes": "string",
      "sourceVersionId": "string",
      "minorVersion": 0
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The project version was created. versionInformation
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/projects/{projectId}/projectVersions/{versionId}
    201 ETag string The entity tag for the project version.

    Get a project version

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.project.version'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.project.version'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.project.version'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.project.version"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/projectVersions/{versionId}

    Returns the information for the project version that is associated with the specified version ID.

    Parameters
    Name In Type Required Description
    projectId path string true none
    versionId path string true none

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "parentId": "string",
      "notes": "string",
      "sourceVersionId": "string",
      "minorVersion": 0
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project version was returned. versionInformation
    404 Not Found No project version exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the project version.

    Update a project version

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.project.version' \
      -H 'Accept: application/vnd.sas.models.project.version' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "id": "string",
      "name": "string",
      "description": "string",
      "parentId": "string",
      "notes": "string",
      "sourceVersionId": "string",
      "minorVersion": 0
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.project.version',
      'Accept':'application/vnd.sas.models.project.version',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.project.version',
      'Accept': 'application/vnd.sas.models.project.version',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.project.version"},
            "Accept": []string{"application/vnd.sas.models.project.version"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /projects/{projectId}/projectVersions/{versionId}

    Updates the project version that is associated with the specified version ID.

    Body parameter

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "parentId": "string",
      "notes": "string",
      "sourceVersionId": "string",
      "minorVersion": 0
    }
    
    Parameters
    Name In Type Required Description
    If-Match header string false The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the project version.
    projectId path string true The unique identifier for the project.
    versionId path string true The unique identifier for the project version.
    body body versionInformation false The representation of the project version.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "parentId": "string",
      "notes": "string",
      "sourceVersionId": "string",
      "minorVersion": 0
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project version was updated. versionInformation
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No project version exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag of the project version.

    Delete a project version

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /projects/{projectId}/projectVersions/{versionId}

    Deletes the project version that is associated with the specified version ID.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    versionId path string true The unique identifier for the project version.

    Example responses

    404 Response

    Responses
    Status Meaning Description Schema
    204 No Content The project version was deleted. None
    404 Not Found No project exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Check if models exist within a project version

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}/models
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}/models',
    {
      method: 'HEAD'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.head('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}/models')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /projects/{projectId}/projectVersions/{versionId}/models

    Returns a list of header information for the models that are within the project version and that are associated with the specified version ID.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    versionId path string true The unique identifier for the project version.
    name query string(sort-criteria) false A query string that allows a search by name to find models in a project.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs.
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the project version.

    Get a list of models within a project version

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}/models \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}/models',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}/models', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/projectVersions/{versionId}/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/projectVersions/{versionId}/models

    Returns a list of models within the project version that is associated with the specified version ID.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    versionId path string true The unique identifier for the project version.
    name query string(sort-criteria) false A query string that allows a search by name to find models in a project.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the models. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the project version.

    Check if project variables exist

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/projects/{projectId}/variables \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/variables',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.head('https://example.com/modelRepository/projects/{projectId}/variables', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/projects/{projectId}/variables", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /projects/{projectId}/variables

    Returns the header information for the project input variables and output variables that are associated with the specified project ID. Also used to determine whether project variables exist.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    name query string(sort-criteria) false A query string that allows a search by name to find a variable in a project.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the projects. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. variableCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get project variables

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/variables \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/variables',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/variables', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/variables", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/variables

    Returns the input variables and output variables for the project that is associated with the specified project ID.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    name query string(sort-criteria) false A query string that allows a search by name to find a variable in a project.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the projects. For more information, see Filtering in REST APIs.
    sortBy query string false The criteria for sorting the projects. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. variableCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Add project variables

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/projects/{projectId}/variables \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.variable' \
      -H 'Accept: application/vnd.sas.models.variable'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.variable',
      'Accept':'application/vnd.sas.models.variable'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/variables',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.variable',
      'Accept': 'application/vnd.sas.models.variable'
    }
    
    r = requests.post('https://example.com/modelRepository/projects/{projectId}/variables', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.variable"},
            "Accept": []string{"application/vnd.sas.models.variable"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/projects/{projectId}/variables", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /projects/{projectId}/variables

    Adds one or more variables to the project that is associated with the specified project ID.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    projectId path string true none
    body body variable false The representation of the new project variable.

    Example responses

    201 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A project variable was added. variable
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/projects/{projectId}/variables/{versionId}
    201 ETag string The entity tag for the project variable.

    Get a project variable

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/variables/{variableId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.variable'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.variable'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/variables/{variableId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.variable'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/variables/{variableId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.variable"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/variables/{variableId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/variables/{variableId}

    Returns the project variable associated with the specified project ID and variable ID.

    Parameters
    Name In Type Required Description
    projectId path string true none
    variableId path string true none

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project variable was returned. variable
    404 Not Found No project variable exists at the requested path Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag of the project variable.

    Update a project variable

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/projects/{projectId}/variables/{variableId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.variable' \
      -H 'Accept: application/vnd.sas.models.variable' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.variable',
      'Accept':'application/vnd.sas.models.variable',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/variables/{variableId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.variable',
      'Accept': 'application/vnd.sas.models.variable',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/projects/{projectId}/variables/{variableId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.variable"},
            "Accept": []string{"application/vnd.sas.models.variable"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/projects/{projectId}/variables/{variableId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /projects/{projectId}/variables/{variableId}

    Updates the project variable that is associated with the specified project ID and variable ID.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    If-Match header string false The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the project variable.
    projectId path string true The unique identifier for the project.
    variableId path string true The unique identifier for the project variable.
    body body variable false The representation of the updated project variable.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project variable was updated. variable
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No project variable exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag for the project variable.

    Delete a project variable

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/projects/{projectId}/variables/{variableId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/variables/{variableId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/modelRepository/projects/{projectId}/variables/{variableId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/projects/{projectId}/variables/{variableId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /projects/{projectId}/variables/{variableId}

    Deletes the project variable associated with the specified project ID and variable ID.

    Parameters
    Name In Type Required Description
    projectId path string true none
    variableId path string true none

    Example responses

    404 Response

    Responses
    Status Meaning Description Schema
    204 No Content The project variable was deleted. None
    404 Not Found No project exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get project contents

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/contents \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/contents',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/contents', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/contents", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/contents

    Returns the project contents associated with the specified project ID. Each entry is of the media type application/vnd.sas.models.project.content.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "projectId": "string",
          "fileUri": "string",
          "role": "string",
          "key": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The contents of the project was returned. projectContentCollection

    Add project content

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/projects/{projectId}/contents \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/contents',
    {
      method: 'POST',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.post('https://example.com/modelRepository/projects/{projectId}/contents', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/projects/{projectId}/contents", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /projects/{projectId}/contents

    Adds the content to the project that is associated with the specified project ID.

    Parameters
    Name In Type Required Description
    projectId path string true none

    Example responses

    201 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "projectId": "string",
          "fileUri": "string",
          "role": "string",
          "key": "string",
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The request succeeded. The project content was added. projectContentCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No project exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelRepository/projects/{projectId}/contents
    201 ETag string The entity tag for the project contents.

    Get project content metadata

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/contents/{contentId}

    Returns the metadata information for the project content that is associated with the specified project ID and content ID.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    contentId path string true The unique identifier for the project content.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "projectId": "string",
      "fileUri": "string",
      "role": "string",
      "key": "string",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project content metadata information was returned. projectContent
    404 Not Found No project content exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the project content.

    Update project content metadata

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/projects/{projectId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json' \
      -H 'If-Match: string'
    
    
    
    const headers = {
      'Accept':'application/json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}',
    {
      method: 'PUT',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/projects/{projectId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /projects/{projectId}/contents/{contentId}

    Updates the metadata information for the project content that is associated with the specified model ID and content ID.

    Parameters
    Name In Type Required Description
    If-Match header string false The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the project content.
    projectId path string true The unique identifier for the project.
    contentId path string true The unique identifier for the project.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "projectId": "string",
      "fileUri": "string",
      "role": "string",
      "key": "string",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The metadata information for the project content was updated. projectContent
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No project or content exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag for the project content.

    Delete project contents

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/projects/{projectId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/projects/{projectId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /projects/{projectId}/contents/{contentId}

    Deletes the contents of the project that is associated with the specified project ID and content ID.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.
    contentId path string true The unique identifier for the project content.

    Example responses

    404 Response

    Responses
    Status Meaning Description Schema
    204 No Content The project contents was deleted. None
    404 Not Found No project contents exist at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get project content

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/contents/{contentId}/content \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/plain'
    
    
    
    const headers = {
      'Accept':'text/plain'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}/content',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/plain'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}/content', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/plain"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/contents/{contentId}/content", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/contents/{contentId}/content

    Returns the project content that is associated with the specified project ID and content ID.

    Parameters
    Name In Type Required Description
    projectId path string true none
    contentId path string true none

    Example responses

    404 Response

    {"message":"string","id":"string","errorCode":0,"httpStatusCode":0,"details":["string"],"remediation":"string","errors":[null],"links":[{"method":"string","rel":"string","uri":"string","href":"string","title":"string","type":"string","itemType":"string","responseType":"string","responseItemType":"string"}],"version":0}
    
    Responses
    Status Meaning Description Schema
    200 OK The project content was returned successfully. None
    404 Not Found project or content not found Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.

    Update project content

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/projects/{projectId}/contents/{contentId}/content \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json' \
      -H 'If-Match: string'
    
    
    
    const headers = {
      'Accept':'application/json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}/content',
    {
      method: 'PUT',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/projects/{projectId}/contents/{contentId}/content', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/projects/{projectId}/contents/{contentId}/content", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /projects/{projectId}/contents/{contentId}/content

    Updates the project content that is associated with the specified project ID and content ID.

    Parameters
    Name In Type Required Description
    If-Match header string true The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the project content.
    projectId path string true The unique identifier for the project.
    contentId path string true The unique identifier for the project content.

    Example responses

    400 Response

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project content was updated. None
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No project content exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag for the project content.

    Get a project's history

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/{projectId}/history \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/{projectId}/history',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/{projectId}/history', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/{projectId}/history", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/history

    Returns the project's key historical events.

    Parameters
    Name In Type Required Description
    projectId path string true The unique identifier for the project.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "action": "string",
          "user": "string",
          "dateTime": "2019-08-24",
          "projectVersion": "string",
          "attributeJson": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The project's key historical events were returned. projectHistoricalActionCollection

    Get all project user-defined properties

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/projects/userProperties \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/projects/userProperties',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/projects/userProperties', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/projects/userProperties", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/userProperties

    Returns all distinct user-defined properties on the project-level.

    Parameters
    Name In Type Required Description
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.

    Example responses

    200 Response

    [
      "string"
    ]
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    Response Schema

    Repositories

    Contains operations for searching and managing repositories.

    Check if repositories exist

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelRepository/repositories \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/repositories',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.head('https://example.com/modelRepository/repositories', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelRepository/repositories", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /repositories

    Returns a list of header information for repositories. Also used to determine whether repositories exist.

    Parameters
    Name In Type Required Description
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the repository. For more information, see Filtering in REST APIs. For example, ?filter=eq(name, a repository name) returns the repository by name.
    sortBy query string false The criteria for sorting the models. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "folderId": "string",
          "defaultRepository": true,
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelRepositoryCollection

    Get a list of repositories

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/repositories \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelRepository/repositories',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelRepository/repositories', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/repositories", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /repositories

    Returns a paginated list of repositories.

    Parameters
    Name In Type Required Description
    start query integer(int32) false The 0-based start index of a paginated request.
    limit query integer(int32) false The maximum number of items to return in this request.
    filter query string(filter-criteria) false The criteria for filtering the repository. For more information, see Filtering in REST APIs. For example, ?filter=eq(name, a repository name) returns the repository by name.
    sortBy query string false The criteria for sorting the models. For more information, see Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "folderId": "string",
          "defaultRepository": true,
          "version": 2
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. modelRepositoryCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Create a repository

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelRepository/repositories \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.repository' \
      -H 'Accept: application/vnd.sas.models.repository'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "folderId": "string",
      "defaultRepository": true,
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.repository',
      'Accept':'application/vnd.sas.models.repository'
    };
    
    fetch('https://example.com/modelRepository/repositories',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.repository',
      'Accept': 'application/vnd.sas.models.repository'
    }
    
    r = requests.post('https://example.com/modelRepository/repositories', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.repository"},
            "Accept": []string{"application/vnd.sas.models.repository"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelRepository/repositories", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /repositories

    Creates a new repository. The Model Repository service supports multiple repositories to manage models.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "folderId": "string",
      "defaultRepository": true,
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    body body modelRepository false The representation of a new model repository.

    Example responses

    201 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "folderId": "string",
      "defaultRepository": true,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The request has been fulfilled and resulted in a new resource being created. modelRepository
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string For example: /modelRepository/repositories/{id}
    201 ETag string A tag that identifies the revision of this object.

    Get a repository

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelRepository/repositories/{repositoryId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.repository'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.repository'
    };
    
    fetch('https://example.com/modelRepository/repositories/{repositoryId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.repository'
    }
    
    r = requests.get('https://example.com/modelRepository/repositories/{repositoryId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.repository"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelRepository/repositories/{repositoryId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /repositories/{repositoryId}

    Returns the repository information for the specified repository ID.

    Parameters
    Name In Type Required Description
    repositoryId path string true none

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "folderId": "string",
      "defaultRepository": true,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The repository information was returned. modelRepository
    404 Not Found No repository exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.

    Update a repository

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelRepository/repositories/{repositoryId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.repository' \
      -H 'Accept: application/vnd.sas.models.repository' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "folderId": "string",
      "defaultRepository": true,
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.repository',
      'Accept':'application/vnd.sas.models.repository',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelRepository/repositories/{repositoryId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.repository',
      'Accept': 'application/vnd.sas.models.repository',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelRepository/repositories/{repositoryId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.repository"},
            "Accept": []string{"application/vnd.sas.models.repository"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelRepository/repositories/{repositoryId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /repositories/{repositoryId}

    Updates the repository information for the specified repository ID. This information includes the name and description of the repository.

    Body parameter

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "folderId": "string",
      "defaultRepository": true,
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    If-Match header string false The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the repository.
    repositoryId path string true The unique identifier for the repository.
    body body modelRepository false The representation of the updates for the model repository.

    Example responses

    200 Response

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "folderId": "string",
      "defaultRepository": true,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The repository was updated. modelRepository
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No repository exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or If-Unmodified-Since precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string The entity tag of the repository.

    Delete a repository

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelRepository/repositories/{repositoryId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/modelRepository/repositories/{repositoryId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/modelRepository/repositories/{repositoryId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelRepository/repositories/{repositoryId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /repositories/{repositoryId}

    Deletes the repository with the specified repository ID.

    Parameters
    Name In Type Required Description
    repositoryId path string true none

    Example responses

    404 Response

    Responses
    Status Meaning Description Schema
    204 No Content The repository was deleted. None
    404 Not Found No repository exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1json/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1json/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Schemas

    modelProjectCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "location": "string",
          "repositoryId": "string",
          "folderId": "string",
          "championModelName": "string",
          "candidateChampionName": "string",
          "externalProjectId": "string",
          "candidateChampionHonored": true,
          "variables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "testTable": "string",
          "scoreInputTable": "string",
          "scoreOutputTable": "string",
          "performanceTable": "string",
          "trainTable": "string",
          "targetVariable": "string",
          "targetEventValue": "string",
          "predictionVariable": "string",
          "segmentationVariable": "string",
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "challengerModels": [
            "string"
          ],
          "classTargetValues": "string",
          "targetLevel": "string",
          "eventProbabilityVariable": "string",
          "latestVersion": "string",
          "version": 2
        }
      ]
    }
    
    

    Model Project Collection

    Properties
    Name Type Required Restrictions Description
    Model Project Collection any false none A collection of project representations.

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [link] false none The links that apply to the collection.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [modelProject] false none An array of project representations.

    modelProject

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "location": "string",
      "repositoryId": "string",
      "folderId": "string",
      "championModelName": "string",
      "candidateChampionName": "string",
      "externalProjectId": "string",
      "candidateChampionHonored": true,
      "variables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "testTable": "string",
      "scoreInputTable": "string",
      "scoreOutputTable": "string",
      "performanceTable": "string",
      "trainTable": "string",
      "targetVariable": "string",
      "targetEventValue": "string",
      "predictionVariable": "string",
      "segmentationVariable": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "challengerModels": [
        "string"
      ],
      "classTargetValues": "string",
      "targetLevel": "string",
      "eventProbabilityVariable": "string",
      "latestVersion": "string",
      "version": 2
    }
    
    

    Model Project

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the project.
    modifiedBy string false none The user that last modified the project.
    creationTimeStamp string(date-time) false none The timestamp for when the project was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string(date-time) false none The timestamp for when the project was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    id string false none The unique identifier for the project.
    name string false none The name of the project.
    description string false none The description of the project.
    function string false none The model function of the project. Valid values: analytical, classification, cluster, forecasting, prediction, Text categorization, Text extraction, Text sentiment, Text topics, transformation
    location string false none The location of the project.
    repositoryId string false none The repository ID for the repository that contains the project.
    folderId string false none The project folder ID
    championModelName string false none The name of the champion model.
    candidateChampionName string false none The name of the candidate champion model.
    externalProjectId string false none The identifier for the external project.
    candidateChampionHonored boolean false none Indicates to set the candidate champion as the project champion during import.
    variables [variable] false none none
    testTable string false none The data table for testing.
    scoreInputTable string false none The score input data table.
    scoreOutputTable string false none The score output data table.
    performanceTable string false none The model performance data table.
    trainTable string false none The model train table.
    targetVariable string false none The name of the target variable.
    targetEventValue string false none The target event value.
    predictionVariable string false none The name of the prediction variable.
    segmentationVariable string false none The name of the segmentation variable.
    properties [modelProperty] false none none
    challengerModels [string] false none A list of challenger models.
    classTargetValues string false none A list of target values.
    targetLevel string false none Indicates a class target level of binary, nominal, ordinal, or interval.
    eventProbabilityVariable string false none The name of the event probability variable.
    latestVersion string false none The latest project version in the project.
    version integer false none The project representation version. The version is 2.

    modelProjectVersionCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "versionNumber": "string",
          "parentId": "string",
          "version": 2
        }
      ]
    }
    
    

    Project Version Collection

    Properties
    Name Type Required Restrictions Description
    Project Version Collection any false none A collection of project version representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [modelProjectVersion] false none The array of project version representations.

    projectContentCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "projectId": "string",
          "fileUri": "string",
          "role": "string",
          "key": "string",
          "version": 2
        }
      ]
    }
    
    

    Project File Collection

    Properties
    Name Type Required Restrictions Description
    Project File Collection any false none A collection of model content representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [projectContent] false none The array of application/vnd.sas.projects.project.content representations.

    modelProjectVersion

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "versionNumber": "string",
      "parentId": "string",
      "version": 2
    }
    
    

    Project Version

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the project version.
    modifiedBy string false none The user that last modified the project version.
    creationTimeStamp string(date-time) false none The timestamp for when the project version was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string(date-time) false none The timestamp for when the project version was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    id string false none The unique identifier for the project version.
    name string false none The name of the project version.
    description string false none The description for the project version.
    versionNumber string false none The version number for the project version.
    parentId string false none The unique identifier for the parent project.
    version integer false none The project version representation version. The version is 2.

    projectRequest

    {
      "name": "string",
      "description": "string",
      "function": "string",
      "externalProjectId": "string",
      "versionOption": "string",
      "modelList": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 2
    }
    
    

    Project Request

    Properties
    Name Type Required Restrictions Description
    name string false none The name of the project.
    description string false none The description of the project.
    function string false none The model function from the project. Valid values are: classification, prediction, segmentation, and unknown
    externalProjectId string false none The external project ID. This is a reference to an external client project.
    versionOption string false none Import a model into a specific version. The options are: new, latest, or an existing version.
    modelList [object] false none none
    » Link object false none A link to a related operation or resource.
    »» method string false none The HTTP method for the link.
    »» rel string true none The relationship of the link to the resource.
    »» uri string false none The relative URI for the link.
    »» href string false none The URL for the link.
    »» title string false none The title for the link.
    »» type string false none The media type or link type for the link.
    »» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    version integer false none The project request representation version. The version is 2.

    projectContent

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "projectId": "string",
      "fileUri": "string",
      "role": "string",
      "key": "string",
      "version": 2
    }
    
    

    Project Content

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the project content.
    modifiedBy string false none The user that last modified the project content.
    creationTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the project content was created.
    modifiedTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the content was last modified.
    name string false none The name of the project content.
    projectId string false none The unique identifier for the project that the project content is associated with.
    fileUri string false none The URI for the project content.
    role string false none The project content role to determine how the project content should be displayed or processed.
    key string false none The key is the sha1 key for only the analytic store file.
    version integer false none The project content representation version. The version is 2.

    modelProperty

    {
      "name": "string",
      "value": "string",
      "type": "string"
    }
    
    

    Model Property

    Properties
    Name Type Required Restrictions Description
    name string false none The name of the property.
    value string false none The value for the property.
    type string false none The data type for the property. Valid values: string, decimal, integer, date, datetime

    variableCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ]
    }
    
    

    Variable Collection

    Properties
    Name Type Required Restrictions Description
    Variable Collection any false none A collection of variable representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [variable] false none The array of application/vnd.sas.models.variable representations.

    variable

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "description": "string",
      "role": "string",
      "type": "string",
      "level": "string",
      "format": "string",
      "length": 0,
      "version": 2
    }
    
    

    Variable

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the variable.
    modifiedBy string false none The user that last modified the variable.
    creationTimeStamp string(date-time) false none The timestamp for when the variable was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string(date-time) false none The timestamp for when the variable was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    name string false none The name of the variable.
    description string false none The description of this variable.
    role string false none The role of the variable. Valid values are: input, output, target
    type string false none The type of variable. Valid values are: string, decimal, integer, boolean, date, datetime
    level string false none The measurement level of the variable. Valid values are: binary, interval, nominal, ordinal
    format string false none The format of the variable. An example is int32.
    length integer false none The length of the variable.
    version integer false none The variable representation version. The version is 2.

    projectHistoricalActionCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "action": "string",
          "user": "string",
          "dateTime": "2019-08-24",
          "projectVersion": "string",
          "attributeJson": "string"
        }
      ]
    }
    
    

    Project Historical Action Collection

    Properties
    Name Type Required Restrictions Description
    Project Historical Action Collection any false none A collection of historical action representations for a project.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [projectHistory] false none The array of historical event representations.

    projectHistory

    {
      "action": "string",
      "user": "string",
      "dateTime": "2019-08-24",
      "projectVersion": "string",
      "attributeJson": "string"
    }
    
    

    Historical Action

    Properties
    Name Type Required Restrictions Description
    action string false none The name of the action.
    user string false none The user who performed the action.
    dateTime string(date) false none When the action is performed.
    projectVersion string false none The name of the project version.
    attributeJson string false none Attribute information in JSON format.

    modelContentCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "modelId": "string",
          "fileUri": "string",
          "role": "string",
          "key": "string",
          "version": 2
        }
      ]
    }
    
    

    Model Content Collection

    Properties
    Name Type Required Restrictions Description
    Model Content Collection any false none A collection of model content representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [modelContent] false none The array of application/vnd.sas.models.model.content representations.

    modelContent

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "modelId": "string",
      "fileUri": "string",
      "role": "string",
      "key": "string",
      "version": 2
    }
    
    

    Model Content

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the model content.
    modifiedBy string false none The user that last modified the model content.
    creationTimeStamp string(date-time) false none The timestamp for when the model content was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string(date-time) false none The timestamp for when the model content was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    name string false none The name of the model content.
    modelId string false none The unique identifier for the model that the model content is associated with.
    fileUri string false none The URI for the model content.
    role string false none The role to determine how the model content should be displayed or processed.
    key string false none The key is the sha1 key for only the analytic store file.
    version integer false none The model content representation version. The version is 2.

    modelCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "eventProbVar": "string",
          "targetEvent": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "dataUris": [
            {
              "name": "string",
              "uri": "string",
              "uriType": "string",
              "mediaType": "string",
              "contentType": "string"
            }
          ],
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    

    Model Collection

    Properties
    Name Type Required Restrictions Description
    Model Collection any false none A collection of model representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [model] false none An array of model representations.

    model

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "eventProbVar": "string",
      "targetEvent": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    

    Model

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the model.
    modifiedBy string false none The user that last modified the model.
    creationTimeStamp string(date-time) false none The timestamp for when the model was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string(date-time) false none The timestamp for when the model was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    id string false none The unique identifier for the model.
    name string false none The name of the model.
    description string false none The description of the model.
    function string false none The function of the model. Valid values: analytical, classification, cluster, forecasting, prediction, Text analytics, transformation
    algorithm string false none The name of model algorithm.
    tool string false none The name of the model tool.
    modeler string false none This is the user that created or built the model.
    scoreCodeType string false none The score code type for the model.
    trainTable string false none The train data table.
    eventProbVar string false none The name of the event probability variable.
    targetEvent string false none The target event value.
    champion boolean false none Indicates whether the project has champion model or not.
    role string false none The role of the model. Valid values: plain, champion, challenger
    location string false none The location of this model.
    targetVariable string false none The name of the target variable.
    projectId string false none The unique identifier for the project that contains the model.
    projectName string false none The name of the project that contains the model.
    projectVersionId string false none The unique identifier for the project version that contains the model.
    projectVersionName string false none The display name of the project version that contains the model
    folderId string false none The unique identifier for the folder that contains the model
    repositoryId string false none The unique identifier for the repository that contains the model.
    championStartTime string false none The time at which the model was set as the project champion model.
    championEndTime string false none The time at which the model was unset (cleared) as the project champion model.
    suggestedChampion boolean false none Indicates the model that was suggested as the champion model at import time.
    retrainable boolean false none Indicates whether the model can be retrained or not.
    immutable boolean false none Indicates whether the model can be changed or not.
    modelVersionName string false none The display name for a model version.
    dataUris [uriReference] false none The URI reference point to a analytic report. It can have zero or multiple URI references.
    properties [modelProperty] false none none
    inputVariables [variable] false none none
    outputVariables [variable] false none none
    version integer false none The model representation version. The version is 2.

    modelVersionCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "function": "string",
          "algorithm": "string",
          "tool": "string",
          "modeler": "string",
          "scoreCodeType": "string",
          "trainTable": "string",
          "classificationEventProbabilityVariableName": "string",
          "classificationTargetEventValue": "string",
          "champion": true,
          "role": "string",
          "location": "string",
          "targetVariable": "string",
          "projectId": "string",
          "projectName": "string",
          "projectVersionId": "string",
          "projectVersionName": "string",
          "folderId": "string",
          "repositoryId": "string",
          "championStartTime": "string",
          "championEndTime": "string",
          "suggestedChampion": true,
          "retrainable": true,
          "immutable": true,
          "modelVersionName": "string",
          "properties": [
            {
              "name": "string",
              "value": "string",
              "type": "string"
            }
          ],
          "inputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "outputVariables": [
            {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "name": "string",
              "description": "string",
              "role": "string",
              "type": "string",
              "level": "string",
              "format": "string",
              "length": 0,
              "version": 2
            }
          ],
          "version": 2
        }
      ]
    }
    
    

    Model Version Collection

    Properties
    Name Type Required Restrictions Description
    Model Version Collection any false none A collection of model version representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [modelVersion] false none The array of application/vnd.sas.models.model.version representations.

    modelVersion

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "modeler": "string",
      "scoreCodeType": "string",
      "trainTable": "string",
      "classificationEventProbabilityVariableName": "string",
      "classificationTargetEventValue": "string",
      "champion": true,
      "role": "string",
      "location": "string",
      "targetVariable": "string",
      "projectId": "string",
      "projectName": "string",
      "projectVersionId": "string",
      "projectVersionName": "string",
      "folderId": "string",
      "repositoryId": "string",
      "championStartTime": "string",
      "championEndTime": "string",
      "suggestedChampion": true,
      "retrainable": true,
      "immutable": true,
      "modelVersionName": "string",
      "properties": [
        {
          "name": "string",
          "value": "string",
          "type": "string"
        }
      ],
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    

    Model Version

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the model.
    modifiedBy string false none The user that last modified the model.
    creationTimeStamp string(date-time) false none The timestamp for when the model version was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string(date-time) false none The timestamp for when the model version was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    id string false none Model ID
    name string false none The name of the model.
    description string false none The description of this model.
    function string false none The function of the model. Valid values are: classification, prediction, segmentation, unknown
    algorithm string false none The name of model algorithm.
    tool string false none The tool name that was used to create the model.
    modeler string false none The user that created or built the model.
    scoreCodeType string false none The score code type of the model.
    trainTable string false none The name of the train data table.
    classificationEventProbabilityVariableName string false none The name of the classification event probability variable.
    classificationTargetEventValue string false none The classification target event value.
    champion boolean false none Indicates whether the project has a champion model or not.
    role string false none The role of a model. Valid values are: plain, champion, challenger
    location string false none The location of this model.
    targetVariable string false none The name of the target variable.
    projectId string false none The unique identifier for the project that contains the model.
    projectName string false none The project name for the project that contains the model.
    projectVersionId string false none The project version ID for the project version that contains the model
    projectVersionName string false none The project version display name for the project version that contains the model
    folderId string false none The folder ID for the folder that contains the model
    repositoryId string false none The repository ID for the repository that contains the model.
    championStartTime string false none The time at which the model was set as the project champion model.
    championEndTime string false none The time at which the model was unset (cleared) as the project champion model.
    suggestedChampion boolean false none Indicates that the model was the suggested champion model at import time.
    retrainable boolean false none Indicates whether the model can be retrained or not.
    immutable boolean false none Indicates whether the model can be changed or not.
    modelVersionName string false none The model version display name.
    properties [modelProperty] false none none
    inputVariables [variable] false none none
    outputVariables [variable] false none none
    version integer false none The model version representation version. The version is 2.

    modelRequest

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "function": "string",
      "algorithm": "string",
      "tool": "string",
      "toolVersion": "string",
      "modeler": "string",
      "dataUris": [
        {
          "name": "string",
          "uri": "string",
          "uriType": "string",
          "mediaType": "string",
          "contentType": "string"
        }
      ],
      "scoreCodeUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "trainCodeUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "targetEvent": "string",
      "nondeterministic": true,
      "dataSourceUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "dataSourceNotes": "string",
      "externalModelId": "string",
      "trainTableSummaryUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "fitStatUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "sasOptions": "string",
      "dataPlanUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "rocDataUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "liftDataUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      },
      "partitionLevels": {
        "name": "string",
        "start": 0,
        "limit": 0,
        "count": 0,
        "accept": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "version": 0,
        "items": [
          {
            "dataRole": "string",
            "value": "string"
          }
        ]
      },
      "eventLevels": {
        "name": "string",
        "start": 0,
        "limit": 0,
        "count": 0,
        "accept": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "version": 0,
        "items": [
          {
            "variableName": "string",
            "eventValue": "string"
          }
        ]
      },
      "modelTransformation": {
        "inputVariables": [
          {
            "createdBy": "string",
            "modifiedBy": "string",
            "creationTimeStamp": "2019-08-24T14:15:22Z",
            "modifiedTimeStamp": "2019-08-24T14:15:22Z",
            "name": "string",
            "description": "string",
            "role": "string",
            "type": "string",
            "level": "string",
            "format": "string",
            "length": 0,
            "version": 2
          }
        ],
        "outputVariables": [
          {
            "createdBy": "string",
            "modifiedBy": "string",
            "creationTimeStamp": "2019-08-24T14:15:22Z",
            "modifiedTimeStamp": "2019-08-24T14:15:22Z",
            "name": "string",
            "description": "string",
            "role": "string",
            "type": "string",
            "level": "string",
            "format": "string",
            "length": 0,
            "version": 2
          }
        ],
        "steps": [
          {
            "name": "string",
            "start": 0,
            "limit": 0,
            "count": 0,
            "accept": "string",
            "links": [
              {
                "method": "string",
                "rel": "string",
                "uri": "string",
                "href": "string",
                "title": "string",
                "type": "string",
                "itemType": "string",
                "responseType": "string",
                "responseItemType": "string"
              }
            ],
            "version": 0,
            "items": [
              {
                "sequence": 0,
                "type": "string",
                "stepUri": {
                  "name": "string",
                  "uri": "string",
                  "uriType": "string",
                  "mediaType": "string",
                  "contentType": "string"
                }
              }
            ]
          }
        ]
      },
      "trainInputs": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "version": 2
    }
    
    

    Model Request

    Properties
    Name Type Required Restrictions Description
    id string false none The unique identifier for the model.
    name string false none The name of the model.
    description string false none The description of the model.
    function string false none The function of the model. Valid values are: classification, prediction, segmentation, unknown
    algorithm string false none The name of model algorithm.
    tool string false none The name of the tool that was used to create the model.
    toolVersion string false none The version of the tool that was used to create the model.
    modeler string false none The user that created the model.
    dataUris [uriReference] false none The URI reference point to a analytic report. It can have zero or multiple UI references.
    scoreCodeUri uriReference false none none
    trainCodeUri uriReference false none none
    targetEvent string false none The target event.
    nondeterministic boolean false none nondeterministic
    dataSourceUri uriReference false none none
    dataSourceNotes string false none Additional data source information. This property can contain an intermediate data table.
    externalModelId string false none The external model ID.
    trainTableSummaryUri uriReference false none none
    fitStatUri uriReference false none none
    sasOptions string false none Additional SAS options for this model.
    dataPlanUri uriReference false none none
    rocDataUri uriReference false none none
    liftDataUri uriReference false none none
    partitionLevels partitionLevelCollection false none A collection of partition level representations.
    eventLevels eventLevelCollection false none A collection of partition level representations.
    modelTransformation modelTransformation false none none
    trainInputs [variable] false none The training input variables.
    version integer false none The model request representation version. The version is 2.

    modelTransformation

    {
      "inputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "outputVariables": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "name": "string",
          "description": "string",
          "role": "string",
          "type": "string",
          "level": "string",
          "format": "string",
          "length": 0,
          "version": 2
        }
      ],
      "steps": [
        {
          "name": "string",
          "start": 0,
          "limit": 0,
          "count": 0,
          "accept": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0,
          "items": [
            {
              "sequence": 0,
              "type": "string",
              "stepUri": {
                "name": "string",
                "uri": "string",
                "uriType": "string",
                "mediaType": "string",
                "contentType": "string"
              }
            }
          ]
        }
      ]
    }
    
    

    Model Transformation

    Properties
    Name Type Required Restrictions Description
    inputVariables [variable] false none A list of the input variables.
    outputVariables [variable] false none A list of the output variables.
    steps [stepCollection] false none A collection of transformation steps.

    stepCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "sequence": 0,
          "type": "string",
          "stepUri": {
            "name": "string",
            "uri": "string",
            "uriType": "string",
            "mediaType": "string",
            "contentType": "string"
          }
        }
      ]
    }
    
    

    Step Collection

    Properties
    Name Type Required Restrictions Description
    Step Collection any false none A collection of step representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [step] false none The array of step representations of visual analytic transformation.

    step

    {
      "sequence": 0,
      "type": "string",
      "stepUri": {
        "name": "string",
        "uri": "string",
        "uriType": "string",
        "mediaType": "string",
        "contentType": "string"
      }
    }
    
    

    Step

    Properties
    Name Type Required Restrictions Description
    sequence integer false none The step's order number.
    type string false none The content type (for example, dataStep).
    stepUri uriReference false none none

    partitionLevelCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "dataRole": "string",
          "value": "string"
        }
      ]
    }
    
    

    Partition Level Collection

    Properties
    Name Type Required Restrictions Description
    Partition Level Collection any false none A collection of partition level representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [partitionLevel] false none The array of partition level representations.

    partitionLevel

    {
      "dataRole": "string",
      "value": "string"
    }
    
    

    Partition Level

    Properties
    Name Type Required Restrictions Description
    dataRole string false none The data role.
    value string false none The value of the data role.

    eventLevelCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "variableName": "string",
          "eventValue": "string"
        }
      ]
    }
    
    

    Event Level Collection

    Properties
    Name Type Required Restrictions Description
    Event Level Collection any false none A collection of partition level representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [eventLevel] false none The array of event level representations.

    eventLevel

    {
      "variableName": "string",
      "eventValue": "string"
    }
    
    

    Event Level

    Properties
    Name Type Required Restrictions Description
    variableName string false none The variable name.
    eventValue string false none The value of the event.

    uriReference

    {
      "name": "string",
      "uri": "string",
      "uriType": "string",
      "mediaType": "string",
      "contentType": "string"
    }
    
    

    URI Reference

    Properties
    Name Type Required Restrictions Description
    name string false none The name of the URI reference.
    uri string false none The value of the URI.
    uriType string false none The child or reference of the URI.
    mediaType string false none The media type of this URI.
    contentType string false none The content type that the URI points to.

    modelRepositoryCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "createdBy": "string",
          "modifiedBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "id": "string",
          "name": "string",
          "description": "string",
          "folderId": "string",
          "defaultRepository": true,
          "version": 2
        }
      ]
    }
    
    

    Model Repository Collection

    Properties
    Name Type Required Restrictions Description
    Model Repository Collection any false none A collection of model repository representations.

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [modelRepository] false none The array of application/vnd.sas.models.repository representations.

    modelRepository

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "folderId": "string",
      "defaultRepository": true,
      "version": 2
    }
    
    

    Model Repository

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user that created the repository.
    modifiedBy string false none The user that last modified the repository.
    creationTimeStamp string(date-time) false none The timestamp for when the repository was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string(date-time) false none The timestamp for when the repository was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    id string false none The repository ID.
    name string false none The repository name.
    description string false none The description of the repository.
    folderId string false none The folder that is associated with the repository.
    defaultRepository boolean false none Indicates whether the repository is a default repository or not.
    version integer false none The repository representation version. The version is 2.

    versionInformation

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "parentId": "string",
      "notes": "string",
      "sourceVersionId": "string",
      "minorVersion": 0
    }
    
    

    Version Information

    Properties
    Name Type Required Restrictions Description
    id string false none The unique identifier for the project version.
    name string false none The name of the project version.
    description string false none The description of the project version.
    parentId string false none The identifier for the parent folder or project.
    notes string false none The additional notes about the version.
    sourceVersionId string false none The identifier for the original source version.
    minorVersion integer false none The minor version number.

    analyticStore

    {
      "name": "string",
      "uri": "string",
      "key": "string",
      "caslib": "string",
      "location": "string",
      "errorCode": "string",
      "host": "string",
      "fullPath": "string",
      "state": "string",
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Analytic Store

    Properties
    Name Type Required Restrictions Description
    name string false none The name of the analytic store in the CAS library.
    uri string false none The URI to the CAS library location for the analytic store.
    key string false none The unique key assigned to the analytic store.
    caslib string false none The name of the CAS library where this analytic store is stored.
    location string false none The integration URI for SAS Event Stream Processing and SAS Micro Analytic Service integration.
    errorCode string false none The error code that is returned when moving the analytic store to the integration location has failed.
    host string false none The server host name of the integration location.
    fullPath string false none The full filepath of the integration location.
    state string false none The state of the last integration copy request.
    version integer false none The repository representation version. The version is 2.
    links [link] false none Links that apply to this file resource. The links are: "self", "content", "patch", "update", and "delete".

    analyticStoreCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "string",
          "uri": "string",
          "key": "string",
          "caslib": "string",
          "location": "string",
          "errorCode": "string",
          "host": "string",
          "fullPath": "string",
          "state": "string",
          "version": 1,
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    

    Analytic Store Collection

    Properties
    Name Type Required Restrictions Description
    Analytic Store Collection any false none none

    allOf

    Name Type Required Restrictions Description
    anonymous modelProjectCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » name string false none The name of the analyticStores collection in the context of the request.
    » accept string false none application/vnd.sas.collection
    » items [analyticStore] false none An array of application/vnd.sas.models.analytic.store.

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    Model Repository Media Types
    application/vnd.sas.models.repository

    Contains details about a model repository.

    The schema is at modelRepostiory.

    application/vnd.sas.models.repository+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-09-28T18:03:07.921Z",
       "modifiedTimeStamp":"2017-09-28T18:03:11.950Z",
       "createdBy":"myUserID",
       "modifiedBy":"myUserID",
       "links":[ 
          {  
             "method":"GET",
             "rel":"up",
             "href":"/modelRepository/repositories",
             "uri":"/modelRepository/repositories",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.repository"
          }, 
          {  
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository/repositories/5797affd-f572-412e-bbf5-a071f9e33095",
             "uri":"/modelRepository/repositories/5797affd-f572-412e-bbf5-a071f9e33095",
             "type":"application/vnd.sas.models.repository"
          },
          {  
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelRepository/repositories/5797affd-f572-412e-bbf5-a071f9e33095",
             "uri":"/modelRepository/repositories/5797affd-f572-412e-bbf5-a071f9e33095"
          },
          {  
             "method":"PUT",
             "rel":"update",
             "href":"/modelRepository/repositories/5797affd-f572-412e-bbf5-a071f9e33095",
             "uri":"/modelRepository/repositories/5797affd-f572-412e-bbf5-a071f9e33095",
             "type":"application/vnd.sas.models.repository"
          }
       ],
       "version":2,
       "id":"5797affd-f572-412e-bbf5-a071f9e33095",
       "name":"Repository 1",
       "description":"This is the default model repository.",
       "folderId":"9710a1a6-a3a8-4cd7-aaba-5194f4b86879",
       "defaultRepository":true
    }
    
    application/vnd.sas.models.model

    Contains metadata about the model, as well as links to the model files and source code.

    The schema is at model.

    application/vnd.sas.models.model+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-09-28T18:14:04.276Z",
       "modifiedTimeStamp":"2017-09-28T18:14:04.276Z",
       "createdBy":"myUserID",
       "modifiedBy":"myUserID",
       "links":[
          {
             "method":"GET",
             "rel":"up",
             "href":"/modelRepository/models",
             "uri":"/modelRepository/models",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.summary"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "type":"application/vnd.sas.models.model"
          },
          {
             "method":"GET",
             "rel":"alternate",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "type":"application/vnd.sas.models.model.summary"
          },
          {
             "method":"GET",
             "rel":"scoreCode",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/code",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/code",
             "type":"text/plain"
          },
          {
             "method":"GET",
             "rel":"contents",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.content"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "type":"application/vnd.sas.models.model",
             "responseType":"application/vnd.sas.models.model"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756"
          },
          {
             "method":"GET",
             "rel":"modelVersions",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/modelVersions",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/modelVersions",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.version"
          },
          {
             "method":"POST",
             "rel":"addModelVersion",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/modelVersions",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/modelVersions",
             "type":"application/vnd.sas.models.model.version"
          },
          {
             "method":"GET",
             "rel":"variables",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.variable"
          },
          {
             "method":"POST",
             "rel":"setAsChampion",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion?modelId=f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion?modelId=f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "responseType":"application/vnd.sas.models.model"
          },
          {
             "method":"POST",
             "rel":"setAsChallenger",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers?modelId=f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers?modelId=f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "responseType":"application/vnd.sas.models.model"
          }
       ],
       "version":2,
       "id":"f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
       "name":"seededUiSpkHmeq",
       "description":"For Robin and Kristen",
       "location":"/Model Repositories/Repository 1/seededUiFolder",
       "projectId":"3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
       "projectName":"seededUiProject",
       "projectVersionId":"0e849bd4-203d-4a14-aceb-75139d1392b4",
       "projectVersionName":"Version 1",
       "repositoryId":"5797affd-f572-412e-bbf5-a071f9e33095",
       "function":"classification",
       "scoreCodeType":"dataStep",
       "suggestedChampion":false,
       "role":"plain",
       "immutable":false,
       "inputVariables":[
          {
             "creationTimeStamp":"2017-09-28T18:14:04.620Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.620Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9"
                }
             ],
             "version":2,
             "id":"7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
             "name":"CLAGE",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.622Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.622Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670"
                }
             ],
             "version":2,
             "id":"45d3672c-34ac-4ea6-a1dc-bb9330540670",
             "name":"CLNO",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.623Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.623Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f"
                }
             ],
             "version":2,
             "id":"e61f9e18-31b9-408c-8299-41d860dc938f",
             "name":"DEBTINC",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.623Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.623Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6"
                }
             ],
             "version":2,
             "id":"fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
             "name":"DELINQ",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.623Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.623Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7"
                }
             ],
             "version":2,
             "id":"e0c609c6-94ac-461e-8d09-cb0194ce33e7",
             "name":"DEROG",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.624Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.624Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b"
                }
             ],
             "version":2,
             "id":"e09647b6-6e66-496e-84c5-917fc6da689b",
             "name":"JOB",
             "role":"input",
             "type":"string",
             "level":"nominal",
             "format":"Best8.",
             "length":7
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.626Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.626Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd"
                }
             ],
             "version":2,
             "id":"be549582-c176-44bd-be72-1943943f7cbd",
             "name":"LOAN",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.626Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.626Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932"
                }
             ],
             "version":2,
             "id":"8c09299a-f78a-4915-9305-f69f644cb932",
             "name":"MORTDUE",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.626Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.626Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8"
                }
             ],
             "version":2,
             "id":"fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
             "name":"NINQ",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.627Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.627Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3"
                }
             ],
             "version":2,
             "id":"662f46c8-28cd-4bf3-b0b9-dd0357198af3",
             "name":"REASON",
             "role":"input",
             "type":"string",
             "level":"nominal",
             "length":7
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9"
                }
             ],
             "version":2,
             "id":"28cd6fc8-5557-4f6e-9788-c35f912116c9",
             "name":"VALUE",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a"
                }
             ],
             "version":2,
             "id":"66e8313f-2225-416b-80b3-4d2b767d897a",
             "name":"YOJ",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          }
       ],
       "outputVariables":[
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a"
                }
             ],
             "version":2,
             "id":"6aa90846-c344-4fe9-87b1-c4d19e387d8a",
             "name":"EM_CLASSIFICATION",
             "role":"output",
             "type":"string",
             "level":"nominal",
             "length":32
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c"
                }
             ],
             "version":2,
             "id":"ea37840c-7872-4ee9-9774-703dd9eeca6c",
             "name":"EM_EVENTPROBABILITY",
             "role":"output",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed"
                }
             ],
             "version":2,
             "id":"a129779e-2ed8-4f3b-8a6b-ab570491fbed",
             "name":"EM_PROBABILITY",
             "role":"output",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.630Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.630Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb"
                }
             ],
             "version":2,
             "id":"56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
             "name":"I_BAD",
             "role":"output",
             "type":"string",
             "level":"nominal",
             "length":12
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.635Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.635Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7"
                }
             ],
             "version":2,
             "id":"6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
             "name":"P_BAD0",
             "role":"output",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.635Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.635Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294"
                }
             ],
             "version":2,
             "id":"1d8a77d8-574f-490a-84d0-88cc27e3b294",
             "name":"P_BAD1",
             "role":"output",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.635Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.635Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d"
                }
             ],
             "version":2,
             "id":"23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
             "name":"U_BAD",
             "role":"output",
             "type":"decimal",
             "level":"nominal",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.636Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.636Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319"
                }
             ],
             "version":2,
             "id":"f021aa35-e096-41fd-867d-840191bfb319",
             "name":"_WARN_",
             "role":"output",
             "type":"string",
             "level":"nominal",
             "length":4
          }
       ],
       "modelVersionName":"1.0",
       "retrainable":false,
       "dataUris" :[ {
             "name" : "VA_REPORTS",
             "uri" : "/files/files/78d74a72-2c7d-4646-9073-dd660855555",
             "mediaType" : "application/vnd.sas.analytics.report+json"
           }
       ],
       "targetVariable":"BAD"
    }
    
    
    application/vnd.sas.models.model.summary

    Returns the resource summary information for the specified model ID.

    This media type is a summary form of application/vnd.sas.models.model. The primary difference between these two is that this summary omits members: "location", "inputVariables", "outputVariables" and "targetVariables".

    The schema is at modelSummary.

    application/vnd.sas.models.model.summary+json

    Here is an example of the JSON representation for this media type.

    
     {
         "creationTimeStamp":"2017-09-28T18:14:04.276Z",
         "modifiedTimeStamp":"2017-09-28T18:14:04.276Z",
         "createdBy":"myUserID",
         "modifiedBy":"myUserID",
         "links":[  
            {  
               "method":"GET",
               "rel":"self",
               "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
               "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
               "type":"application/vnd.sas.models.model"
            },
            {  
               "method":"DELETE",
               "rel":"delete",
               "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
               "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756"
            },
            {  
               "method":"GET",
               "rel":"contents",
               "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
               "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
               "type":"application/vnd.sas.collection",
               "itemType":"application/vnd.sas.models.model.content"
            },
            {  
               "method":"GET",
               "rel":"variables",
               "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
               "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
               "type":"application/vnd.sas.collection",
               "itemType":"application/vnd.sas.models.variable"
            }
         ],
         "version":2,
         "id":"f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
         "name":"seededUiSpkHmeq",
         "description":"For Robin and Kristen",
         "projectId":"3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
         "projectName":"seededUiProject",
         "projectVersionId":"0e849bd4-203d-4a14-aceb-75139d1392b4",
         "projectVersionName":"Version 1",
         "repositoryId":"5797affd-f572-412e-bbf5-a071f9e33095",
         "function":"classification",
         "scoreCodeType":"dataStep",
         "role":"plain",
         "immutable":false,
         "modelVersionName":"1.0",
    }
    
    application/vnd.sas.models.model.content

    Contains the metadata information about the model file that is associated with the specified model ID and content ID

    The schema is at modelContent.

    application/vnd.sas.models.model.content+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-09-28T18:14:09.086Z",
       "modifiedTimeStamp":"2017-09-28T18:14:09.086Z",
       "createdBy":"myUserID",
       "modifiedBy":"myUserID",
       "links":[
          {
             "method":"GET",
             "rel":"up",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.content"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "type":"application/vnd.sas.models.model.content"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "type":"application/vnd.sas.models.model.content"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e"
          },
          {
             "method":"GET",
             "rel":"content",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "type":"text/vnd.sas.source.sas"
          },
          {
             "method":"PUT",
             "rel":"updateContentStream",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "type":"application/octet-stream",
             "responseType":"application/vnd.sas.models.model.content"
          },
          {
             "method":"PUT",
             "rel":"updateContentMultipart",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "type":"multipart/form-data",
             "responseType":"application/vnd.sas.models.model.content"
          }
       ],
       "version":2,
       "id":"fe438479-a078-43ce-84f0-5d9e719b809e",
       "name":"batch.sas",
       "modelId":"f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
       "role":"train",
       "fileUri":"/files/files/9038cd31-f1a7-4f48-a02f-e75acc1cdfef"
    }
    

    Here is an example of the JSON representation for a collection of model content.

    
     {
    [
       {
          "method":"GET",
          "rel":"self",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "type":"application/vnd.sas.collection",
          "itemType":"application/vnd.sas.models.model.content"
       },
       {
          "method":"POST",
          "rel":"create",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "type":"application/vnd.sas.models.model.content"
       },
       {
          "method":"POST",
          "rel":"addContent",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "type":"multipart/form-data",
          "responseType":"application/vnd.sas.models.model.content"
       },
       {
          "method":"GET",
          "rel":"up",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5",
          "type":"application/vnd.sas.models.model"
       }
    ]
    "name": "contents",
    "count": 5,
    items: [
    ],
    "version": 2
    }
    
    application/vnd.sas.models.model.variable

    Contains the model variable associated with the specified model ID and variable ID.

    The schema is at modelVariable.

    application/vnd.sas.models.model.variable+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-09-28T18:14:04.620Z",
       "modifiedTimeStamp":"2017-09-28T18:14:04.620Z",
       "createdBy":"myUserID",
       "modifiedBy":"myUserID",
       "links":[
          {
             "method":"GET",
             "rel":"up",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.variable"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
             "type":"application/vnd.sas.models.variable"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
             "type":"application/vnd.sas.models.variable"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9"
          }
       ],
       "version":2,
       "id":"7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
       "name":"CLAGE",
       "role":"input",
       "type":"decimal",
       "level":"interval",
       "format":"Best8.",
       "length":8
    }
    

    Here is an example of a collection of variables.

    
     {
    [
       {
          "method":"GET",
          "rel":"self",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/variables",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/variables",
          "type":"application/vnd.sas.collection",
          "itemType":"application/vnd.sas.models.variable"
       },
       {
          "method":"POST",
          "rel":"create",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/variables",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/variables",
          "type":"application/vnd.sas.models.variable",
          "responseType":"application/vnd.sas.models.variable"
       },
       {
          "method":"GET",
          "rel":"up",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5",
          "type":"application/vnd.sas.models.model"
       }
    ],
    "name": "model variables",
    "count": 0,
    "items":[]
    
    }
    
    
    application/vnd.sas.models.model.request

    This is used only in the creation of a common model into model repository. It provides metadata about the model as well as links to the model files, analytic store, and source code.

    The schema is at modelRequest.

    application/vnd.sas.models.model.request

    Here is an example of the JSON representation for this media type.

    
     {
      "version" : 2,
      "name" : "Decision Tree",
      "modeler" : "emduser1",
      "function" : "classification",
      "algorithm" : "tree",
      "tool" : "SAS Visual Pipeline",
      "toolVersion" : "15.1",
      "targetEvent" : "Self",
      "sourceUri" : {
        "name" : "Decision Tree",
        "uri" : "/analyticsComponents/components/5c7262e1-9165-4d20-a572-14cb7565a89b",
        "uriType" : "reference",
        "mediaType" : "application/vnd.sas.analytics.component"
      },
      "nondeterministic" : false,
      "datasourceUri" : {
        "name" : "DM_64QIXSR0ZOJZVNOM4Y9FOF84K",
        "uri" : "/dataTables/dataSources/cas~fs~cas~fs~DMINE/tables/DM_64QIXSR0ZOJZVNOM4Y9FOF84K",
        "uriType" : "reference"
      },
      "externalModelId" : "5c7262e1-9165-4d20-a572-14cb7565a89b",
      "fitStatUri" : {
        "name" : "dmcas_fitstat",
        "uri" : "/files/files/78d74a72-2c7d-4646-9073-dd66081f0f30",
        "mediaType" : "application/vnd.sas.analytics.report+json"
      },
      "dataUris" :[ {
          "name" : "VA_REPORTS",
          "uri" : "/files/files/78d74a72-2c7d-4646-9073-dd660855555",
          "mediaType" : "application/vnd.sas.analytics.report+json"
        }
      ],
      "sasOptions" : "options VALIDMEMNAME=EXTEND VALIDVARNAME=ANY;\n",
      "partitionLevels" : [ {
        "dataRole" : "train",
        "value" : "1"
      }, {
        "dataRole" : "validate",
        "value" : "0"
      }, {
        "dataRole" : "test",
        "value" : "2"
      } ],
      "eventLevels" : [ {
        "variableName" : "I_JOB",
        "eventValue" : ""
      }, {
        "variableName" : "P_JOBMgr",
        "eventValue" : "Mgr"
      }, {
        "variableName" : "P_JOBOffice",
        "eventValue" : "Office"
      }, {
        "variableName" : "P_JOBOther",
        "eventValue" : "Other"
      }, {
        "variableName" : "P_JOBProfExe",
        "eventValue" : "ProfExe"
      }, {
        "variableName" : "P_JOBSales",
        "eventValue" : "Sales"
      }, {
        "variableName" : "P_JOBSelf",
        "eventValue" : "Self"
      } ],
      "interactions" : [ ],
      "modelTransformation" : {
        "inputVariables" : [ {
          "name" : "CLAGE",
          "role" : "input",
          "type" : "numeric",
          "level" : "interval",
          "label" : "",
          "length" : 8
        }, {
          "name" : "CLNO",
          "role" : "input",
          "type" : "numeric",
          "level" : "interval",
          "label" : "",
          "length" : 8
        }, {
          "name" : "DEBTINC",
          "role" : "input",
          "type" : "numeric",
          "level" : "interval",
          "label" : "",
          "length" : 8
        }, {
          "name" : "LOAN",
          "role" : "input",
          "type" : "numeric",
          "level" : "interval",
          "label" : "",
          "length" : 8
        }, {
          "name" : "MORTDUE",
          "role" : "input",
          "type" : "numeric",
          "level" : "interval",
          "label" : "",
          "length" : 8
        }, {
          "name" : "NINQ",
          "role" : "input",
          "type" : "numeric",
          "level" : "nominal",
          "label" : "",
          "length" : 8
        } ],
        "outputVariables" : [ {
          "name" : "I_JOB",
          "role" : "classification",
          "type" : "string",
          "length" : 7
        }, {
          "name" : "P_JOBMGR",
          "role" : "predict",
          "type" : "numeric",
          "length" : 8
        }, {
          "name" : "P_JOBOFFICE",
          "role" : "predict",
          "type" : "numeric",
          "length" : 8
        }, {
          "name" : "P_JOBOTHER",
          "role" : "predict",
          "type" : "numeric",
          "length" : 8
        }, {
          "name" : "P_JOBPROFEXE",
          "role" : "predict",
          "type" : "numeric",
          "length" : 8
        }, {
          "name" : "P_JOBSALES",
          "role" : "predict",
          "type" : "numeric",
          "length" : 8
        }, {
          "name" : "P_JOBSELF",
          "role" : "predict",
          "type" : "numeric",
          "length" : 8
        }, {
          "name" : "_leaf_id_",
          "role" : "input",
          "type" : "numeric",
          "length" : 8
        } ],
        "steps" : [ {
          "sequence" : 1,
          "type" : "ds1",
          "stepUri" : {
            "uri" : "/files/files/01837f1e-7921-4baf-a29f-6228f0ddee3a",
            "uriType" : "child",
            "contentType" : "ds1"
          },
          "inputVariables" : [ ],
          "outputVariables" : [ ]
        } ]
      },
      "trainInputs" : [ {
        "name" : "CLAGE",
        "role" : "input",
        "type" : "numeric",
        "level" : "interval",
        "length" : 8
      }, {
        "name" : "CLNO",
        "role" : "input",
        "type" : "numeric",
        "level" : "interval",
        "length" : 8
      }, {
        "name" : "DEBTINC",
        "role" : "input",
        "type" : "numeric",
        "level" : "interval",
        "length" : 8
      }, {
        "name" : "BAD",
        "role" : "input",
        "type" : "numeric",
        "level" : "binary",
        "length" : 8
      }, {
        "name" : "DELINQ",
        "role" : "input",
        "type" : "numeric",
        "level" : "nominal",
        "length" : 8
      }, {
        "name" : "DEROG",
        "role" : "input",
        "type" : "numeric",
        "level" : "nominal",
        "length" : 8
      }, {
        "name" : "LOAN",
        "role" : "input",
        "type" : "numeric",
        "level" : "interval",
        "length" : 8
      }, {
        "name" : "MORTDUE",
        "role" : "input",
        "type" : "numeric",
        "level" : "interval",
        "length" : 8
      }, {
        "name" : "NINQ",
        "role" : "input",
        "type" : "numeric",
        "level" : "nominal",
        "length" : 8
      }, {
        "name" : "REASON",
        "role" : "input",
        "type" : "string",
        "level" : "binary",
        "length" : 7
      }, {
        "name" : "VALUE",
        "role" : "input",
        "type" : "numeric",
        "level" : "interval",
        "length" : 8
      }, {
        "name" : "YOJ",
        "role" : "input",
        "type" : "numeric",
        "level" : "interval",
        "length" : 8
      }, {
        "name" : "JOB",
        "role" : "target",
        "type" : "string",
        "level" : "nominal",
        "length" : 7
      }, {
        "name" : "_PartInd_",
        "role" : "partition",
        "type" : "numeric",
        "level" : "interval",
        "label" : "_PartInd_",
        "length" : 8
      } ],
      "rocDataUri" : {
        "name" : "dmcas_roc",
        "uri" : "/files/files/2d101474-ecc9-411e-8196-b518d1f69ceb",
        "mediaType" : "application/vnd.sas.analytics.report+json"
      },
      "liftDataUri" : {
        "name" : "dmcas_lift",
        "uri" : "/files/files/1d2fe8e3-a68a-457d-92bf-a210cb0d0835",
        "mediaType" : "application/vnd.sas.analytics.report+json"
      }
    }
    
    application/vnd.sas.models.project.request

    Contains details about importing one or more model into a model project.

    The schema is at modelProject.

    application/vnd.sas.models.project.request+json

    Here is an example of the JSON representation for this media type.

    
     {
        "name":"WBtestingDMProject5",
        "description" :"Sample data mining CAS models.",
        "externalProjectId" : "dmcas5",
        "function":"Classification",
        "versionOption":"newVersion",
        "modelList":[
            {
                "href": "/folders/folders/5043d1cb-c6f0-4f5e-9cbc-a74b83e10865",
                "method": "GET",
                "rel": "modelTestFolder",
                "type": "application/vnd.sas.models.model",
                "uri": "/folders/folders/5043d1cb-c6f0-4f5e-9cbc-a74b83e10865"
            }
        ],
        "version":2
    }
    
    
    application/vnd.sas.models.project

    Contains details about a model project.

    The schema is at modelProject.

    application/vnd.sas.models.project+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-09-28T18:14:00.249Z",
       "modifiedTimeStamp":"2017-09-28T18:14:01.123Z",
       "createdBy":"myUserID",
       "modifiedBy":"myUserID",
       "links":[
          {
             "method":"GET",
             "rel":"up",
             "href":"/modelRepository/projects",
             "uri":"/modelRepository/projects",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.project.summary"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "type":"application/vnd.sas.models.project"
          },
          {
             "method":"GET",
             "rel":"alternate",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "type":"application/vnd.sas.models.project.summary"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "type":"application/vnd.sas.models.project"
          },
          {
             "method":"GET",
             "rel":"projectVersions",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.project.version"
          },
          {
             "method":"GET",
             "rel":"projectModels",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/models",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/models",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.summary"
          },
          {
             "method":"GET",
             "rel":"projectVariables",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/variables",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/variables",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.variable.summary"
          },
          {
             "method":"GET",
             "rel":"championModel",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion",
             "type":"application/vnd.sas.models.model"
          },
          {
             "method":"DELETE",
             "rel":"unsetChampion",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion"
          },
          {
             "method":"GET",
             "rel":"championScoreCodeJson",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "type":"text/vnd.sas.models.score.code.raw"
          },
          {
             "method":"GET",
             "rel":"championScoreCodeText",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "type":"text/plain"
          },
          {
             "method":"GET",
             "rel":"championDs2packageScoreCode",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "type":"text/vnd.sas.models.score.code.ds2package"
          },
          {
             "method":"GET",
             "rel":"championDs2ScoreCode",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "type":"text/vnd.sas.models.score.code.ds2"
          },
          {
             "method":"GET",
             "rel":"challengers",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.summary"
          },
          {
             "method":"DELETE",
             "rel":"unsetChallengers",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers"
          }
       ],
       "version":2,
       "id":"3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
       "name":"seededUiProject",
       "description":"For Robin and Kristen",
       "location":"/Model Repositories/Repository 1/seededUiFolder",
       "repositoryId":"5797affd-f572-412e-bbf5-a071f9e33095",
       "folderId":"637b427e-c158-4d0f-9fc5-d15d76115385",
       "candidateChampionHonored":false,
       "targetLevel":"",
       "challengerModels":[
    
       ],
       "latestVersion":"Version 1"
    }
    
    application/vnd.sas.models.project.summary

    Contains summary information about a model project.

    The schema is at modelProjectSummary.

    application/vnd.sas.models.project.summary+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-09-28T18:14:00.249Z",
       "modifiedTimeStamp":"2017-09-28T18:14:01.123Z",
       "createdBy":"myUserID",
       "modifiedBy":"myUserID",
       "links":[
          {
             "method":"GET",
             "rel":"up",
             "href":"/modelRepository/projects",
             "uri":"/modelRepository/projects",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.project.summary"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "type":"application/vnd.sas.models.project"
          },
          {
             "method":"GET",
             "rel":"alternate",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "type":"application/vnd.sas.models.project.summary"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
             "type":"application/vnd.sas.models.project"
          },
          {
             "method":"GET",
             "rel":"projectVersions",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.project.version"
          },
          {
             "method":"GET",
             "rel":"projectModels",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/models",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/models",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.summary"
          },
          {
             "method":"GET",
             "rel":"projectVariables",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/variables",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/variables",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.variable.summary"
          },
          {
             "method":"GET",
             "rel":"championModel",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion",
             "type":"application/vnd.sas.models.model"
          },
          {
             "method":"DELETE",
             "rel":"unsetChampion",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion"
          },
          {
             "method":"GET",
             "rel":"championScoreCodeJson",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "type":"text/vnd.sas.models.score.code.raw+json"
          },
          {
             "method":"GET",
             "rel":"championScoreCodeText",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "type":"text/plain"
          },
          {
             "method":"GET",
             "rel":"championDs2packageScoreCode",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "type":"text/vnd.sas.models.scorecode.ds2package"
          },
          {
             "method":"GET",
             "rel":"championDs2ScoreCode",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion/code",
             "type":"text/vnd.sas.models.scorecode.ds2"
          },
          {
             "method":"GET",
             "rel":"challengers",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.summary"
          },
          {
             "method":"DELETE",
             "rel":"unsetChallengers",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers"
          }
       ],
       "version":2,
       "id":"3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
       "name":"seededUiProject",
       "description":"For Robin and Kristen",
       "location":"/Model Repositories/Repository 1/seededUiFolder",
       "repositoryId":"5797affd-f572-412e-bbf5-a071f9e33095",
       "folderId":"637b427e-c158-4d0f-9fc5-d15d76115385"
    }
    
    application/vnd.sas.models.project.content

    Contains the metadata information about the project file that is associated with the specified project ID and content ID

    The schema is at projectContent.

    application/vnd.sas.models.project.content+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-09-28T18:14:09.086Z",
       "modifiedTimeStamp":"2017-09-28T18:14:09.086Z",
       "createdBy":"myUserID",
       "modifiedBy":"myUserID",
       "links":[
          {
             "method":"GET",
             "rel":"up",
             "href":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
             "uri":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.project.content"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "uri":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "type":"application/vnd.sas.models.project.content"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "uri":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "type":"application/vnd.sas.models.project.content"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e",
             "uri":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e"
          },
          {
             "method":"GET",
             "rel":"content",
             "href":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "uri":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "type":"text/vnd.sas.source.sas"
          },
          {
             "method":"POST",
             "rel":"updateContentMultipart",
             "href":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "uri":"/modelRepository/projects/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents/fe438479-a078-43ce-84f0-5d9e719b809e/content",
             "type":"multipart/form-data",
             "responseType":"application/vnd.sas.models.project.content"
          }
       ],
       "version":2,
       "id":"fe438479-a078-43ce-84f0-5d9e719b809e",
       "name":"batch.sas",
       "projectId":"f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
       "fileUri":"/files/files/9038cd31-f1a7-4f48-a02f-e75acc1cdfef"
    }
    

    Here is an example of the JSON representation for a collection of model content.

    
     {
    [
       {
          "method":"GET",
          "rel":"self",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "type":"application/vnd.sas.collection",
          "itemType":"application/vnd.sas.models.model.content"
       },
       {
          "method":"POST",
          "rel":"create",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "type":"application/vnd.sas.models.model.content"
       },
       {
          "method":"POST",
          "rel":"addContent",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5/contents",
          "type":"multipart/form-data",
          "responseType":"application/vnd.sas.models.model.content"
       },
       {
          "method":"GET",
          "rel":"up",
          "href":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5",
          "uri":"/modelRepository/models/63f16fb0-1136-4b8b-bf7a-e977babdd0f5",
          "type":"application/vnd.sas.models.model"
       }
    ]
    "name": "contents",
    "count": 5,
    items: [
    ],
    "version": 2
    }
    
    application/vnd.sas.models.project.version

    Contains details about a project version. Each project can have one or more versions. Each project version can contain one or more models.

    The schema is at modelProjectVersion.

    application/vnd.sas.models.project.version+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-09-28T18:14:01.110Z",
       "modifiedTimeStamp":"2017-09-28T18:14:01.124Z",
       "createdBy":"myUserID",
       "modifiedBy":"myUserID",
       "links":[
          {
             "method":"PUT",
             "rel":"update",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions/0e849bd4-203d-4a14-aceb-75139d1392b4",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions/0e849bd4-203d-4a14-aceb-75139d1392b4",
             "type":"application/vnd.sas.models.project.version",
             "responseType":"application/vnd.sas.models.project.version"
          },
          {
             "method":"GET",
             "rel":"up",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.project.version"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions/0e849bd4-203d-4a14-aceb-75139d1392b4",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions/0e849bd4-203d-4a14-aceb-75139d1392b4",
             "type":"application/vnd.sas.models.project.version"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions/0e849bd4-203d-4a14-aceb-75139d1392b4",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions/0e849bd4-203d-4a14-aceb-75139d1392b4"
          },
          {
             "method":"GET",
             "rel":"projectVersionModels",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions/0e849bd4-203d-4a14-aceb-75139d1392b4/models",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/projectVersions/0e849bd4-203d-4a14-aceb-75139d1392b4/models",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.summary"
          }
       ],
       "version":2,
       "id":"0e849bd4-203d-4a14-aceb-75139d1392b4",
       "name":"Version 1",
       "location":"/Model Repositories/Repository 1/seededUiFolder",
       "parentId":"3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
       "versionNumber":"1.0"
    }
    
    application/vnd.sas.models.analytic.store

    Contains analytic store metadata in JSON format.

    The schema is at analyticStore.

    
     {
      "name": "_61M7Z0JR5M700WNIGXEZ2BG03_AST",
      "uri": "/dataTables/dataSources/cas~fs~cas-shared-default~fs~ModelStore/tables/_61M7Z0JR5M700WNIGXEZ2BG03_AST",
      "key": "CC9334D8ED7C5D7137340B3AD9BCA50D0280A0D8",
      "caslib": "ModelStore",
      "location": "file:///models/astores/viya/_61M7Z0JR5M700WNIGXEZ2BG03_AST.astore",
      "host": "d7-mon-18w25.uda.sashq-r.openstack.sas.com",
      "fullPath": "/opt/sas/viya/config/data/modelsvr/astore/_61M7Z0JR5M700WNIGXEZ2BG03_AST.astore",
      "state": "Success"
    }
    
    text/vnd.sas.models.score.code.raw

    Contains model score code in JSON format.

    The schema is at scoreCode.

    
     {
      length _strfmt_ $7; 
      drop _strfmt_;
      _strfmt_ = ' ';
      length DT_bad 8;
      ...
      drop _numval_;
      drop _node_id_;
      drop _new_id_;
    }
    
    text/vnd.sas.models.score.code.ds2package

    Contains model score code in a DS2 package format.

    The schema is at scoreCodeDs2Package.

    
     {
      proc ds2;
      ds2_options sas tkgmac;
      package REg1/overwrite=yes;
      ...
      end;
      endpackage;
      run;
    }
    
    text/vnd.sas.models.score.code.ds2

    Contains model score code as ds2 format.

    The schema is at scoreCodeDs2.

    
     {
      #_local _P1;
      #_local _P0;
      #_local _IY;
      #_local _MAXP;
      ...
      I_BAD = REGDRF[_IY];
      U_BAD = REGDRU[_IY];
      EM_EVENTPROBABILITY = P_BAD1;
      EM_PROBABILITY = MAX(P_BAD1, P_BAD0);
      EM_CLASSIFICATION = I_BAD;
      _return: ;
    }
    
    
    application/vnd.sas.models.model.version

    Contains details about a model version for a specific model. A model version is a snapshot of the metadata about the model, as well as links to the model files and source code.

    The schema is at modelVersion.

    application/vnd.sas.models.model.version+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-09-28T18:14:04.276Z",
       "modifiedTimeStamp":"2017-09-28T18:14:04.276Z",
       "createdBy":"myUserID",
       "modifiedBy":"myUserID",
       "links":[
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "type":"application/vnd.sas.models.model"
          },
          {
             "method":"GET",
             "rel":"alternate",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "type":"application/vnd.sas.models.model.summary"
          },
          {
             "method":"GET",
             "rel":"scoreCode",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/code",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/code",
             "type":"text/plain"
          },
          {
             "method":"GET",
             "rel":"contents",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/contents",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.content"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "type":"application/vnd.sas.models.model",
             "responseType":"application/vnd.sas.models.model"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756"
          },
          {
             "method":"GET",
             "rel":"modelVersions",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/modelVersions",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/modelVersions",
             "type":"application/vnd.sas.collection",
             "responseItemType":"application/vnd.sas.models.model.version"
          },
          {
             "method":"POST",
             "rel":"addModelVersion",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/modelVersions",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/modelVersions",
             "type":"application/vnd.sas.models.model.version"
          },
          {
             "method":"GET",
             "rel":"variables",
             "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
             "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.variable"
          },
          {
             "method":"POST",
             "rel":"setAsChampion",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion?modelId=f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/champion?modelId=f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "responseType":"application/vnd.sas.models.model"
          },
          {
             "method":"POST",
             "rel":"setAsChallenger",
             "href":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers?modelId=f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "uri":"/modelRepository/projects/3cd6dd2f-7114-4ebd-9f25-89f7806c8399/challengers?modelId=f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
             "responseType":"application/vnd.sas.models.model"
          }
       ],
       "version":2,
       "id":"f7edcd6c-8adf-434c-b6fe-aa0f8a81d756",
       "name":"seededUiSpkHmeq",
       "description":"For Robin and Kristen",
       "location":"/Model Repositories/Repository 1/seededUiFolder",
       "projectId":"3cd6dd2f-7114-4ebd-9f25-89f7806c8399",
       "projectName":"seededUiProject",
       "projectVersionId":"0e849bd4-203d-4a14-aceb-75139d1392b4",
       "projectVersionName":"Version 1",
       "projectVersionNum":"1.0",
       "indirectFolderId":"637b427e-c158-4d0f-9fc5-d15d76115385",
       "repositoryId":"5797affd-f572-412e-bbf5-a071f9e33095",
       "function":"classification",
       "scoreCodeType":"dataStep",
       "suggestedChampion":false,
       "candidateChampion":false,
       "role":"plain",
       "immutable":true,
       "inputVariables":[
          {
             "creationTimeStamp":"2017-09-28T18:14:04.620Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.620Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9"
                }
             ],
             "version":2,
             "id":"7a7b7945-6ffd-4678-9a37-ea5ce7fdd2d9",
             "name":"CLAGE",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.622Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.622Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/45d3672c-34ac-4ea6-a1dc-bb9330540670"
                }
             ],
             "version":2,
             "id":"45d3672c-34ac-4ea6-a1dc-bb9330540670",
             "name":"CLNO",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.623Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.623Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e61f9e18-31b9-408c-8299-41d860dc938f"
                }
             ],
             "version":2,
             "id":"e61f9e18-31b9-408c-8299-41d860dc938f",
             "name":"DEBTINC",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.623Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.623Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb46b22a-ffe3-486d-a6da-e06116c5ebb6"
                }
             ],
             "version":2,
             "id":"fb46b22a-ffe3-486d-a6da-e06116c5ebb6",
             "name":"DELINQ",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.623Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.623Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e0c609c6-94ac-461e-8d09-cb0194ce33e7"
                }
             ],
             "version":2,
             "id":"e0c609c6-94ac-461e-8d09-cb0194ce33e7",
             "name":"DEROG",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.624Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.624Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/e09647b6-6e66-496e-84c5-917fc6da689b"
                }
             ],
             "version":2,
             "id":"e09647b6-6e66-496e-84c5-917fc6da689b",
             "name":"JOB",
             "role":"input",
             "type":"string",
             "level":"nominal",
             "length":7
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.626Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.626Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/be549582-c176-44bd-be72-1943943f7cbd"
                }
             ],
             "version":2,
             "id":"be549582-c176-44bd-be72-1943943f7cbd",
             "name":"LOAN",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.626Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.626Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/8c09299a-f78a-4915-9305-f69f644cb932"
                }
             ],
             "version":2,
             "id":"8c09299a-f78a-4915-9305-f69f644cb932",
             "name":"MORTDUE",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.626Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.626Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8"
                }
             ],
             "version":2,
             "id":"fb4e350f-b1d3-4fcf-9987-b9ce9d2c3fe8",
             "name":"NINQ",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.627Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.627Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/662f46c8-28cd-4bf3-b0b9-dd0357198af3"
                }
             ],
             "version":2,
             "id":"662f46c8-28cd-4bf3-b0b9-dd0357198af3",
             "name":"REASON",
             "role":"input",
             "type":"string",
             "level":"nominal",
             "length":7
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/28cd6fc8-5557-4f6e-9788-c35f912116c9"
                }
             ],
             "version":2,
             "id":"28cd6fc8-5557-4f6e-9788-c35f912116c9",
             "name":"VALUE",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/66e8313f-2225-416b-80b3-4d2b767d897a"
                }
             ],
             "version":2,
             "id":"66e8313f-2225-416b-80b3-4d2b767d897a",
             "name":"YOJ",
             "role":"input",
             "type":"decimal",
             "level":"interval",
             "length":8
          }
       ],
       "outputVariables":[
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6aa90846-c344-4fe9-87b1-c4d19e387d8a"
                }
             ],
             "version":2,
             "id":"6aa90846-c344-4fe9-87b1-c4d19e387d8a",
             "name":"EM_CLASSIFICATION",
             "role":"output",
             "type":"string",
             "level":"nominal",
             "length":32
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/ea37840c-7872-4ee9-9774-703dd9eeca6c"
                }
             ],
             "version":2,
             "id":"ea37840c-7872-4ee9-9774-703dd9eeca6c",
             "name":"EM_EVENTPROBABILITY",
             "role":"output",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.628Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.628Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/a129779e-2ed8-4f3b-8a6b-ab570491fbed"
                }
             ],
             "version":2,
             "id":"a129779e-2ed8-4f3b-8a6b-ab570491fbed",
             "name":"EM_PROBABILITY",
             "role":"output",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.630Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.630Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb"
                }
             ],
             "version":2,
             "id":"56f59e1c-e8e2-4cde-bfc2-6ab4db52f4bb",
             "name":"I_BAD",
             "role":"output",
             "type":"string",
             "level":"nominal",
             "length":12
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.635Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.635Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/6a147fd5-5520-41c4-978a-24c9a0d8e5e7"
                }
             ],
             "version":2,
             "id":"6a147fd5-5520-41c4-978a-24c9a0d8e5e7",
             "name":"P_BAD0",
             "role":"output",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.635Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.635Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/1d8a77d8-574f-490a-84d0-88cc27e3b294"
                }
             ],
             "version":2,
             "id":"1d8a77d8-574f-490a-84d0-88cc27e3b294",
             "name":"P_BAD1",
             "role":"output",
             "type":"decimal",
             "level":"interval",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.635Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.635Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/23c78dd6-ccf1-4b8e-9b42-2a681d419e5d"
                }
             ],
             "version":2,
             "id":"23c78dd6-ccf1-4b8e-9b42-2a681d419e5d",
             "name":"U_BAD",
             "role":"output",
             "type":"decimal",
             "level":"nominal",
             "length":8
          },
          {
             "creationTimeStamp":"2017-09-28T18:14:04.636Z",
             "modifiedTimeStamp":"2017-09-28T18:14:04.636Z",
             "createdBy":"myUserID",
             "modifiedBy":"myUserID",
             "links":[
                {
                   "method":"GET",
                   "rel":"up",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables",
                   "type":"application/vnd.sas.collection",
                   "itemType":"application/vnd.sas.models.variable"
                },
                {
                   "method":"GET",
                   "rel":"self",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"PUT",
                   "rel":"update",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "type":"application/vnd.sas.models.variable"
                },
                {
                   "method":"DELETE",
                   "rel":"delete",
                   "href":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319",
                   "uri":"/modelRepository/models/f7edcd6c-8adf-434c-b6fe-aa0f8a81d756/variables/f021aa35-e096-41fd-867d-840191bfb319"
                }
             ],
             "version":2,
             "id":"f021aa35-e096-41fd-867d-840191bfb319",
             "name":"_WARN_",
             "role":"output",
             "type":"string",
             "level":"nominal",
             "length":4
          }
       ],
       "modelVersionName":"1.0",
       "retrainable":false,
       "targetVariable":"BAD"
    }
    
    
    Externally Defined Media Types
    application/vnd.sas.api

    Contains top-level links for an API. See application/vnd.sas.api

    Here is an example of the JSON representation for this media type.

    
     {
       "version":1,
       "links":[  
          {  
             "method":"GET",
             "rel":"self",
             "href":"/modelRepository",
             "uri":"/modelRepository",
             "type":"application/vnd.sas.api"
          },
          {  
             "method":"GET",
             "rel":"models",
             "href":"/modelRepository/models",
             "uri":"/modelRepository/models",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.summary"
          },
          {  
             "method":"POST",
             "rel":"addModel",
             "href":"/modelRepository/models",
             "uri":"/modelRepository/models",
             "type":"application/vnd.sas.models.model",
             "responseType":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.summary"
          },
          {  
             "method":"POST",
             "rel":"addModelProject",
             "href":"/modelRepository/models",
             "uri":"/modelRepository/models",
             "type":"application/vnd.sas.models.project.request",
             "responseType":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.model.summary"
          },
          {  
             "method":"GET",
             "rel":"projects",
             "href":"/modelRepository/projects",
             "uri":"/modelRepository/projects",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.project.summary"
          },
          {  
             "method":"POST",
             "rel":"createProject",
             "href":"/modelRepository/projects",
             "uri":"/modelRepository/projects",
             "type":"application/vnd.sas.models.project"
          },
          {  
             "method":"GET",
             "rel":"repositories",
             "href":"/modelRepository/repositories",
             "uri":"/modelRepository/repositories",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.models.repository.summary"
          },
          {  
             "method":"POST",
             "rel":"createRepository",
             "href":"/modelRepository/repositories",
             "uri":"/modelRepository/repositories",
             "type":"application/vnd.sas.models.repository"
          }
       ]
    }
    
    
    application/vnd.sas.collection

    A paginated, filterable, sortable collection of resource representations.

    See application/vnd.sas.collection.

    application/vnd.sas.error

    Used to represent error response from REST API calls.

    See application/vnd.sas.error.

    Represents a link in REST or another web application.

    See application/vnd.sas.link.

    Resource Relationships

    Path: /

    The Root resource returns a collection of links to the top-level resources surfaced through this API. The response uses the application/vnd.sas.api media type.

    The GET / response includes the following links:

    Relation Method Description
    models GET Returns the first page of the collection of models.
    URI: '/modelRepository/models'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.summary.
    createModel POST Import a model into the model repository.
    URI: '/modelRepository/models'
    Request type: application/vnd.sas.models.model.
    Response type: application/vnd.sas.models.model.
    importModelsToProject POST Imports one or more models into a model project within the model repository.
    URI: '/modelRepository/models'
    Request type: application/vnd.sas.models.model.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.summary.
    projects GET Returns the first page of the collection of projects.
    URI: '/modelRepository/projects'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.summary.
    createProject POST Creates a model project in the model repository.
    URI: '/modelRepository/projects'
    Request type: application/vnd.sas.models.project.
    Response type: application/vnd.sas.models.project.
    repositories GET Returns the first page of the collection of repositories.
    URI: '/modelRepository/repositories'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.repository.summary.
    createRepository POST Creates a repository in the common model repository.
    URI: '/modelRepository/repositories'
    Request type: application/vnd.sas.models.repository.
    Response type: application/vnd.sas.models.repository.
    Models

    Path: /models

    This resource provides a collection of models.

    Default page size is 20.

    The models collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.models.model resources. (These types apply to the response for the self, prev, next, first, and last links below.)

    The response includes the following links:

    Relation Method Description
    self GET Returns the current page from the collection.
    URI: '/modelRepository/models'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.summary.
    prev GET Returns the previous page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    next GET Returns the next page of resources from the collection. This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    first GET Returns the first page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    last GET Returns the last page of resources from the collection. This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    createModel POST Imports a model into a project or folder.
    URI: '/modelRepository/models'
    Request type: application/vnd.sas.models.model.
    Response type: application/vnd.sas.models.model.
    createModelCommon POST Imports a common SAS Viya model into a folder.
    URI: '/modelRepository/models'
    Request type: application/vnd.sas.models.model.request.
    Response type: application/vnd.sas.models.model.
    createModelProject POST Imports a collection of models into a project.
    URI: '/modelRepository/models'
    Request type: application/vnd.sas.models.project.request.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.summary.
    createModelMultipartFormData POST Imports a model into a project or folder through multipart form data.
    URI: '/modelRepository/models'
    Request type: multipart/form-data.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.summary.
    createModelOctetStream POST Imports a model into a project or folder through octet stream.
    URI: '/modelRepository/models'
    Request type: application/octet-stream.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.summary.
    Model Algorithm

    The is the enumeration of model algorithm

    Model Details

    Path: /models/{modelId}

    Contains details about a model that is located in a folder or a project.

    The model representation is application/vnd.sas.models.model.

    The response includes the following links:

    Relation Method Description
    up GET Returns the collection to which this model belongs.
    URI: '/modelRepository/models'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.
    Response item type: application/vnd.sas.models.model.summary.
    self GET Returns information about a model for the specified model ID.
    URI: '/modelRepository/models/{modelId}'
    Response type: application/vnd.sas.models.model.
    alternate GET Returns a summary about a model for the specified model ID.
    URI: '/modelRepository/models/{modelId}'
    Response type: application/vnd.sas.models.model.summary.
    delete DELETE Deletes a model with the specified ID.
    URI: '/modelRepository/models/{modelId}'
    update PUT Updates the model information for the model that matches the specified criteria and model ID.
    URI: '/modelRepository/models/{modelId}'
    Response type: application/vnd.sas.models.model.
    contents GET Returns the contents of a model for the specified model ID.
    URI: '/modelRepository/models/{modelId}/contents'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.content.
    variables GET Returns the variables of a model for the specified model ID.
    URI: '/modelRepository/models/{modelId}/variables'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.variable.
    scoreCode GET Returns the model score code for the specified model ID.
    URI: '/modelRepository/models/{modelId}/code'
    Response type: text/plain.
    setAsChampion POST Sets the specified model as a project champion.
    URI: '/modelRepository/projects/{projectId}/champion?modelId={modelId}'
    Response type: application/vnd.sas.models.model.
    setAsChallenger POST Sets the specified model as a challenger.
    URI: '/modelRepository/projects/{projectId}/challengers?modelId={modelId}'
    Response type: application/vnd.sas.models.model.
    modelVersions GET Returns a list of model versions for the specified model ID.
    URI: '/modelRepository/models/{modelId}/modelVersions'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.version.
    addModelVersions POST Creates a new model version for the specified model ID.
    URI: '/modelRepository/models/{modelId}/modelVersions'
    Request type: application/vnd.sas.models.model.version.
    Response type: application/vnd.sas.models.model.version.
    Model Contents

    Path: /models/{modelId}/contents

    This resource contains a collection of model contents.

    The modelContents representation is application/vnd.sas.models.model.content.

    The response includes the following links:

    Relation Method Description
    up GET Returns the model that the contents belong to.
    URI: '/modelRepository/models/{modelId}'
    Response type: application/vnd.sas.models.model.
    self GET Returns the contents of a model and the metadata information for the specified model ID.
    URI: '/modelRepository/models/{modelId}/contents'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.content.
    create POST Adds the specified model contents to the model associated with the specified model ID.
    URI: '/modelRepository/models/{modelId}/contents'
    Request type: application/vnd.sas.models.model.content.
    Response type: application/vnd.sas.models.model.content.
    addContent POST Adds the specified model contents to the model associated with the specified model ID.
    URI: '/modelRepository/models/{modelId}/contents'
    Request type: multipart/form-data.
    Response type: application/vnd.sas.models.model.content.
    Model Content Details

    Path: /models/{modelId}/contents/{contentId}

    This resource contains model content details.

    The modelContentDetail representation is application/vnd.sas.models.model.content.

    The response includes the following links:

    Relation Method Description
    up GET Returns the collection to which the model content belongs.
    URI: '/modelRepository/models/{modelId}/contents'
    Response type: application/vnd.sas.models.model.
    self GET Returns the metadata information about the model content that is associated with the specified model ID and content ID.
    URI: '/modelRepository/models/{modelId}/contents/{contentId}'
    Response type: application/vnd.sas.models.model.content.
    update PUT Updates the metadata information about the model content that is associated with the specified model ID and content ID.
    URI: '/modelRepository/models/{modelId}/contents/{contentId}'
    Response type: application/vnd.sas.models.model.content.
    delete DELETE Deletes the contents of the model that is associated with the specified model ID and content ID.
    URI: '/modelRepository/models/{modelId}/contents/{contentId}'
    updateContentStream PUT Updates the model content that is associated with the specified model ID and content ID.
    URI: '/modelRepository/models/{modelId}/contents/{contentId}/content'
    Request type: application/octet-stream.
    Response type: application/vnd.sas.models.model.content.
    updateContentMultipart POST Updates the model content that is associated with the specified model ID and content ID.
    URI: '/modelRepository/models/{modelId}/contents/{contentId}/content'
    Request type: multipart/form-data.
    Response type: application/vnd.sas.models.model.content.
    Model Variables

    Path: /models/{modelId}/variables

    This resource contains a collection of model variable.

    The modelVariables representation is application/vnd.sas.models.model.variable.

    The response includes the following links:

    Relation Method Description
    up GET Returns the model that these variables belong to.
    URI: '/modelRepository/models/{modelId}'
    Response type: application/vnd.sas.models.model.
    self GET Returns the variables of a model and the metadata information for the specified model ID.
    URI: '/modelRepository/models/{modelId}/variables'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.variable.
    create POST Adds one or more variables to the model that is associated with the specified model ID.
    URI: '/modelRepository/models/{modelId}/variables'
    Request type: application/vnd.sas.models.model.variable.
    Response type: application/vnd.sas.models.model.variable.
    Model Variable Details

    Path: /models/{modelId}/variables/{variableId}

    This resource contains model variable details.

    The modelVariableDetail representation is application/vnd.sas.models.model.variable.

    The response includes the following links:

    Relation Method Description
    up GET Returns the model to which the model variable belong.
    URI: '/modelRepository/models/{modelId}/variables'
    Response type: application/vnd.sas.models.model.
    self GET Returns the model variable associated with the specified model ID and variable ID.
    URI: '/modelRepository/models/{modelId}/variables/{variableId}'
    Response type: application/vnd.sas.models.model.variable.
    update PUT Updates the model variable that is associated with the specified model ID and variable ID.
    URI: '/modelRepository/models/{modelId}/variables/{variableId}'
    Response type: application/vnd.sas.models.model.variable.
    delete DELETE Deletes the model variable associated with the specified model ID and variable ID.
    URI: '/modelRepository/models/{modelId}/variables/{variableId}'
    Model Versions

    Path: /models/{modelId}/modelVersions

    This resource contains a collection of model version.

    The modelVersions representation is collection of application/vnd.sas.models.model.

    The response includes the following links:

    Relation Method Description
    up GET Returns the model that the versions belong to.
    URI: '/modelRepository/models/{modelId}'
    Response type: application/vnd.sas.models.model.
    self GET Returns the version of a model and the metadata information for the specified model ID.
    URI: '/modelRepository/models/{modelId}/modelVersions'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.
    create POST Creates a new model version for the specified model ID.
    URI: '/modelRepository/models/{modelId}/modelVersions'
    Request type: application/json.
    Response type: application/vnd.sas.models.model.
    Model Version Details

    Path: /models/{modelId}/modelVersions/{versionId}

    This resource contains model version details.

    The modelVersionDetail representation is application/vnd.sas.models.model.

    The response includes the following links:

    Relation Method Description
    up GET Returns the model to which the model version belongs.
    URI: '/modelRepository/models/{modelId}/modelVersions'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.
    self GET Returns information about the model version that is associated with the specified model ID and version ID.
    URI: '/modelRepository/models/{modelId}/modelVersions/{modelVersionId}'
    Response type: application/vnd.sas.models.model.
    Model Analytic Stores

    Path: /models/{modelId}/analyticStore

    This resource contains a collection of analytic store metadata for the model.

    The analyticStore representation is a collection of application/vnd.sas.models.analytic.store.

    The response includes the following links:

    Relation Method Description
    up GET Returns the model that the analytic store belongs to.
    URI: '/modelRepository/models/{modelId}'
    Response type: application/vnd.sas.models.model.
    self GET Returns the collection of analytic stores for a model and the metadata information for the specified model ID.
    URI: '/modelRepository/models/{modelId}/analyticStore'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.analytic.store.
    Model Analytic Store Details

    Path: /models/{modelId}/analyticStore/{analyticStoreName}

    This resource contains details for the analytic store metadata.

    The analyticStore representation is application/vnd.sas.models.analytic.store.

    The response includes the following links:

    Relation Method Description
    up GET Returns the analytic store collection to which the analytic store belongs.
    URI: '/modelRepository/models/{modelId}/analyticStore'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.analytic.store.
    self GET Returns information about the analytic store that is associated with the specified model ID and analytic store name.
    URI: '/modelRepository/models/{modelId}/modelVersions/{analyticStoreName}'
    Response type: application/vnd.sas.models.analytic.store.
    model GET Returns the model that the analytic store belongs to.
    URI: '/modelRepository/models/{modelId}'
    Response type: application/vnd.sas.models.model.
    copy PUT Copies the analytic store to the integration location. The location is pre-defined for SAS Event Stream Processing and SAS Micro Analytics Service integration.
    URI: '/modelRepository/models/{modelId}'
    Response type: application/vnd.sas.models.analytic.store.
    Model Mapped Code

    Path: /models/{modelId}/mappedCode

    This API provides mapped code generated by the score object defined in the Score Definition.

    The mappedCode representation is application/vnd.sas.score.mapped.code.

    Projects

    Path: /projects

    This resource contains a collection of projects.

    Default page size is 20.

    The projects collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.models.project resources. (These types apply to the response for the self, prev, next, first, and last links below.)

    The response includes the following links:

    Relation Method Description
    createProject POST Creates the project within the specified path or a specified folder.
    URI: '/modelRepository/projects'
    Request type: application/vnd.sas.models.project.
    Response type: application/vnd.sas.models.project.
    self GET Returns the current page from the collection.
    URI: '/modelRepository/projects'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    prev GET Returns the previous page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    next GET Returns the next page of resources from the collection. This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    first GET Returns the first page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    last GET Returns the last page of resources from the collection. This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    Project Detail

    Path: /projects/{projectId}

    This resource contains project details that are within a folder.

    The modelProjectDetail representation is application/vnd.sas.models.project.

    The response includes the following links:

    Relation Method Description
    up GET Returns the collection to which this project belongs.
    URI: '/modelRepository/projects'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.
    Response item type: application/vnd.sas.models.project.summary.
    self GET Returns information about a project for the specified project ID.
    URI: '/modelRepository/projects/{projectId}'
    Response type: application/vnd.sas.models.project.
    alternate GET Returns a summary about a project for the specified project ID.
    Response type: application/vnd.sas.models.model.summary.
    delete DELETE Deletes the project with the specified project ID.
    URI: '/modelRepository/projects/{projectId}'
    update PUT Updates the project information for the project that matches the specified criteria and project ID.
    URI: '/modelRepository/projects/{projectId}'
    Response type: application/vnd.sas.models.project.
    projectVersions GET Returns a list of project versions for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/projectVersions'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.version.
    projectModels GET Returns a list of models for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/models'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.
    projectVariables GET Returns the input and output project variables that are associated with the specified project ID.
    URI: '/modelRepository/projects/{projectId}/variables'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.variable.
    projectHistory GET Returns the history information that is associated with the specified project ID.
    URI: '/modelRepository/projects/{projectId}/history'
    Response type: application/vnd.sas.collection.
    championScoreCodeJson GET Returns the champion model score code for the specified project ID, in a JSON format.
    URI: '/modelRepository/projects/{projectId}/champion/code'
    Response type: text/vnd.sas.models.score.code.raw.
    championScoreCodeText GET Returns the champion model score code for the specified project ID, in a text format.
    URI: '/modelRepository/projects/{projectId}/champion/code'
    Response type: text/plain.
    championDS2packageScoreCode GET Returns the champion model score code as a DS2 package for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/champion/code'
    Response type: text/vnd.sas.models.score.code.ds2package.
    championDS2ScoreCode GET Returns the champion model score code as DS2 for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/champion/code'
    Response type: text/vnd.sas.models.score.code.ds2.
    championModel GET Returns the champion model for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/champion'
    Response type: application/vnd.sas.models.model.
    unsetChampion DELETE Clears the champion model role for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/champion'
    challengers GET Returns a list of models for the specified project ID that have a model role of challenger.
    URI: '/modelRepository/projects/{projectId}/challengers'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.
    unsetChallengers DELETE Clears models with the challenger model role that are associated with the specified project ID.
    URI: '/modelRepository/projects/{projectId}/challengers'
    Project Variables

    Path: /projects/{projectId}/variables

    This resource contains a collection of project variables.

    The projectVariables representation is application/vnd.sas.models.model.variable.

    The response includes the following links:

    Relation Method Description
    up GET Returns the project that the variables belong to.
    URI: '/modelRepository/projects/{projectId}'
    Response type: application/vnd.sas.models.project.
    self GET Returns the variables of a project and the metadata information for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/variables'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.variable.
    create POST Adds one or more variables to the project that is associated with the specified project ID.
    URI: '/modelRepository/projects/{projectId}/variables'
    Request type: application/vnd.sas.models.model.variable.
    Response type: application/vnd.sas.models.model.variable.
    Project Variable Details

    Path: /projects/{projectId}/variables/{variableId}

    This resource contains project variable details.

    The projectVariableDetail representation is application/vnd.sas.models.model.variable.

    The response includes the following links:

    Relation Method Description
    up GET Returns the input and output project variables that are associated with the specified project ID.
    URI: '/modelRepository/projects/{projectId}/variables'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.variable.
    self GET Returns the project variable associated with the specified project ID and variable ID.
    URI: '/modelRepository/projects/{projectId}/variables/{variableId}'
    Response type: application/vnd.sas.models.model.variable.
    update PUT Updates the project variable that is associated with the specified project ID and variable ID.
    URI: '/modelRepository/projects/{projectId}/variables/{variableId}'
    Response type: application/vnd.sas.models.model.variable.
    delete DELETE Deletes the project variable associated with the specified project ID and variable ID.
    URI: '/modelRepository/projects/{projectId}/variables'
    Project Contents

    Path: /projects/{projectId}/contents

    This resource contains a collection of project contents.

    The projectContents representation is application/vnd.sas.models.project.content.

    The response includes the following links:

    Relation Method Description
    up GET Returns the project that the contents belongs to.
    URI: '/modelRepository/projects/{projectId}'
    Response type: application/vnd.sas.models.project.
    self GET Returns the contents of a project and the metadata information for the specified model ID.
    URI: '/modelRepository/projects/{projectId}/contents'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.content.
    create POST Adds the specified project file to the project associated with the specified project ID
    URI: '/modelRepository/projects/{projectId}/contents'
    Request type: application/vnd.sas.models.project.content.
    Response type: application/vnd.sas.models.project.content.
    addContent POST Adds the specified project files to the project associated with the specified project ID
    URI: '/modelRepository/projects/{projectId}/contents'
    Request type: multipart/form-data.
    Response type: application/vnd.sas.models.project.content.
    Project Content Details

    Path: /projects/{projectId}/contents/{projectId}

    This resource contains project content details.

    The projectContentDetail representation is application/vnd.sas.models.project.content.

    The response includes the following links:

    Relation Method Description
    up GET Returns the collection to which the project contents belongs to.
    URI: '/modelRepository/projects/{projectId}/contents'
    Response type: application/vnd.sas.models.project.
    self GET Returns the metadata information about the project content that is associated with the specified project ID and content ID.
    URI: '/modelRepository/projects/{projectId}/contents/{contentId}'
    Response type: application/vnd.sas.models.project.content.
    update PUT Updates the metadata information about the project file that is associated with the specified project ID and content ID.
    URI: '/modelRepository/projects/{projectId}/contents/{contentId}'
    Response type: application/vnd.sas.models.project.content.
    delete DELETE Deletes the contents of the project that is associated with the specified project ID and content ID.
    URI: '/modelRepository/projects/{projectId}/contents/{contentId}'
    updateContentMultipart POST Updates the project content that is associated with the specified project ID and content ID.
    URI: '/modelRepository/projects/{projectId}/contents/{contentId}/content'
    Request type: multipart/form-data.
    Response type: application/vnd.sas.models.project.content.
    Project Versions

    Path: /projects/{projectId}/projectVersions

    This resource contains a collection of project versions.

    The projectVersions representation is collection of application/vnd.sas.models.project.version.

    The response includes the following links:

    Relation Method Description
    up GET Returns the project that the project versions belong to.
    URI: '/modelRepository/projects/{projectId}'
    Response type: application/vnd.sas.models.project.
    self GET Returns the project versions of a project and the metadata information for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/projectVersions'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.version.
    create POST Creates a new project version for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/projectVersions'
    Request type: application/json.
    Response type: application/vnd.sas.models.project.version.
    Project Version Details

    Path: /projects/{projectId}/projectVersions/{projectVersionId}

    This resource contains project version details.

    The projectVersionDetail representation is application/vnd.sas.models.project.version.

    The response includes the following links:

    Relation Method Description
    up GET Returns the project versions for the specified project ID.
    URI: '/modelRepository/projects/{projectId}/projectVersions'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.project.version.
    self GET Returns the project version information and that is associated with the specified version ID.
    URI: '/modelRepository/projects/{projectId}/projectVersions/{projectVersionId}'
    Response type: application/vnd.sas.models.project.version.
    update PUT Updates the project version that is associated with the specified version ID.
    URI: '/modelRepository/projects/{projectId}/projectVersions/{projectVersionId}'
    Response type: application/vnd.sas.models.project.version.
    delete DELETE Deletes the project version that is associated with the specified version ID.
    URI: '/modelRepository/projects/{projectId}/projectVersions/{projectVersionId}'
    projectVersionModels GET Returns a list of models for the specified project ID and version ID.
    URI: '/modelRepository/projects/{projectId}/projectVersions/{projectVersionId}/models'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.model.
    Repositories

    Path: /repositories

    This resource contains a collection of model repositories.

    The repository representation is application/vnd.sas.models.repository.

    The response includes the following links:

    Relation Method Description
    up GET Returns the application root API.
    URI: '/modelRepository'
    Response type: application/vnd.sas.api.
    self GET Returns a paginated list of repositories.
    URI: '/modelRepository/repositories'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.repository.
    create POST Creates a new repository.
    URI: '/modelRepository/repositories'
    Request type: application/vnd.sas.models.repository.
    Response type: application/vnd.sas.models.repository.
    Repository Details

    Path: /repositories/{repositoryId}

    This resource contains model repository details.

    The modelRepositoryDetail representation is application/vnd.sas.models.repository.

    The response includes the following links:

    Relation Method Description
    up GET Returns the collection of model repositories.
    URI: '/modelRepository/repositories'
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.models.repository.
    self GET Returns the repository information for the specified repository ID.
    URI: '/modelRepository/repositories/{repositoryId}'
    Response type: application/vnd.sas.models.repository.
    update PUT Updates the repository information for the specified repository ID.
    URI: '/modelRepository/repositories/{repositoryId}'
    Response type: application/vnd.sas.models.repository.
    delete DELETE Deletes the repository with the specified repository ID.
    URI: '/modelRepository/repositories/{repositoryId}'

    Model Publish

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Model Publish API provides support for publishing objects (such as models) to Amazon Web Services (AWS), CAS, Hadoop, Private Docker, SAS Micro Analytic Service, or Teradata.

    Usage Notes

    Overview

    The Model Publish API provides support for publishing objects to CAS, Hadoop, Private Docker, SAS Micro Analytic Service, or Teradata, as well as container destinations such as Amazon Web Services (AWS) and Private Docker.

    Here are the functions that this API provides:

    Note: By default only SAS Administrators can define, update, and delete publishing destinations. Authenticated users can perform all of the other functions.

    For more information, see the following documentation:

    Terminology

    destination

    a location where an object or SAS content is published to.

    decision

    a decision flow that contains a sequential collection of steps for rule sets, models, record contacts, treatments, branches, and conditions that encapsulate an automated decision-making process. A decision has a signature (term list) that is associated with it and that all step objects must map to.

    model

    a formula or algorithm that computes outputs from inputs.

    publish

    deploy an object to a destination, which can be a predefined server, a Docker container, a file system, or a database.

    published object

    an object such as a model, a decision, or a rule set that contains DATA step or DS2 code, and can also contain analytic store files, and a SAS user-defined format, if available.

    rule set

    an ordered set of rule logic with actions that are managed within the Business Rules API. Rule sets are used to make deterministic decisions to indicate statuses such as approved or declined.

    SAS Cloud Analytic Services (CAS)

    a server that provides the cloud-based run-time environment for data management and analytics with SAS.

    SAS Micro Analytic Service

    a real time, memory resident, high-performance program execution service.

    Error Codes

    HTTP Status Code Error Code Description
    400 21900 A value for the destination serverName parameter must be specified.
    400 21901 The valid publish types for the type parameter are "aws", "cas", "microAnalyticServer", "privateDocker", teradata", and "hadoop".
    400 21902 A value for the casLibrary parameter was not specified.
    400 21903 A value for the hdfsDirectory parameter was not specified.
    400 21905 The server name could not be found.
    400 21907 A value for the destination casServerName parameter was not specified.
    400 21908 A value for the configurationDirectory parameter was not specified.
    400 21930 A value for the destinationName a was not specified.
    404 21906 The destination name could not be found.
    409 21904 The server already exists for the destination name that was specified.
    409 21931 The published model already exists in the destination model table.
    500 21932 A license is required for Teradata or Hadoop.

    Operations

    Publish

    Contains the operations for publishing models.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelPublish/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/modelPublish/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/modelPublish/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelPublish/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns a list of links to the top-level resources that are surfaced through this API.

    Example responses

    200 Response

    {
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.

    Check API availability

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelPublish/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/modelPublish/',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.head('https://example.com/modelPublish/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelPublish/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /

    Returns header information and a status of whether the Model Publish service is available.

    Example responses

    200 Response

    {
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    Response Schema

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.

    Check if published models exist

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelPublish/models \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelPublish/models',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.head('https://example.com/modelPublish/models', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelPublish/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /models

    Returns header information for the list of published models.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first published model to return.
    limit query integer(int32) false The maximum number of published models to return.
    filter query string false The criteria for filtering the publishing destinations. See Filtering in REST APIs.
    sortBy query string false The criteria for sorting the publishing destinations. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "analyticStoreUri": [
            "string"
          ],
          "codeType": "string",
          "id": "string",
          "modelId": "string",
          "name": "string",
          "note": "string",
          "type": "string",
          "sourceUri": "string",
          "destination": {
            "name": "string",
            "casServerName": "string",
            "casLibrary": "string",
            "description": "string",
            "destinationTable": "string",
            "destinationType": "string",
            "databaseCasLibrary": "string",
            "user": "string",
            "hdfsDirectory": "string",
            "configurationDirectory": "string",
            "authenticationDomain": "string",
            "masUri": "string",
            "links": [
              {
                "method": "string",
                "rel": "string",
                "uri": "string",
                "href": "string",
                "title": "string",
                "type": "string",
                "itemType": "string",
                "responseType": "string",
                "responseItemType": "string"
              }
            ],
            "createdBy": "string",
            "creationTimeStamp": "2019-08-24T14:15:22Z",
            "modifiedBy": "string",
            "modifiedTimeStamp": "2019-08-24T14:15:22Z",
            "version": 1
          },
          "state": "string",
          "verified": false,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "version": 1
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. publishModelCollection

    Get a list of published models

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelPublish/models \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelPublish/models',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelPublish/models', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelPublish/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models

    Returns a list of published models.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first published model to return.
    limit query integer(int32) false The maximum number of published models to return.
    filter query string false The criteria for filtering the publishing destinations. See Filtering in REST APIs.
    sortBy query string false The criteria for sorting the publishing destinations. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "analyticStoreUri": [
            "string"
          ],
          "codeType": "string",
          "id": "string",
          "modelId": "string",
          "name": "string",
          "note": "string",
          "type": "string",
          "sourceUri": "string",
          "destination": {
            "name": "string",
            "casServerName": "string",
            "casLibrary": "string",
            "description": "string",
            "destinationTable": "string",
            "destinationType": "string",
            "databaseCasLibrary": "string",
            "user": "string",
            "hdfsDirectory": "string",
            "configurationDirectory": "string",
            "authenticationDomain": "string",
            "masUri": "string",
            "links": [
              {
                "method": "string",
                "rel": "string",
                "uri": "string",
                "href": "string",
                "title": "string",
                "type": "string",
                "itemType": "string",
                "responseType": "string",
                "responseItemType": "string"
              }
            ],
            "createdBy": "string",
            "creationTimeStamp": "2019-08-24T14:15:22Z",
            "modifiedBy": "string",
            "modifiedTimeStamp": "2019-08-24T14:15:22Z",
            "version": 1
          },
          "state": "string",
          "verified": false,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "version": 1
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. publishModelCollection

    Publish models

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelPublish/models \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.publishing.request' \
      -H 'Accept: application/vnd.sas.models.publishing.model+json' \
      -H 'Authorization: string'
    
    
    const inputBody = '{
      "description": "string",
      "modelContents": [
        {
          "analyticStoreUri": [
            "string"
          ],
          "code": "string",
          "codeType": "string",
          "format": "string",
          "modelName": "string",
          "modelId": "string",
          "sourceUri": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "version": 1
        }
      ],
      "name": "string",
      "note": "string",
      "destinationName": "string",
      "verified": false,
      "version": 1
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.publishing.request',
      'Accept':'application/vnd.sas.models.publishing.model+json',
      'Authorization':'string'
    };
    
    fetch('https://example.com/modelPublish/models',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.publishing.request',
      'Accept': 'application/vnd.sas.models.publishing.model+json',
      'Authorization': 'string'
    }
    
    r = requests.post('https://example.com/modelPublish/models', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.publishing.request"},
            "Accept": []string{"application/vnd.sas.models.publishing.model+json"},
            "Authorization": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelPublish/models", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models

    Publish one or more models to a CAS server, Hadoop, SAS Micro Analytic Service, or a Teradata database.

    Body parameter

    {
      "description": "string",
      "modelContents": [
        {
          "analyticStoreUri": [
            "string"
          ],
          "code": "string",
          "codeType": "string",
          "format": "string",
          "modelName": "string",
          "modelId": "string",
          "sourceUri": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "version": 1
        }
      ],
      "name": "string",
      "note": "string",
      "destinationName": "string",
      "verified": false,
      "version": 1
    }
    
    Parameters
    Name In Type Required Description
    reuseExistingModules query boolean false Reuse the published modules.
    promoteModelTable query boolean false Indicates whether to promote the destination table.
    Authorization header string true Authorization
    body body publishRequest true pReq

    Example responses

    201 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The models were published. destinationCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelPublish/models/{publishId}
    201 ETag string A tag that identifies the revision of this object.

    Check if a published model exists

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelPublish/models/{publishId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/modelPublish/models/{publishId}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.head('https://example.com/modelPublish/models/{publishId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelPublish/models/{publishId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /models/{publishId}

    Returns header information for a published model.

    Parameters
    Name In Type Required Description
    publishId path string true publishId

    Example responses

    200 Response

    {
      "analyticStoreUri": [
        "string"
      ],
      "codeType": "string",
      "id": "string",
      "modelId": "string",
      "name": "string",
      "note": "string",
      "type": "string",
      "sourceUri": "string",
      "destination": {
        "name": "string",
        "casServerName": "string",
        "casLibrary": "string",
        "description": "string",
        "destinationTable": "string",
        "destinationType": "string",
        "databaseCasLibrary": "string",
        "user": "string",
        "hdfsDirectory": "string",
        "configurationDirectory": "string",
        "authenticationDomain": "string",
        "masUri": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "version": 1
      },
      "state": "string",
      "verified": false,
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. publishModel
    404 Not Found No published model exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.

    Get published models

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelPublish/models/{publishId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/modelPublish/models/{publishId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.get('https://example.com/modelPublish/models/{publishId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelPublish/models/{publishId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{publishId}

    Returns published models.

    Parameters
    Name In Type Required Description
    publishId path string true The identifier for the published models.

    Example responses

    200 Response

    {
      "analyticStoreUri": [
        "string"
      ],
      "codeType": "string",
      "id": "string",
      "modelId": "string",
      "name": "string",
      "note": "string",
      "type": "string",
      "sourceUri": "string",
      "destination": {
        "name": "string",
        "casServerName": "string",
        "casLibrary": "string",
        "description": "string",
        "destinationTable": "string",
        "destinationType": "string",
        "databaseCasLibrary": "string",
        "user": "string",
        "hdfsDirectory": "string",
        "configurationDirectory": "string",
        "authenticationDomain": "string",
        "masUri": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "version": 1
      },
      "state": "string",
      "verified": false,
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. publishModel
    404 Not Found No published models exist at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.

    Get the mapped code for a model

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelPublish/models/{publishId}/mappedCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/modelPublish/models/{publishId}/mappedCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/modelPublish/models/{publishId}/mappedCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelPublish/models/{publishId}/mappedCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /models/{publishId}/mappedCode

    Returns the code to be able to run the model based on the provided data and mapping information in request.

    Body parameter

    {
      "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    Parameters
    Name In Type Required Description
    publishId path string true The ID of the published model.
    body body #/paths/~1models~1%7BpublishId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request%2Bjson/schema true The information for scoreDefinitionId and hints.

    Example responses

    200 Response

    {
      "code": "/* DS2 code of an object, which generates an XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS"
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    500 Internal Server Error The request could not be fulfilled because of an unexpected server error. Inline
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 1.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 500

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a published model log

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelPublish/models/{publishId}/log \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/modelPublish/models/{publishId}/log',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.get('https://example.com/modelPublish/models/{publishId}/log', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelPublish/models/{publishId}/log", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /models/{publishId}/log

    Returns a published model log.

    Parameters
    Name In Type Required Description
    publishId path string true The identifier of the published model log.

    Example responses

    200 Response

    {
      "id": "string",
      "modelId": "string",
      "modelName": "string",
      "publishName": "string",
      "note": "string",
      "destinationName": "string",
      "log": "string",
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. log

    Destinations

    Contains the operations for publishing destinations.

    Check publishing destinations availability

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelPublish/destinations \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelPublish/destinations',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.head('https://example.com/modelPublish/destinations', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelPublish/destinations", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /destinations

    Returns header information for a list of publishing destinations.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first publishing destination to return.
    limit query integer(int32) false The maximum number of publishing destinations to return.
    filter query string false The criteria for filtering the publishing destinations. See Filtering in REST APIs.
    sortBy query string false The criteria for sorting the publishing destinations. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "string",
          "casServerName": "string",
          "casLibrary": "string",
          "description": "string",
          "destinationTable": "string",
          "destinationType": "string",
          "databaseCasLibrary": "string",
          "user": "string",
          "hdfsDirectory": "string",
          "configurationDirectory": "string",
          "authenticationDomain": "string",
          "masUri": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "version": 1
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. destinationCollection

    Get a list of publishing destinations

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelPublish/destinations \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/modelPublish/destinations',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/modelPublish/destinations', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelPublish/destinations", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /destinations

    Returns a list of publishing destinations.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first publishing destination to return.
    limit query integer(int32) false The maximum number of publishing destinations to return.
    filter query string false The criteria for filtering the publishing destinations. See Filtering in REST APIs.
    sortBy query string false The criteria for sorting the publishing destinations. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "string",
          "casServerName": "string",
          "casLibrary": "string",
          "description": "string",
          "destinationTable": "string",
          "destinationType": "string",
          "databaseCasLibrary": "string",
          "user": "string",
          "hdfsDirectory": "string",
          "configurationDirectory": "string",
          "authenticationDomain": "string",
          "masUri": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "version": 1
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. destinationCollection

    Create a publishing destination

    Code samples

    # You can also use wget
    curl -X POST https://example.com/modelPublish/destinations \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.publishing.destination' \
      -H 'Accept: application/vnd.sas.models.publishing.destination+json'
    
    
    const inputBody = '{
      "name": "string",
      "casServerName": "string",
      "casLibrary": "string",
      "description": "string",
      "destinationTable": "string",
      "destinationType": "string",
      "databaseCasLibrary": "string",
      "user": "string",
      "hdfsDirectory": "string",
      "configurationDirectory": "string",
      "authenticationDomain": "string",
      "masUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.publishing.destination',
      'Accept':'application/vnd.sas.models.publishing.destination+json'
    };
    
    fetch('https://example.com/modelPublish/destinations',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.publishing.destination',
      'Accept': 'application/vnd.sas.models.publishing.destination+json'
    }
    
    r = requests.post('https://example.com/modelPublish/destinations', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.publishing.destination"},
            "Accept": []string{"application/vnd.sas.models.publishing.destination+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/modelPublish/destinations", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /destinations

    Creates a publishing destination.

    Body parameter

    {
      "name": "string",
      "casServerName": "string",
      "casLibrary": "string",
      "description": "string",
      "destinationTable": "string",
      "destinationType": "string",
      "databaseCasLibrary": "string",
      "user": "string",
      "hdfsDirectory": "string",
      "configurationDirectory": "string",
      "authenticationDomain": "string",
      "masUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    Parameters
    Name In Type Required Description
    body body destination true Creates a publishing destination.

    Example responses

    201 Response

    {
      "name": "string",
      "casServerName": "string",
      "casLibrary": "string",
      "description": "string",
      "destinationTable": "string",
      "destinationType": "string",
      "databaseCasLibrary": "string",
      "user": "string",
      "hdfsDirectory": "string",
      "configurationDirectory": "string",
      "authenticationDomain": "string",
      "masUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The publishing destination was created. destination
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string /modelPublish/destinations/{destinationName}
    201 ETag string A tag that identifies the revision of this object.

    Check publishing destination by name

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/modelPublish/destinations/{destinationName} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.publishing.destination+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.publishing.destination+json'
    };
    
    fetch('https://example.com/modelPublish/destinations/{destinationName}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.publishing.destination+json'
    }
    
    r = requests.head('https://example.com/modelPublish/destinations/{destinationName}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.publishing.destination+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/modelPublish/destinations/{destinationName}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /destinations/{destinationName}

    Returns the header information for a publishing destination by name.

    Parameters
    Name In Type Required Description
    destinationName path string true destinationName

    Example responses

    200 Response

    {
      "name": "string",
      "casServerName": "string",
      "casLibrary": "string",
      "description": "string",
      "destinationTable": "string",
      "destinationType": "string",
      "databaseCasLibrary": "string",
      "user": "string",
      "hdfsDirectory": "string",
      "configurationDirectory": "string",
      "authenticationDomain": "string",
      "masUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. destination
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.

    Get a publishing destination by name

    Code samples

    # You can also use wget
    curl -X GET https://example.com/modelPublish/destinations/{destinationName} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.models.publishing.destination+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.models.publishing.destination+json'
    };
    
    fetch('https://example.com/modelPublish/destinations/{destinationName}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.models.publishing.destination+json'
    }
    
    r = requests.get('https://example.com/modelPublish/destinations/{destinationName}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.models.publishing.destination+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/modelPublish/destinations/{destinationName}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /destinations/{destinationName}

    Returns a publishing destination by name.

    Parameters
    Name In Type Required Description
    destinationName path string true destinationName

    Example responses

    200 Response

    {
      "name": "string",
      "casServerName": "string",
      "casLibrary": "string",
      "description": "string",
      "destinationTable": "string",
      "destinationType": "string",
      "databaseCasLibrary": "string",
      "user": "string",
      "hdfsDirectory": "string",
      "configurationDirectory": "string",
      "authenticationDomain": "string",
      "masUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. destination
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies the revision of this object.

    Update a publishing destination

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/modelPublish/destinations/{destinationName} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.models.publishing.destination' \
      -H 'Accept: application/vnd.sas.models.publishing.destination+json' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "name": "string",
      "casServerName": "string",
      "casLibrary": "string",
      "description": "string",
      "destinationTable": "string",
      "destinationType": "string",
      "databaseCasLibrary": "string",
      "user": "string",
      "hdfsDirectory": "string",
      "configurationDirectory": "string",
      "authenticationDomain": "string",
      "masUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.models.publishing.destination',
      'Accept':'application/vnd.sas.models.publishing.destination+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/modelPublish/destinations/{destinationName}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.models.publishing.destination',
      'Accept': 'application/vnd.sas.models.publishing.destination+json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/modelPublish/destinations/{destinationName}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.models.publishing.destination"},
            "Accept": []string{"application/vnd.sas.models.publishing.destination+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/modelPublish/destinations/{destinationName}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /destinations/{destinationName}

    Updates a publishing destination.

    Body parameter

    {
      "name": "string",
      "casServerName": "string",
      "casLibrary": "string",
      "description": "string",
      "destinationTable": "string",
      "destinationType": "string",
      "databaseCasLibrary": "string",
      "user": "string",
      "hdfsDirectory": "string",
      "configurationDirectory": "string",
      "authenticationDomain": "string",
      "masUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    Parameters
    Name In Type Required Description
    If-Match header string true If-Match
    destinationName path string true destinationName
    body body destination true pReq

    Example responses

    200 Response

    {
      "name": "string",
      "casServerName": "string",
      "casLibrary": "string",
      "description": "string",
      "destinationTable": "string",
      "destinationType": "string",
      "databaseCasLibrary": "string",
      "user": "string",
      "hdfsDirectory": "string",
      "configurationDirectory": "string",
      "authenticationDomain": "string",
      "masUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. destination
    400 Bad Request The request was invalid. errorResponse
    412 Precondition Failed ETag is not matched. Inline
    428 Precondition Required The request headers did not include a 'If-Match' or 'If-Unmodified-Since' precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1models/post/responses/400/content/application~1vnd.sas.models.publishing.model%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Etag string A tag that identifies the revision of this object.

    Delete a publishing destination

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/modelPublish/destinations/{destinationName}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/modelPublish/destinations/{destinationName}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/modelPublish/destinations/{destinationName}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/modelPublish/destinations/{destinationName}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /destinations/{destinationName}

    Deletes a publishing destination by name.

    Parameters
    Name In Type Required Description
    destinationName path string true The destination name.
    Responses
    Status Meaning Description Schema
    204 No Content The publishing destination was deleted. None

    Schemas

    destinationCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "string",
          "casServerName": "string",
          "casLibrary": "string",
          "description": "string",
          "destinationTable": "string",
          "destinationType": "string",
          "databaseCasLibrary": "string",
          "user": "string",
          "hdfsDirectory": "string",
          "configurationDirectory": "string",
          "authenticationDomain": "string",
          "masUri": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "version": 1
        }
      ]
    }
    
    

    Destination Resource Collection

    Properties
    Name Type Required Restrictions Description
    Destination Resource Collection any false none A collection of destination representations.

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [link] false none The links that apply to the collection.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [destination] false none The array of application/vnd.sas.models.publishing.destination representations.

    destination

    {
      "name": "string",
      "casServerName": "string",
      "casLibrary": "string",
      "description": "string",
      "destinationTable": "string",
      "destinationType": "string",
      "databaseCasLibrary": "string",
      "user": "string",
      "hdfsDirectory": "string",
      "configurationDirectory": "string",
      "authenticationDomain": "string",
      "masUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    

    Publishing Destination

    Properties
    Name Type Required Restrictions Description
    name string true none The name of the publishing destination server.
    casServerName string false none The name of the CAS server.
    casLibrary string false none The name of the CAS library.
    description string false none The description of the destination server.
    destinationTable string false none The name of the publishing destination table.
    destinationType string false none The destination type can be "cas", "microAnalyticServer", "teradata", or "hadoop".
    databaseCasLibrary string false none The pre-defined CAS library that was used by Teradata.
    user string false none The user name of Hadoop.
    hdfsDirectory string false none The root HDFS folder where the model directory is to be created.
    configurationDirectory string false none The class path for Hadoop JAR files. For example: /opt/hadoopjars
    authenticationDomain string false none The name of the authentication domain that contains the remote login information for publishing users to gain access to the remote environment for the SAS Micro Analytic Service. For example: remoteAuthDomain
    masUri string false none The base URI that contains the host, the protocol, and optionally the port, which addresses the remote SAS Micro Analytic Service that this destination publishes to for this destination. For example: http://hostA.com
    links [object] false none links
    » Link object false none A link to a related operation or resource.
    »» method string false none The HTTP method for the link.
    »» rel string true none The relationship of the link to the resource.
    »» uri string false none The relative URI for the link.
    »» href string false none The URL for the link.
    »» title string false none The title for the link.
    »» type string false none The media type or link type for the link.
    »» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    createdBy string false none The user who created the object.
    creationTimeStamp string(date-time) false none The timestamp for when the object was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedBy string false none The user who most recently modified the object.
    modifiedTimeStamp string(date-time) false none The timestamp for when the object was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    version integer false none The API representation version.

    publishContent

    {
      "analyticStoreUri": [
        "string"
      ],
      "code": "string",
      "codeType": "string",
      "format": "string",
      "modelName": "string",
      "modelId": "string",
      "sourceUri": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    

    Model Publishing Content

    Properties
    Name Type Required Restrictions Description
    analyticStoreUri [string] false none The URI point to the analytic store in the CAS library.
    code string true none The model score code.
    codeType string true none The code type can be datastep or ds2.
    format string false none The format used to determine how the values of a variable should be written or displayed.
    modelName string true none The name of the model.
    modelId string false none The model ID that can be used by the client to find their published model.
    sourceUri string false none This URI represents where the model came from.
    createdBy string false none The user who created the object.
    creationTimeStamp string(date-time) false none The timestamp for when the object was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedBy string false none The user who most recently modified the object.
    modifiedTimeStamp string(date-time) false none The timestamp for when the object was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    version integer false none The API representation version.

    publishRequest

    {
      "description": "string",
      "modelContents": [
        {
          "analyticStoreUri": [
            "string"
          ],
          "code": "string",
          "codeType": "string",
          "format": "string",
          "modelName": "string",
          "modelId": "string",
          "sourceUri": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "version": 1
        }
      ],
      "name": "string",
      "note": "string",
      "destinationName": "string",
      "verified": false,
      "version": 1
    }
    
    

    Publish Model Request

    Properties
    Name Type Required Restrictions Description
    description string false none The description for the published model.
    modelContents [publishContent] true none A list of models.
    name string true none The published name of a model.
    note string false none The description for the published model.
    destinationName string false none The name of the publishing destination.
    verified boolean false none Indicates whether the model is verified.
    version integer false none The API representation version.

    publishModelCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "analyticStoreUri": [
            "string"
          ],
          "codeType": "string",
          "id": "string",
          "modelId": "string",
          "name": "string",
          "note": "string",
          "type": "string",
          "sourceUri": "string",
          "destination": {
            "name": "string",
            "casServerName": "string",
            "casLibrary": "string",
            "description": "string",
            "destinationTable": "string",
            "destinationType": "string",
            "databaseCasLibrary": "string",
            "user": "string",
            "hdfsDirectory": "string",
            "configurationDirectory": "string",
            "authenticationDomain": "string",
            "masUri": "string",
            "links": [
              {
                "method": "string",
                "rel": "string",
                "uri": "string",
                "href": "string",
                "title": "string",
                "type": "string",
                "itemType": "string",
                "responseType": "string",
                "responseItemType": "string"
              }
            ],
            "createdBy": "string",
            "creationTimeStamp": "2019-08-24T14:15:22Z",
            "modifiedBy": "string",
            "modifiedTimeStamp": "2019-08-24T14:15:22Z",
            "version": 1
          },
          "state": "string",
          "verified": false,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "version": 1
        }
      ]
    }
    
    

    Published Model Resource Collection

    Properties
    Name Type Required Restrictions Description
    Published Model Resource Collection any false none A collection of published model representations.

    allOf

    Name Type Required Restrictions Description
    anonymous destinationCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [publishModel] false none The array of application/vnd.sas.models.publishing.model representations.

    publishModel

    {
      "analyticStoreUri": [
        "string"
      ],
      "codeType": "string",
      "id": "string",
      "modelId": "string",
      "name": "string",
      "note": "string",
      "type": "string",
      "sourceUri": "string",
      "destination": {
        "name": "string",
        "casServerName": "string",
        "casLibrary": "string",
        "description": "string",
        "destinationTable": "string",
        "destinationType": "string",
        "databaseCasLibrary": "string",
        "user": "string",
        "hdfsDirectory": "string",
        "configurationDirectory": "string",
        "authenticationDomain": "string",
        "masUri": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "version": 1
      },
      "state": "string",
      "verified": false,
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 1
    }
    
    

    Published Model

    Properties
    Name Type Required Restrictions Description
    analyticStoreUri [string] false none A list of CAS table URIs for each analytic store.
    codeType string false none The score code type for the model.
    id string false none The ID of the published model.
    modelId string false none The model ID from source application.
    name string false none The published name for a model.
    note string false none The description of the published model.
    type string false none Publish type can be one of the following: cas, microAnalyticServer, teradata, hadoop
    sourceUri string false none The URI of the source reference.
    destination destination false none Contains information about a publishing destination.
    state string false none The state of the published model (pending, running, completed, failed).
    verified boolean false none Indicates whether the model has been is verified.
    createdBy string false none The user who created the object.
    creationTimeStamp string(date-time) false none The timestamp for when the object was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedBy string false none The user who most recently modified the object.
    modifiedTimeStamp string(date-time) false none The timestamp for when the object was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    version integer false none The API representation version.

    log

    {
      "id": "string",
      "modelId": "string",
      "modelName": "string",
      "publishName": "string",
      "note": "string",
      "destinationName": "string",
      "log": "string",
      "version": 1
    }
    
    

    Published Model Log

    Properties
    Name Type Required Restrictions Description
    id string false none The ID of the publish log.
    modelId string false none The ID of the model.
    modelName string false none The name of the model.
    publishName string false none The published name for the model
    note string false none The description of the published model.
    destinationName string false none The name of the publishing destination.
    log string false none The log for this published model.
    version integer false none The API representation version.

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    application/vnd.sas.models.publishing.model

    Contains details for publishing an object (such as a model, a decision, or a rule set) to a destination server.

    The schema is at publishModel.

    application/vnd.sas.models.publishing.model+json

    Here is an example of the JSON representation of this media type.

    
     {
       "creationTimeStamp":"2017-08-18T18:34:50.173Z",
       "modifiedTimeStamp":"2017-08-18T18:34:50.173Z",
       "createdBy":"userId",
       "modifiedBy":"userId",
       "version":1,
       "id":"04d65048-78a9-441c-98df-d4aa7b014687",
       "publishName":"reg1",
       "publishType":"casModel",
       "verified":false,
       "destinationName": "casDestination",
       "codeType":"dataStep",
       "analyticStoreUri":[
         "/dataTables/dataSources/cas~fs~cas-shared-default~fs~Public/tables/HMEQ"
       ],
       "sourceUri":"/modelRepository/models/dscodeModelId/code",
       "note":"Publishing a model",
       "properties":{
          "property2":"anyValue",
          "property1":"anyValue"
       },
       "links":[
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelPublish/models/04d65048-78a9-441c-98df-d4aa7b014687",
             "uri":"/modelPublish/models/04d65048-78a9-441c-98df-d4aa7b014687",
             "type":"application/vnd.sas.models.publishing.model"
          }
       ]
    }
    
    application/vnd.sas.models.publishing.request

    Describes publishing an object (such as a model, a decision, or a rule set) to the predefined destination.

    The schema is at publishRequest.

    application/vnd.sas.models.publishing.request+json

    Here is an example of the JSON representation of this media type.

    
     {
        "name":"Published model name",
        "note" : "Publishing a model",
        "modelContents":[
            {
                "modelName": "model5",
                "principalId": "clientsideId1",
                "codeType": "ds2",
                "code":"-------------some ds2 code in there.---------------",
                "analyticStoreUri":[
                    "/dataTables/dataSources/cas~fs~cas-shared-default~fs~Public/tables/HMEQ"
                ],
                "sourceUri": "/modelRepository/models/ds2"
            }
        ],
        "properties":{
            "property1":"anyValue",
            "property2":"anyValue"
        },
        "destinationName":"myDestination",
        "version":1
    }
    
    application/vnd.sas.models.publishing.request.asynchronous

    Describes publishing an object (such as a model, a decision, or a rule set) to the predefined destination.

    The schema is at publishRequest.

    application/vnd.sas.models.publishing.request.asynchronous+json

    The example of the JSON representation is same as application/vnd.sas.models.publishing.request

    application/vnd.sas.score.mapped.code

    This type is used as a response to request for execution code made with application/vnd.sas.score.execution.request to generate code that is mapped to specific data based on the request.

    The codeType that is returned within mappedCode is always text/vnd.sas.source.ds2 for this version of the service.

    See application/vnd.sas.score.mapped.code

    application/vnd.sas.models.publishing.destination

    Contains details for a publishing destination. The destination is the place where an object or SAS content is published to. The destination type includes Amazon Web Service, CAS, Hadoop, Private Docker, SAS Micro Analytic Service, and Teradata.

    Valid values for the destinationType are: aws, cas, microAnalyticService, privateDocker, teradata, or hadoop

    The schema is at destination.

    application/vnd.sas.models.publishing.destination+json

    Here is an example of the JSON representation of this media type.

    
     {
       "creationTimeStamp":"2017-08-18T18:20:22.141Z",
       "modifiedTimeStamp":"2017-08-18T18:20:22.141Z",
       "createdBy":"userId",
       "modifiedBy":"userId",
       "id":"0ffb714c-ede7-4a70-beaf-e66d805601c8",
       "links":[
          {
             "method":"GET",
             "rel":"up",
             "href":"/modelPublish/destinations",
             "uri":"/modelPublish/destinations",
             "type":"application/vnd.sas.collection"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/modelPublish/destinations/myServer1",
             "uri":"/modelPublish/destinations/myServer1",
             "type":"application/vnd.sas.models.publishing.destination"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/modelPublish/destinations/myServer1",
             "uri":"/modelPublish/destinations/myServer1",
             "type":"application/vnd.sas.models.publishing.destination"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/modelPublish/destinations/myServer1",
             "uri":"/modelPublish/destinations/myServer1"
          }
       ],
       "version":1,
       "name":"myServer1",
       "destinationType":"cas",
       "casServerName":"newcas",
       "casLibrary" : "Public",
       "destinationTable" : "ModelTable",
       "properties": [{'name': 'myName',                
                     'value': 'myValue'}
                     ]
    }
    
    application/vnd.sas.models.publishing.destination.cas
    application/vnd.sas.models.publishing.destination.cas+json

    Defines a CAS destination.

    The schema is at destinationCas.

    
     {
        "name":"myCasDestination",
        "casServerName":"casServerName",
        "casLibrary" : "CASUSER(userId)",
        "destinationTable" : "ModelTable",
        "version":1
    }
    
    application/vnd.sas.models.publishing.destination.teradata
    application/vnd.sas.models.publishing.destination.teradata+json

    Defines a Teradata destination.

    The schema is at destinationTeradata.

    
     {
        "name":"myTeradataDestination",
        "casLibrary":"CASUSER(userId)",
        "casServerName":"casServerName",
        "databaseCasLibrary": "teradataLib",
        "destinationTable":"ModelTable3",
        "version":1,
    }
    
    application/vnd.sas.models.publishing.destination.hadoop
    application/vnd.sas.models.publishing.destination.hadoop+json

    Defines a Hadoop destination.

    The schema is at destinationHadoop.

    
     {
        "name":"myHadoopDestination",
        "casServerName":"casServerName",
        "casLibrary" : "CASUSER(userId)",
        "destinationTable" : "ModelTable2",
        "hdfsDirectory" : "/tmp/mmlib",
        "configurationDirectory" : "/opt/hadoopjars",
        "user":"userId",
        "version":1
    }
    
    application/vnd.sas.models.publishing.destination.mas
    application/vnd.sas.models.publishing.destination.mas+json

    Defines a SAS Micro Analytic Service destination.

    The schema is at destinationMas.

    
     {
        "name":"myMas",
        "masUri" : "http://host.com",
        "authenticationDomain" : "myDomain",
        "version":1
    }
    
    application/vnd.sas.models.publishing.destination.aws
    application/vnd.sas.models.publishing.destination.aws+json

    Defines an Amazon Web Services (AWS) destination.

    The schema is at destinationAws.

    
     {
        "name":"myAws",
        "destinationType":"aws",
        "properties": [{'name': 'accessKeyId',   
                     'value': 'myAccessKeyId'},
                    {'name': 'secretAccessKey',        
                     'value': 'myAccessKey'},
                    {'name': 'region',
                     'value': 'us-east-1'},
                    {'name': 'kubernetesCluster',              
                     'value': 'myeks'}
                       ]
        "version":1
    }
    
    application/vnd.sas.models.publishing.destination.privatedocker
    application/vnd.sas.models.publishing.destination.privatedocker+json

    Defines a Private Docker destination.

    The schema is at destinationPrivateDocker.

    
     {
        "name":"myDocker",
        "destinationType":"privateDocker",
        "properties": [{'name': 'baseRepoUrl',
                     'value': 'docker.mycompany.com/myfolder'},
                   {'name': 'dockerHost',
                     'value': 'tcp://10.10.10.88:2375'}
                       ]
        "version":1
    }
    
    Root

    Path: /

    The root returns a collection of links to the top-level resources that are surfaced through this API. The response uses the application/vnd.sas.api media type.

    The response includes the following links:

    Relation Method Description
    destinations GET Returns the first page of the collection of destinations.
    Response type: application/vnd.sas.collection
    Response item type: application/vnd.sas.summary
    Response item type: application/vnd.sas.models.publishing.destination.
    createDestination POST Creates a destination server.
    Request type: application/vnd.sas.models.publishing.destination
    Response type: application/vnd.sas.models.publishing.destination
    createDestinationCAS POST Creates a CAS destination.
    Request type: application/vnd.sas.models.publishing.destination.cas
    Response type: application/vnd.sas.models.publishing.destination.cas
    createDestinationMAS POST Creates a SAS Micro Analytic Service destination.
    Request type: application/vnd.sas.models.publishing.destination.mas
    Response type: application/vnd.sas.models.publishing.destination.mas
    createDestinationTeradata POST Creates a Teradata destination.
    Request type: application/vnd.sas.models.publishing.destination.teradata
    Response type: application/vnd.sas.models.publishing.destination.teradata
    createDestinationHadoop POST Creates a Hadoop destination.
    Request type: application/vnd.sas.models.publishing.destination.hadoop
    Response type: application/vnd.sas.models.publishing.destination.hadoop
    createDestinationAWS POST Creates an Amazon Web Services (AWS) destination.
    Request type: application/vnd.sas.models.publishing.destination.aws
    Response type: application/vnd.sas.models.publishing.destination.aws
    createDestinationPrivateDocker POST Creates a Private Docker destination.
    Request type: application/vnd.sas.models.publishing.destination.privatedocker
    Response type: application/vnd.sas.models.publishing.destination.privatedocker
    models GET Returns the first page of the collection of published objects (such as models, decisions, and rule sets).
    Response type: application/vnd.sas.collection
    Response item type: application/vnd.sas.models.publishing.model
    publishModel POST Publishes an object (such as a model, a decision or a rule set) to destination server.
    Request type: application/vnd.sas.models.publishing.request
    Request type: application/vnd.sas.models.publishing.request.asynchronous
    Response type: application/vnd.sas.models.publishing.model
    Destinations

    Path: /destinations

    This resource contains a collection of destinations.

    Default page size is 20.

    The destinations collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.models.publishing.destination resources or application/vnd.sas.summary. These types apply to the response for the self, prev, next, first, and last links below.

    The response includes the following links:

    Relation Method Description
    createDestination POST Creates a destination.
    Request type: application/vnd.sas.models.publishing.destination
    Response type: application/vnd.sas.models.publishing.destination
    self GET Returns the current page from the collection.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection. This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection. This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection. This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Destination Details

    Path: /destinations/{destinationName}

    Describes the destination information, which includes destination name, type, host, and database information, if applicable.

    The destinationDetail representation is application/vnd.sas.models.publishing.destination.

    The response includes the following links:

    Relation Method Description
    up GET Returns the destination collection.
    Response type: application/vnd.sas.collection
    Response item type: application/vnd.sas.models.publishing.destination.
    self GET Returns information about a destination for the specified destination name.
    Response type: application/vnd.sas.models.publishing.destination.
    delete DELETE Deletes a server with the specified destination name.
    head HEAD Returns the destination header information for the specified destination name.
    Response type: application/vnd.sas.models.publishing.destination
    update PUT Updates the destination information for the destination that matches the specified criteria and destination name.
    Response type: application/vnd.sas.models.publishing.destination
    Published Objects

    Path: /models

    This resource contains a collection of published objects (such as models, decisions, and rule sets).

    Default page size is 20.

    The publish collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.models.publishing.model resources or application/vnd.sas.summary. (These types apply to the response for the self, prev, next, first, and last links below.)

    The response includes the following links:

    Relation Method Description
    self GET Returns the current page from the collection.
    Response type: application/vnd.sas.collection
    prev GET Returns the previous page of resources from the collection.
    Present if not at the start of the collection.
    Response type: application/vnd.sas.collection
    next GET Returns the next page of resources from the collection.
    Present if not at the end of the collection.
    Response type: application/vnd.sas.collection
    first GET Returns the first page of resources from the collection.
    Present if not at the start of the collection.
    Response type: application/vnd.sas.collection
    last GET Returns the last page of resources from the collection.
    Present if not at the end of the collection.
    Response type: application/vnd.sas.collection
    publishedModels POST Publish a model to a destination server.
    Request type: application/vnd.sas.models.publishing.model
    Response type: application/vnd.sas.models.publishing.model
    Published Object Details

    Path: /models/{publishId}

    Contains detailed information about the published object (such as a model, a decision, or a rule set).

    The publishDetail representation is application/vnd.sas.models.publishing.model.

    The response includes the following links:

    Relation Method Description
    up GET Returns the published object collection.
    Response type: application/vnd.sas.collection
    Response item type: application/vnd.sas.models.publishing.model
    self GET Returns information about a published object for the specified publish ID.
    Response type: application/vnd.sas.models.publishing.model
    head HEAD Returns header information about a published object for the specified publish ID.
    Response type: application/vnd.sas.models.publishing.model
    mappedCode POST Returns the mapped code object for execution in the Score Execution service.
    Request type: application/vnd.sas.score.code.generation.request
    Response type: application/vnd.sas.score.mapped.code
    Mapped Code

    Path: /models/{publishId}/mappedCode

    Responds with a full executable program based on application/vnd.sas.score.code.generation.request, which is provided within the request.

    The mappedCode response representation is application/vnd.sas.score.mapped.code, which contains the generated code.

    Micro Analytic Score

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers License: SAS Institute

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Micro Analytic Score API provides stateless, memory-resident, high-performance program execution.

    Usage Notes

    Overview

    SAS Micro Analytic Service is an analytics execution engine with an emphasis on small footprint and high-speed transaction processing rather than batch processing. The Micro Analytic Score API enables SAS analytics, in the form of a micro analytic service module, to be embedded within or alongside a device and provide in-memory execution of SAS analytics and logic. Other uses of this API are applications that require decision making into near real-time and transaction-based production systems. For these applications, micro analytic modules are loaded and executed to provide the near real-time decision results.

    DS2 code, analytic store (ASTORE), and open-source Python code can be compiled by the Micro Analytic Score API and stored in memory as individual steps that are available for execution. Here is the domain terminology that is associated with this functionality:

    When a module is compiled and available in memory, the published micro-analytic steps are available for execution. Only steps of public modules can be executed externally by a client. Private modules are reusable analytic code components. Though they are not directly available for execution, they are used to compose larger and more complex public modules.

    Every step requires input data to execute and generate output. The description of the input and output data is called the signature. When input data is submitted for execution, the Micro Analytic Score API validates the data against the signature before executing it.

    Complex and large modules might take a long time to compile. The Micro Analytic Score API supports the ability to submit these modules asynchronously, so that the caller does not have to wait for the compilation to complete. Instead, the caller can check the compilation status after submission.

    The Micro Analytic Score API supports executing steps in three different ways:

    DS2 Source Code Format

    DS2 source, such as SAS Model Manager projects or SAS Enterprise Miner models, can be used by the Micro Analytic API.

    example code

    A complete code example is here.

    Module Life Cycle

    A compiled micro analytic module stays compiled during the lifetime of the server session in which it was compiled, even when dependent modules are later updated.

    The Micro Analytic Score API manages the persistence of the modules by keeping metadata about the modules. This ensures that when the service restarts, there is enough information to re-create the existing modules. However, when the modules are loaded into memory again, they might have different addresses than they previously did. Therefore, each reload of the modules requires that they be recompiled.

    Statelessness

    State is not maintained between executions of the same micro analytic module.

    Error Codes

    Operations

    Root

    Contains the operations for the Root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/microanalyticScore/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns a list of links to the top-level collections that are surfaced through the API. HEAD is also supported and returns status and headers only.

    Example responses

    List of top-level links

    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "modules",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "POST",
          "rel": "createModule",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "jobs",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "POST",
          "rel": "createJob",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.job"
        }
      ]
    }
    
    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "modules",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "POST",
          "rel": "createModule",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "jobs",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "POST",
          "rel": "createJob",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.job"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. A collection of link objects was returned. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is from a SAS service.

    Get headers for the service

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/microanalyticScore/
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/microanalyticScore/',
    {
      method: 'HEAD'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.head('https://example.com/microanalyticScore/')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/microanalyticScore/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /

    Retrieves headers for the service and checks whether the service is available.

    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The service is available. None
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is from a SAS service.

    Modules

    Contains the operations for module resources.

    Get loaded modules

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/modules \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/modules', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/modules", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /modules

    Retrieves the collection of modules that are loaded in memory by the service. Standard paging options are supported. The returned collection items are of type application/vnd.sas.microanalytic.module.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first module to return.
    limit query integer false The maximum number of modules to return.
    filter query string(filter-criteria) false The criteria for filtering the modules. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the modules. See Sorting in REST APIs.

    Example responses

    Get loaded modules response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules?start=0&limit=20",
          "uri": "/microanalyticScore/modules?start=0&limit=20",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "createModule",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/microanalyticScore/modules?start=20&limit=20",
          "uri": "/microanalyticScore/modules?start=20&limit=20",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "last",
          "href": "/microanalyticScore/modules?start=40&limit=20",
          "uri": "/microanalyticScore/modules?start=40&limit=20",
          "type": "application/vnd.sas.collection"
        }
      ],
      "name": "modules",
      "accept": "application/vnd.sas.microanalytic.module",
      "start": 0,
      "count": 45,
      "items": [
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm/source",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm/steps",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm/submodules",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.286Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:04.286Z",
          "id": "dcm_sortingalgorithm",
          "name": "DCM_SortingAlgorithm",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "quicksortstep",
            "sort"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage",
              "uri": "/microanalyticScore/modules/driverpackage",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/source",
              "uri": "/microanalyticScore/modules/driverpackage/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/driverpackage/steps",
              "uri": "/microanalyticScore/modules/driverpackage/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/driverpackage",
              "uri": "/microanalyticScore/modules/driverpackage",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/driverpackage",
              "uri": "/microanalyticScore/modules/driverpackage"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:02.903Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:02.903Z",
          "id": "driverpackage",
          "name": "driverPackage",
          "revision": 0,
          "description": "Simple driver package module",
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "test_driver"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/subpackage",
              "uri": "/microanalyticScore/modules/subpackage",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/subpackage/source",
              "uri": "/microanalyticScore/modules/subpackage/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/subpackage/submodules",
              "uri": "/microanalyticScore/modules/subpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/subpackage",
              "uri": "/microanalyticScore/modules/subpackage",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/subpackage",
              "uri": "/microanalyticScore/modules/subpackage"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:02.804Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:03.045Z",
          "id": "subpackage",
          "name": "SUBPACKAGE",
          "revision": 0,
          "description": "Simple subpackage module",
          "scope": "private",
          "language": "ds2",
          "stepIds": [
            "test_sub"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/vmastslvl",
              "uri": "/microanalyticScore/modules/vmastslvl",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/vmastslvl/source",
              "uri": "/microanalyticScore/modules/vmastslvl/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/vmastslvl/steps",
              "uri": "/microanalyticScore/modules/vmastslvl/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/vmastslvl/submodules",
              "uri": "/microanalyticScore/modules/vmastslvl/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/vmastslvl",
              "uri": "/microanalyticScore/modules/vmastslvl",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/vmastslvl",
              "uri": "/microanalyticScore/modules/vmastslvl"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:03.275Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:03.275Z",
          "id": "vmastslvl",
          "name": "vmastslvl",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "gettslvl"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule",
              "uri": "/microanalyticScore/modules/samplemodule",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/samplemodule/source",
              "uri": "/microanalyticScore/modules/samplemodule/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/samplemodule/submodules",
              "uri": "/microanalyticScore/modules/samplemodule/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/samplemodule",
              "uri": "/microanalyticScore/modules/samplemodule",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/samplemodule",
              "uri": "/microanalyticScore/modules/samplemodule"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:04.062Z",
          "id": "samplemodule",
          "name": "sampleModule",
          "revision": 0,
          "description": "Sample module",
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array",
            "copy_varchar_array",
            "copy_int_array",
            "copy_float_array",
            "copy_bigint_array",
            "copy_arrays"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/privatesamplemodule",
              "uri": "/microanalyticScore/modules/privatesamplemodule",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/privatesamplemodule/source",
              "uri": "/microanalyticScore/modules/privatesamplemodule/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/privatesamplemodule/submodules",
              "uri": "/microanalyticScore/modules/privatesamplemodule/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/privatesamplemodule",
              "uri": "/microanalyticScore/modules/privatesamplemodule",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/privatesamplemodule",
              "uri": "/microanalyticScore/modules/privatesamplemodule"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.177Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:04.177Z",
          "id": "privatesamplemodule",
          "name": "sampleModule",
          "revision": 0,
          "description": "A private version of sample module",
          "scope": "private",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array",
            "copy_varchar_array",
            "copy_int_array",
            "copy_float_array",
            "copy_bigint_array",
            "copy_arrays"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/astoretest",
              "uri": "/microanalyticScore/modules/astoretest",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/astoretest/source",
              "uri": "/microanalyticScore/modules/astoretest/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/astoretest/steps",
              "uri": "/microanalyticScore/modules/astoretest/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/astoretest/submodules",
              "uri": "/microanalyticScore/modules/astoretest/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/astoretest",
              "uri": "/microanalyticScore/modules/astoretest",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/astoretest",
              "uri": "/microanalyticScore/modules/astoretest"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:05.457Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:05.457Z",
          "id": "astoretest",
          "name": "astoretest",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "precode",
            "postcode",
            "astorescore"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test_conflict",
              "uri": "/microanalyticScore/modules/test_conflict",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test_conflict/source",
              "uri": "/microanalyticScore/modules/test_conflict/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test_conflict/steps",
              "uri": "/microanalyticScore/modules/test_conflict/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test_conflict/submodules",
              "uri": "/microanalyticScore/modules/test_conflict/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test_conflict",
              "uri": "/microanalyticScore/modules/test_conflict",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test_conflict",
              "uri": "/microanalyticScore/modules/test_conflict"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T20:49:11.323Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T20:49:11.323Z",
          "id": "test_conflict",
          "name": "test_conflict",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-1",
              "uri": "/microanalyticScore/modules/test-module-1",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-1/source",
              "uri": "/microanalyticScore/modules/test-module-1/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-1/steps",
              "uri": "/microanalyticScore/modules/test-module-1/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-1/submodules",
              "uri": "/microanalyticScore/modules/test-module-1/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-1",
              "uri": "/microanalyticScore/modules/test-module-1",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-1",
              "uri": "/microanalyticScore/modules/test-module-1"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:26.536Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:26.536Z",
          "id": "test-module-1",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-2",
              "uri": "/microanalyticScore/modules/test-module-2",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-2/source",
              "uri": "/microanalyticScore/modules/test-module-2/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-2/steps",
              "uri": "/microanalyticScore/modules/test-module-2/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-2/submodules",
              "uri": "/microanalyticScore/modules/test-module-2/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-2",
              "uri": "/microanalyticScore/modules/test-module-2",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-2",
              "uri": "/microanalyticScore/modules/test-module-2"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:26.688Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:26.688Z",
          "id": "test-module-2",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-3",
              "uri": "/microanalyticScore/modules/test-module-3",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-3/source",
              "uri": "/microanalyticScore/modules/test-module-3/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-3/steps",
              "uri": "/microanalyticScore/modules/test-module-3/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-3/submodules",
              "uri": "/microanalyticScore/modules/test-module-3/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-3",
              "uri": "/microanalyticScore/modules/test-module-3",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-3",
              "uri": "/microanalyticScore/modules/test-module-3"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:26.811Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:26.811Z",
          "id": "test-module-3",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-4",
              "uri": "/microanalyticScore/modules/test-module-4",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-4/source",
              "uri": "/microanalyticScore/modules/test-module-4/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-4/steps",
              "uri": "/microanalyticScore/modules/test-module-4/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-4/submodules",
              "uri": "/microanalyticScore/modules/test-module-4/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-4",
              "uri": "/microanalyticScore/modules/test-module-4",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-4",
              "uri": "/microanalyticScore/modules/test-module-4"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:26.931Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:26.931Z",
          "id": "test-module-4",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-5",
              "uri": "/microanalyticScore/modules/test-module-5",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-5/source",
              "uri": "/microanalyticScore/modules/test-module-5/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-5/steps",
              "uri": "/microanalyticScore/modules/test-module-5/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-5/submodules",
              "uri": "/microanalyticScore/modules/test-module-5/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-5",
              "uri": "/microanalyticScore/modules/test-module-5",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-5",
              "uri": "/microanalyticScore/modules/test-module-5"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.055Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.055Z",
          "id": "test-module-5",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-6",
              "uri": "/microanalyticScore/modules/test-module-6",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-6/source",
              "uri": "/microanalyticScore/modules/test-module-6/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-6/steps",
              "uri": "/microanalyticScore/modules/test-module-6/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-6/submodules",
              "uri": "/microanalyticScore/modules/test-module-6/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-6",
              "uri": "/microanalyticScore/modules/test-module-6",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-6",
              "uri": "/microanalyticScore/modules/test-module-6"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.194Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.194Z",
          "id": "test-module-6",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-7",
              "uri": "/microanalyticScore/modules/test-module-7",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-7/source",
              "uri": "/microanalyticScore/modules/test-module-7/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-7/steps",
              "uri": "/microanalyticScore/modules/test-module-7/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-7/submodules",
              "uri": "/microanalyticScore/modules/test-module-7/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-7",
              "uri": "/microanalyticScore/modules/test-module-7",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-7",
              "uri": "/microanalyticScore/modules/test-module-7"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.313Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.313Z",
          "id": "test-module-7",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-8",
              "uri": "/microanalyticScore/modules/test-module-8",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-8/source",
              "uri": "/microanalyticScore/modules/test-module-8/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-8/steps",
              "uri": "/microanalyticScore/modules/test-module-8/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-8/submodules",
              "uri": "/microanalyticScore/modules/test-module-8/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-8",
              "uri": "/microanalyticScore/modules/test-module-8",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-8",
              "uri": "/microanalyticScore/modules/test-module-8"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.431Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.431Z",
          "id": "test-module-8",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-9",
              "uri": "/microanalyticScore/modules/test-module-9",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-9/source",
              "uri": "/microanalyticScore/modules/test-module-9/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-9/steps",
              "uri": "/microanalyticScore/modules/test-module-9/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-9/submodules",
              "uri": "/microanalyticScore/modules/test-module-9/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-9",
              "uri": "/microanalyticScore/modules/test-module-9",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-9",
              "uri": "/microanalyticScore/modules/test-module-9"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.553Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.553Z",
          "id": "test-module-9",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-10",
              "uri": "/microanalyticScore/modules/test-module-10",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-10/source",
              "uri": "/microanalyticScore/modules/test-module-10/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-10/steps",
              "uri": "/microanalyticScore/modules/test-module-10/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-10/submodules",
              "uri": "/microanalyticScore/modules/test-module-10/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-10",
              "uri": "/microanalyticScore/modules/test-module-10",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-10",
              "uri": "/microanalyticScore/modules/test-module-10"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.662Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.662Z",
          "id": "test-module-10",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-11",
              "uri": "/microanalyticScore/modules/test-module-11",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-11/source",
              "uri": "/microanalyticScore/modules/test-module-11/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-11/steps",
              "uri": "/microanalyticScore/modules/test-module-11/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-11/submodules",
              "uri": "/microanalyticScore/modules/test-module-11/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-11",
              "uri": "/microanalyticScore/modules/test-module-11",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-11",
              "uri": "/microanalyticScore/modules/test-module-11"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.790Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.790Z",
          "id": "test-module-11",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-12",
              "uri": "/microanalyticScore/modules/test-module-12",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-12/source",
              "uri": "/microanalyticScore/modules/test-module-12/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-12/steps",
              "uri": "/microanalyticScore/modules/test-module-12/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-12/submodules",
              "uri": "/microanalyticScore/modules/test-module-12/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-12",
              "uri": "/microanalyticScore/modules/test-module-12",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-12",
              "uri": "/microanalyticScore/modules/test-module-12"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.918Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.918Z",
          "id": "test-module-12",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        }
      ],
      "limit": 20,
      "version": 2
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules?start=0&limit=20",
          "uri": "/microanalyticScore/modules?start=0&limit=20",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "createModule",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/microanalyticScore/modules?start=20&limit=20",
          "uri": "/microanalyticScore/modules?start=20&limit=20",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "last",
          "href": "/microanalyticScore/modules?start=40&limit=20",
          "uri": "/microanalyticScore/modules?start=40&limit=20",
          "type": "application/vnd.sas.collection"
        }
      ],
      "name": "modules",
      "accept": "application/vnd.sas.microanalytic.module",
      "start": 0,
      "count": 45,
      "items": [
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm/source",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm/steps",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm/submodules",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/dcm_sortingalgorithm",
              "uri": "/microanalyticScore/modules/dcm_sortingalgorithm"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.286Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:04.286Z",
          "id": "dcm_sortingalgorithm",
          "name": "DCM_SortingAlgorithm",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "quicksortstep",
            "sort"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage",
              "uri": "/microanalyticScore/modules/driverpackage",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/source",
              "uri": "/microanalyticScore/modules/driverpackage/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/driverpackage/steps",
              "uri": "/microanalyticScore/modules/driverpackage/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/driverpackage",
              "uri": "/microanalyticScore/modules/driverpackage",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/driverpackage",
              "uri": "/microanalyticScore/modules/driverpackage"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:02.903Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:02.903Z",
          "id": "driverpackage",
          "name": "driverPackage",
          "revision": 0,
          "description": "Simple driver package module",
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "test_driver"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/subpackage",
              "uri": "/microanalyticScore/modules/subpackage",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/subpackage/source",
              "uri": "/microanalyticScore/modules/subpackage/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/subpackage/submodules",
              "uri": "/microanalyticScore/modules/subpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/subpackage",
              "uri": "/microanalyticScore/modules/subpackage",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/subpackage",
              "uri": "/microanalyticScore/modules/subpackage"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:02.804Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:03.045Z",
          "id": "subpackage",
          "name": "SUBPACKAGE",
          "revision": 0,
          "description": "Simple subpackage module",
          "scope": "private",
          "language": "ds2",
          "stepIds": [
            "test_sub"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/vmastslvl",
              "uri": "/microanalyticScore/modules/vmastslvl",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/vmastslvl/source",
              "uri": "/microanalyticScore/modules/vmastslvl/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/vmastslvl/steps",
              "uri": "/microanalyticScore/modules/vmastslvl/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/vmastslvl/submodules",
              "uri": "/microanalyticScore/modules/vmastslvl/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/vmastslvl",
              "uri": "/microanalyticScore/modules/vmastslvl",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/vmastslvl",
              "uri": "/microanalyticScore/modules/vmastslvl"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:03.275Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:03.275Z",
          "id": "vmastslvl",
          "name": "vmastslvl",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "gettslvl"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule",
              "uri": "/microanalyticScore/modules/samplemodule",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/samplemodule/source",
              "uri": "/microanalyticScore/modules/samplemodule/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/samplemodule/submodules",
              "uri": "/microanalyticScore/modules/samplemodule/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/samplemodule",
              "uri": "/microanalyticScore/modules/samplemodule",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/samplemodule",
              "uri": "/microanalyticScore/modules/samplemodule"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:04.062Z",
          "id": "samplemodule",
          "name": "sampleModule",
          "revision": 0,
          "description": "Sample module",
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array",
            "copy_varchar_array",
            "copy_int_array",
            "copy_float_array",
            "copy_bigint_array",
            "copy_arrays"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/privatesamplemodule",
              "uri": "/microanalyticScore/modules/privatesamplemodule",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/privatesamplemodule/source",
              "uri": "/microanalyticScore/modules/privatesamplemodule/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/privatesamplemodule/submodules",
              "uri": "/microanalyticScore/modules/privatesamplemodule/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/privatesamplemodule",
              "uri": "/microanalyticScore/modules/privatesamplemodule",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/privatesamplemodule",
              "uri": "/microanalyticScore/modules/privatesamplemodule"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.177Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:04.177Z",
          "id": "privatesamplemodule",
          "name": "sampleModule",
          "revision": 0,
          "description": "A private version of sample module",
          "scope": "private",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array",
            "copy_varchar_array",
            "copy_int_array",
            "copy_float_array",
            "copy_bigint_array",
            "copy_arrays"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/astoretest",
              "uri": "/microanalyticScore/modules/astoretest",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/astoretest/source",
              "uri": "/microanalyticScore/modules/astoretest/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/astoretest/steps",
              "uri": "/microanalyticScore/modules/astoretest/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/astoretest/submodules",
              "uri": "/microanalyticScore/modules/astoretest/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/astoretest",
              "uri": "/microanalyticScore/modules/astoretest",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/astoretest",
              "uri": "/microanalyticScore/modules/astoretest"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:05.457Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:19:05.457Z",
          "id": "astoretest",
          "name": "astoretest",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "precode",
            "postcode",
            "astorescore"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test_conflict",
              "uri": "/microanalyticScore/modules/test_conflict",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test_conflict/source",
              "uri": "/microanalyticScore/modules/test_conflict/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test_conflict/steps",
              "uri": "/microanalyticScore/modules/test_conflict/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test_conflict/submodules",
              "uri": "/microanalyticScore/modules/test_conflict/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test_conflict",
              "uri": "/microanalyticScore/modules/test_conflict",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test_conflict",
              "uri": "/microanalyticScore/modules/test_conflict"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T20:49:11.323Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T20:49:11.323Z",
          "id": "test_conflict",
          "name": "test_conflict",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-1",
              "uri": "/microanalyticScore/modules/test-module-1",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-1/source",
              "uri": "/microanalyticScore/modules/test-module-1/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-1/steps",
              "uri": "/microanalyticScore/modules/test-module-1/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-1/submodules",
              "uri": "/microanalyticScore/modules/test-module-1/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-1",
              "uri": "/microanalyticScore/modules/test-module-1",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-1",
              "uri": "/microanalyticScore/modules/test-module-1"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:26.536Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:26.536Z",
          "id": "test-module-1",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-2",
              "uri": "/microanalyticScore/modules/test-module-2",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-2/source",
              "uri": "/microanalyticScore/modules/test-module-2/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-2/steps",
              "uri": "/microanalyticScore/modules/test-module-2/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-2/submodules",
              "uri": "/microanalyticScore/modules/test-module-2/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-2",
              "uri": "/microanalyticScore/modules/test-module-2",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-2",
              "uri": "/microanalyticScore/modules/test-module-2"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:26.688Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:26.688Z",
          "id": "test-module-2",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-3",
              "uri": "/microanalyticScore/modules/test-module-3",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-3/source",
              "uri": "/microanalyticScore/modules/test-module-3/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-3/steps",
              "uri": "/microanalyticScore/modules/test-module-3/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-3/submodules",
              "uri": "/microanalyticScore/modules/test-module-3/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-3",
              "uri": "/microanalyticScore/modules/test-module-3",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-3",
              "uri": "/microanalyticScore/modules/test-module-3"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:26.811Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:26.811Z",
          "id": "test-module-3",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-4",
              "uri": "/microanalyticScore/modules/test-module-4",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-4/source",
              "uri": "/microanalyticScore/modules/test-module-4/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-4/steps",
              "uri": "/microanalyticScore/modules/test-module-4/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-4/submodules",
              "uri": "/microanalyticScore/modules/test-module-4/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-4",
              "uri": "/microanalyticScore/modules/test-module-4",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-4",
              "uri": "/microanalyticScore/modules/test-module-4"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:26.931Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:26.931Z",
          "id": "test-module-4",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-5",
              "uri": "/microanalyticScore/modules/test-module-5",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-5/source",
              "uri": "/microanalyticScore/modules/test-module-5/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-5/steps",
              "uri": "/microanalyticScore/modules/test-module-5/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-5/submodules",
              "uri": "/microanalyticScore/modules/test-module-5/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-5",
              "uri": "/microanalyticScore/modules/test-module-5",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-5",
              "uri": "/microanalyticScore/modules/test-module-5"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.055Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.055Z",
          "id": "test-module-5",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-6",
              "uri": "/microanalyticScore/modules/test-module-6",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-6/source",
              "uri": "/microanalyticScore/modules/test-module-6/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-6/steps",
              "uri": "/microanalyticScore/modules/test-module-6/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-6/submodules",
              "uri": "/microanalyticScore/modules/test-module-6/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-6",
              "uri": "/microanalyticScore/modules/test-module-6",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-6",
              "uri": "/microanalyticScore/modules/test-module-6"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.194Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.194Z",
          "id": "test-module-6",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-7",
              "uri": "/microanalyticScore/modules/test-module-7",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-7/source",
              "uri": "/microanalyticScore/modules/test-module-7/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-7/steps",
              "uri": "/microanalyticScore/modules/test-module-7/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-7/submodules",
              "uri": "/microanalyticScore/modules/test-module-7/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-7",
              "uri": "/microanalyticScore/modules/test-module-7",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-7",
              "uri": "/microanalyticScore/modules/test-module-7"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.313Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.313Z",
          "id": "test-module-7",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-8",
              "uri": "/microanalyticScore/modules/test-module-8",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-8/source",
              "uri": "/microanalyticScore/modules/test-module-8/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-8/steps",
              "uri": "/microanalyticScore/modules/test-module-8/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-8/submodules",
              "uri": "/microanalyticScore/modules/test-module-8/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-8",
              "uri": "/microanalyticScore/modules/test-module-8",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-8",
              "uri": "/microanalyticScore/modules/test-module-8"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.431Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.431Z",
          "id": "test-module-8",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-9",
              "uri": "/microanalyticScore/modules/test-module-9",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-9/source",
              "uri": "/microanalyticScore/modules/test-module-9/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-9/steps",
              "uri": "/microanalyticScore/modules/test-module-9/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-9/submodules",
              "uri": "/microanalyticScore/modules/test-module-9/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-9",
              "uri": "/microanalyticScore/modules/test-module-9",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-9",
              "uri": "/microanalyticScore/modules/test-module-9"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.553Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.553Z",
          "id": "test-module-9",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-10",
              "uri": "/microanalyticScore/modules/test-module-10",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-10/source",
              "uri": "/microanalyticScore/modules/test-module-10/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-10/steps",
              "uri": "/microanalyticScore/modules/test-module-10/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-10/submodules",
              "uri": "/microanalyticScore/modules/test-module-10/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-10",
              "uri": "/microanalyticScore/modules/test-module-10",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-10",
              "uri": "/microanalyticScore/modules/test-module-10"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.662Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.662Z",
          "id": "test-module-10",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-11",
              "uri": "/microanalyticScore/modules/test-module-11",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-11/source",
              "uri": "/microanalyticScore/modules/test-module-11/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-11/steps",
              "uri": "/microanalyticScore/modules/test-module-11/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-11/submodules",
              "uri": "/microanalyticScore/modules/test-module-11/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-11",
              "uri": "/microanalyticScore/modules/test-module-11",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-11",
              "uri": "/microanalyticScore/modules/test-module-11"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.790Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.790Z",
          "id": "test-module-11",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules",
              "uri": "/microanalyticScore/modules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/test-module-12",
              "uri": "/microanalyticScore/modules/test-module-12",
              "type": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/test-module-12/source",
              "uri": "/microanalyticScore/modules/test-module-12/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "steps",
              "href": "/microanalyticScore/modules/test-module-12/steps",
              "uri": "/microanalyticScore/modules/test-module-12/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/modules/test-module-12/submodules",
              "uri": "/microanalyticScore/modules/test-module-12/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/microanalyticScore/modules/test-module-12",
              "uri": "/microanalyticScore/modules/test-module-12",
              "type": "application/vnd.sas.microanalytic.module",
              "responseType": "application/vnd.sas.microanalytic.module"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/modules/test-module-12",
              "uri": "/microanalyticScore/modules/test-module-12"
            }
          ],
          "version": 2,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:18:27.918Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-03-15T21:18:27.918Z",
          "id": "test-module-12",
          "name": "module",
          "revision": 0,
          "scope": "public",
          "language": "ds2",
          "stepIds": [
            "copy_charn_array"
          ],
          "warnings": []
        }
      ],
      "limit": 20,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. moduleCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is from a SAS service.

    Create a module

    Code samples

    # You can also use wget
    curl -X POST https://example.com/microanalyticScore/modules \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.microanalytic.module.definition+json' \
      -H 'Accept: application/vnd.sas.microanalytic.module+json'
    
    
    const inputBody = '{
      "id": "NewModule",
      "scope": "public",
      "version": 1,
      "description": "Create the NewModule module.",
      "source": "package variabletest /overwrite=yes;\nmethod variable_test_update(varchar(32767) in_string, bigint in_int, double in_float, bigint in_boolean, in_out varchar out_string, in_out bigint out_int, in_out double out_float, in_out bigint out_boolean);\nout_int=in_int + 2;\nout_float=in_float + 1.11;\nif (in_boolean = 0) then out_boolean=1;\nelse out_boolean=0;\nout_string=reverse(in_string);\nend;\nendpackage;\n",
      "type": "text/vnd.sas.source.ds2",
      "properties": [
        {
          "name": "NewModule property name",
          "value": "NewModule property value"
        },
        {
          "name": "NewModule property name 2",
          "value": ""
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.microanalytic.module.definition+json',
      'Accept':'application/vnd.sas.microanalytic.module+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.microanalytic.module.definition+json',
      'Accept': 'application/vnd.sas.microanalytic.module+json'
    }
    
    r = requests.post('https://example.com/microanalyticScore/modules', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.microanalytic.module.definition+json"},
            "Accept": []string{"application/vnd.sas.microanalytic.module+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/microanalyticScore/modules", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /modules

    Creates and loads a module from the provided module definition and returns a representation of the loaded module. Note that the name assigned to a module ID, package, public method, or submodule must not include any of the following characters: forward slash, backslash, period, and semicolon.

    Body parameter

    Create module job request.

    {
      "id": "NewModule",
      "scope": "public",
      "version": 1,
      "description": "Create the NewModule module.",
      "source": "package variabletest /overwrite=yes;\nmethod variable_test_update(varchar(32767) in_string, bigint in_int, double in_float, bigint in_boolean, in_out varchar out_string, in_out bigint out_int, in_out double out_float, in_out bigint out_boolean);\nout_int=in_int + 2;\nout_float=in_float + 1.11;\nif (in_boolean = 0) then out_boolean=1;\nelse out_boolean=0;\nout_string=reverse(in_string);\nend;\nendpackage;\n",
      "type": "text/vnd.sas.source.ds2",
      "properties": [
        {
          "name": "NewModule property name",
          "value": "NewModule property value"
        },
        {
          "name": "NewModule property name 2",
          "value": ""
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    body body moduleDefinition true A definition of the module to be created.

    Example responses

    Create new module response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/newmodule",
          "uri": "/microanalyticScore/modules/newmoudue",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/modules/newmodule/source",
          "uri": "/microanalyticScore/modules/newmodule/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "steps",
          "href": "/microanalyticScore/modules/newmoudue/steps",
          "uri": "/microanalyticScore/modules/newmodule/steps",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/modules/newmodule/submodules",
          "uri": "/microanalyticScore/modules/newmodule/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/newmodule",
          "uri": "/microanalyticScore/modules/newmodule",
          "type": "application/vnd.sas.microanalytic.module",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/modules/newmodule",
          "uri": "/microanalyticScore/modules/newmoudule"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-03T14:31:26.796Z",
      "modifiedBy": "sasboot",
      "modifiedTimeStamp": "2022-05-03T14:31:26.796Z",
      "id": "newmodule",
      "name": "variabletest",
      "revision": 0,
      "description": "New Module",
      "scope": "public",
      "language": "ds2",
      "stepIds": [
        "variable_test"
      ],
      "properties": [
        {
          "name": "NewModule property 1",
          "value": "NewModule property value"
        },
        {
          "name": "NewModule property 2",
          "value": ""
        }
      ],
      "warnings": []
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/newmodule",
          "uri": "/microanalyticScore/modules/newmoudue",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/modules/newmodule/source",
          "uri": "/microanalyticScore/modules/newmodule/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "steps",
          "href": "/microanalyticScore/modules/newmoudue/steps",
          "uri": "/microanalyticScore/modules/newmodule/steps",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/modules/newmodule/submodules",
          "uri": "/microanalyticScore/modules/newmodule/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/newmodule",
          "uri": "/microanalyticScore/modules/newmodule",
          "type": "application/vnd.sas.microanalytic.module",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/modules/newmodule",
          "uri": "/microanalyticScore/modules/newmoudule"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-03T14:31:26.796Z",
      "modifiedBy": "sasboot",
      "modifiedTimeStamp": "2022-05-03T14:31:26.796Z",
      "id": "newmodule",
      "name": "variabletest",
      "revision": 0,
      "description": "New Module",
      "scope": "public",
      "language": "ds2",
      "stepIds": [
        "variable_test"
      ],
      "properties": [
        {
          "name": "NewModule property 1",
          "value": "NewModule property value"
        },
        {
          "name": "NewModule property 2",
          "value": ""
        }
      ],
      "warnings": []
    }
    

    Bad request.

    {
      "errorCode": 0,
      "message": "The request body was missing or invalid.",
      "details": [
        "traceId: acb6c926539b5946",
        "path: /microanalyticScore/modules"
      ],
      "links": [],
      "version": 2,
      "httpStatusCode": 400
    }
    
    {
      "errorCode": 0,
      "message": "The request body was missing or invalid.",
      "details": [
        "traceId: acb6c926539b5946",
        "path: /microanalyticScore/modules"
      ],
      "links": [],
      "version": 2,
      "httpStatusCode": 400
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The module was created. module
    400 Bad Request The request was invalid. The module was not created. error2
    Response Headers
    Status Header Type Format Description
    201 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module was last modified.
    201 Etag string The entity tag that identifies this revision of the module.
    201 Location string uri The URL of the module.

    Get module

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/modules/{moduleId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.microanalytic.module+json' \
      -H 'If-Match: string' \
      -H 'If-Unmodified-Since: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.microanalytic.module+json',
      'If-Match':'string',
      'If-Unmodified-Since':'string'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.microanalytic.module+json',
      'If-Match': 'string',
      'If-Unmodified-Since': 'string'
    }
    
    r = requests.get('https://example.com/microanalyticScore/modules/{moduleId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.microanalytic.module+json"},
            "If-Match": []string{"string"},
            "If-Unmodified-Since": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/modules/{moduleId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /modules/{moduleId}

    For the specified module, returns detailed information including the steps that are contained in the module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module to retrieve.
    If-Match header string false The Etag that is returned from a GET, POST, or PUT of this module.
    If-Unmodified-Since header string false The value of the 'lastModified' date of the module. If the module has been updated since this time, the update will fail.

    Example responses

    Get loaded module reponse.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/modules/samplemodule/source",
          "uri": "/microanalyticScore/modules/samplemodule/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "steps",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/modules/samplemodule/submodules",
          "uri": "/microanalyticScore/modules/samplemodule/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-03-15T21:19:04.062Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-03-15T21:19:04.062Z",
      "id": "samplemodule",
      "name": "sampleModule",
      "revision": 0,
      "description": "Sample module",
      "scope": "public",
      "language": "ds2",
      "stepIds": [
        "copy_charn_array",
        "copy_varchar_array",
        "copy_int_array",
        "copy_float_array",
        "copy_bigint_array",
        "copy_arrays"
      ],
      "warnings": []
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/modules/samplemodule/source",
          "uri": "/microanalyticScore/modules/samplemodule/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "steps",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/modules/samplemodule/submodules",
          "uri": "/microanalyticScore/modules/samplemodule/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-03-15T21:19:04.062Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-03-15T21:19:04.062Z",
      "id": "samplemodule",
      "name": "sampleModule",
      "revision": 0,
      "description": "Sample module",
      "scope": "public",
      "language": "ds2",
      "stepIds": [
        "copy_charn_array",
        "copy_varchar_array",
        "copy_int_array",
        "copy_float_array",
        "copy_bigint_array",
        "copy_arrays"
      ],
      "warnings": []
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. module
    404 Not Found The requested module could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module was last modified.
    200 Etag string The entity tag that identifies this revision of the module.

    Get headers for module

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/microanalyticScore/modules/{moduleId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json' \
      -H 'If-Match: string' \
      -H 'If-Unmodified-Since: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json',
      'If-Match':'string',
      'If-Unmodified-Since':'string'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json',
      'If-Match': 'string',
      'If-Unmodified-Since': 'string'
    }
    
    r = requests.head('https://example.com/microanalyticScore/modules/{moduleId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
            "If-Match": []string{"string"},
            "If-Unmodified-Since": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/microanalyticScore/modules/{moduleId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /modules/{moduleId}

    For the specified module, returns header information for subsequent PUT or check for existence.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module to retrieve.
    If-Match header string false The Etag that is returned from a GET, POST, or PUT of this module.
    If-Unmodified-Since header string false The value of the 'lastModified' date of the module. If the module has been updated since this time, the update will fail.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found The requested module could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module was last modified.
    200 Etag string The entity tag that identifies this revision of the module.

    Update a module

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/microanalyticScore/modules/{moduleId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.microanalytic.module+json' \
      -H 'Accept: application/vnd.sas.microanalytic.module+json' \
      -H 'If-Match: string' \
      -H 'If-Unmodified-Since: string'
    
    
    const inputBody = '{
      "id": "SampleModule",
      "version": 1,
      "description": "Update the SampleModule module.",
      "source": "package variabletest /overwrite=yes;\n method variable_test_update(varchar(32767) in_string, bigint in_int, double in_float, bigint in_boolean, in_out varchar out_string, in_out bigint out_int, in_out double out_float, in_out bigint out_boolean);\n out_int=in_int + 2;\n out_float=in_float + 1.11;\n if (in_boolean = 0) then out_boolean=1;\n else out_boolean=0;\n out_string=reverse(in_string);\n end;\n endpackage;\n",
      "type": "text/vnd.sas.source.ds2",
      "properties": [
        {
          "name": "test property name",
          "value": "test property value"
        },
        {
          "name": "test property name 2",
          "value": ""
        }
      ],
      "scope": "public"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.microanalytic.module+json',
      'Accept':'application/vnd.sas.microanalytic.module+json',
      'If-Match':'string',
      'If-Unmodified-Since':'string'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.microanalytic.module+json',
      'Accept': 'application/vnd.sas.microanalytic.module+json',
      'If-Match': 'string',
      'If-Unmodified-Since': 'string'
    }
    
    r = requests.put('https://example.com/microanalyticScore/modules/{moduleId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.microanalytic.module+json"},
            "Accept": []string{"application/vnd.sas.microanalytic.module+json"},
            "If-Match": []string{"string"},
            "If-Unmodified-Since": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/microanalyticScore/modules/{moduleId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /modules/{moduleId}

    For the specified module, replaces the existing module with values from the request body. Please note, the source of the module is not replaced.

    Body parameter

    Update module request.

    {
      "id": "SampleModule",
      "version": 1,
      "description": "Update the SampleModule module.",
      "source": "package variabletest /overwrite=yes;\n method variable_test_update(varchar(32767) in_string, bigint in_int, double in_float, bigint in_boolean, in_out varchar out_string, in_out bigint out_int, in_out double out_float, in_out bigint out_boolean);\n out_int=in_int + 2;\n out_float=in_float + 1.11;\n if (in_boolean = 0) then out_boolean=1;\n else out_boolean=0;\n out_string=reverse(in_string);\n end;\n endpackage;\n",
      "type": "text/vnd.sas.source.ds2",
      "properties": [
        {
          "name": "test property name",
          "value": "test property value"
        },
        {
          "name": "test property name 2",
          "value": ""
        }
      ],
      "scope": "public"
    }
    
    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module to update.
    If-Match header string false The Etag that is returned from a GET, POST, or PUT of this module.
    If-Unmodified-Since header string false The value of the 'lastModified' date of the module. If the module has been updated since this time, the update will fail.
    body body module true The new definition of the module to load. The name of the module in the new definition must match the previously loaded name.

    Example responses

    Update module response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/modules/samplemodule/source",
          "uri": "/microanalyticScore/modules/samplemodule/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "steps",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/modules/samplemodule/submodules",
          "uri": "/microanalyticScore/modules/samplemodule/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-03-15T21:19:04.062Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
      "id": "samplemodule",
      "name": "sampleModule",
      "revision": 0,
      "description": "Updated sample module.",
      "scope": "public",
      "language": "ds2",
      "stepIds": [
        "copy_charn_array",
        "copy_varchar_array",
        "copy_int_array",
        "copy_float_array",
        "copy_bigint_array",
        "copy_arrays"
      ],
      "properties": [
        {
          "name": "test property name 2",
          "value": ""
        },
        {
          "name": "test property name",
          "value": "test property value"
        }
      ],
      "warnings": []
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules",
          "uri": "/microanalyticScore/modules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/modules/samplemodule/source",
          "uri": "/microanalyticScore/modules/samplemodule/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "steps",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/modules/samplemodule/submodules",
          "uri": "/microanalyticScore/modules/samplemodule/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module",
          "responseType": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-03-15T21:19:04.062Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
      "id": "samplemodule",
      "name": "sampleModule",
      "revision": 0,
      "description": "Updated sample module.",
      "scope": "public",
      "language": "ds2",
      "stepIds": [
        "copy_charn_array",
        "copy_varchar_array",
        "copy_int_array",
        "copy_float_array",
        "copy_bigint_array",
        "copy_arrays"
      ],
      "properties": [
        {
          "name": "test property name 2",
          "value": ""
        },
        {
          "name": "test property name",
          "value": "test property value"
        }
      ],
      "warnings": []
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "errorCode": 1010,
      "message": "One of the following request header fields is required: \"If-Match\" or \"If-Unmodified-Since\".",
      "details": [
        "traceId: 3053787a073a346c",
        "path: /microanalyticScore/modules/samplemodule/"
      ],
      "remediation": "In the request header, include one of the following: the resource's entity tag for the field \"If-Match\", or the resource's last-modified timestamp for the field \"If-Unmodified-Since\".",
      "links": [],
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. module
    400 Bad Request The request was invalid. The module could not be updated. error2
    404 Not Found The requested module could not be found. error2
    412 Precondition Failed The If-Match request header did not match the module's Etag or the If-Unmodified-Since request header did not match the module's last modified timestamp. error2
    428 Precondition Required The request headers did not include an If-Match or If-Unmodified-Since precondition. Set appropriate values for the If-Unmodified-Since and If-Match request headers before reattempting the request. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module was last modified.
    200 Etag string The entity tag that identifies this revision of the module.

    Delete a module

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/microanalyticScore/modules/{moduleId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/microanalyticScore/modules/{moduleId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/microanalyticScore/modules/{moduleId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /modules/{moduleId}

    Deletes the specified module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module to delete.
    Responses
    Status Meaning Description Schema
    204 No Content The module was deleted. None

    Get module source

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/modules/{moduleId}/source \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.microanalytic.module.source+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.microanalytic.module.source+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/source',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.microanalytic.module.source+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/modules/{moduleId}/source', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.microanalytic.module.source+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/modules/{moduleId}/source", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /modules/{moduleId}/source

    Returns the source code of the specified module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the source code.

    Example responses

    Get module source response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule/source",
          "uri": "/microanalyticScore/modules/samplemodule/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/samplemodule/source",
          "uri": "/microanalyticScore/modules/samplemodule/source",
          "type": "application/vnd.sas.microanalytic.module.source",
          "responseType": "application/vnd.sas.microanalytic.module.source"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-03-15T21:19:04.286Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-03-15T21:19:04.286Z",
      "moduleId": "samplemodule",
      "source": "ds2_options sas; package sampleModule / overwrite=yes;   method copy_charN_array(char(12) in_array[4], in_out char(12)  out_array[4]); out_array := in_array; end;  method copy_varchar_array(varchar(512) in_array[3], in_out varchar out_array[3]); out_array := in_array; end;  method copy_int_array(int in_array[5], in_out int out_array[5]); out_array := in_array; end;  method copy_float_array(double in_array[2], in_out double out_array[2]); out_array := in_array; end;  method copy_bigint_array(bigint in_array[1], in_out bigint out_array[1]); out_array := in_array; end;  method copy_arrays(char(12) in_charN_array[4], varchar(512) in_varchar_array[1], int in_int_array[5], double in_double_array[2],  bigint in_bigint_array[1],  in_out char(12)  out_charN_array[4], in_out varchar(512) out_varchar_array[1], in_out int out_int_array[5], in_out double out_double_array[2], in_out bigint out_bigint_array[1]);  copy_charN_array(in_charN_array, out_charN_array); copy_int_array(in_int_array, out_int_array); copy_float_array(in_double_array,  out_double_array); copy_bigint_array(in_bigint_array, out_bigint_array);  end;  endpackage;"
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/samplemodule",
          "uri": "/microanalyticScore/modules/samplemodule",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule/source",
          "uri": "/microanalyticScore/modules/samplemodule/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/samplemodule/source",
          "uri": "/microanalyticScore/modules/samplemodule/source",
          "type": "application/vnd.sas.microanalytic.module.source",
          "responseType": "application/vnd.sas.microanalytic.module.source"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-03-15T21:19:04.286Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-03-15T21:19:04.286Z",
      "moduleId": "samplemodule",
      "source": "ds2_options sas; package sampleModule / overwrite=yes;   method copy_charN_array(char(12) in_array[4], in_out char(12)  out_array[4]); out_array := in_array; end;  method copy_varchar_array(varchar(512) in_array[3], in_out varchar out_array[3]); out_array := in_array; end;  method copy_int_array(int in_array[5], in_out int out_array[5]); out_array := in_array; end;  method copy_float_array(double in_array[2], in_out double out_array[2]); out_array := in_array; end;  method copy_bigint_array(bigint in_array[1], in_out bigint out_array[1]); out_array := in_array; end;  method copy_arrays(char(12) in_charN_array[4], varchar(512) in_varchar_array[1], int in_int_array[5], double in_double_array[2],  bigint in_bigint_array[1],  in_out char(12)  out_charN_array[4], in_out varchar(512) out_varchar_array[1], in_out int out_int_array[5], in_out double out_double_array[2], in_out bigint out_bigint_array[1]);  copy_charN_array(in_charN_array, out_charN_array); copy_int_array(in_int_array, out_int_array); copy_float_array(in_double_array,  out_double_array); copy_bigint_array(in_bigint_array, out_bigint_array);  end;  endpackage;"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. moduleSource
    404 Not Found The requested module could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module was last modified.
    200 Etag string The entity tag that identifies this revision of the module.

    Get headers for module source

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/microanalyticScore/modules/{moduleId}/source \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json' \
      -H 'If-Match: string' \
      -H 'If-Unmodified-Since: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json',
      'If-Match':'string',
      'If-Unmodified-Since':'string'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/source',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json',
      'If-Match': 'string',
      'If-Unmodified-Since': 'string'
    }
    
    r = requests.head('https://example.com/microanalyticScore/modules/{moduleId}/source', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
            "If-Match": []string{"string"},
            "If-Unmodified-Since": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/microanalyticScore/modules/{moduleId}/source", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /modules/{moduleId}/source

    For the specified module, returns header information for subsequent PUT or check for existence. Since the module source is persisted as part of the module, the ETag and Last Modified Date as the same as that of the module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module of the source to retrieve.
    If-Match header string false The Etag that is returned from a GET, POST, or PUT of this module.
    If-Unmodified-Since header string false The value of the 'lastModified' date of the module. If the module has been updated since this time, the update will fail.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found The requested module could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module was last modified.
    200 Etag string The entity tag that identifies this revision of the module.

    Update module source

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/microanalyticScore/modules/{moduleId}/source \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.microanalytic.module.source+json' \
      -H 'Accept: application/vnd.sas.microanalytic.module.source+json' \
      -H 'If-Match: string' \
      -H 'If-Unmodified-Since: string'
    
    
    const inputBody = '{
      "id": "endToEnd",
      "version": 1,
      "description": "Updated source for the endToEnd module.",
      "source": "package endtoend /overwrite=yes;\nmethod variable_test(varchar(32767) in_string, bigint in_int, double in_float, bigint in_boolean, in_out varchar out_string, in_out bigint out_int, in_out double out_float, in_out bigint out_boolean);\nout_int=in_int - 2;\nout_float=in_float + 1.11;\nif (in_boolean = 0) then out_boolean=1;\nelse out_boolean=0;\nout_string=reverse(in_string);\nend;\nendpackage;\n",
      "type": "text/vnd.sas.source.ds2",
      "properties": [
        {
          "name": "prop1",
          "value": "value1"
        },
        {
          "name": "prop3",
          "value": 3
        }
      ],
      "scope": "public"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.microanalytic.module.source+json',
      'Accept':'application/vnd.sas.microanalytic.module.source+json',
      'If-Match':'string',
      'If-Unmodified-Since':'string'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/source',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.microanalytic.module.source+json',
      'Accept': 'application/vnd.sas.microanalytic.module.source+json',
      'If-Match': 'string',
      'If-Unmodified-Since': 'string'
    }
    
    r = requests.put('https://example.com/microanalyticScore/modules/{moduleId}/source', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.microanalytic.module.source+json"},
            "Accept": []string{"application/vnd.sas.microanalytic.module.source+json"},
            "If-Match": []string{"string"},
            "If-Unmodified-Since": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/microanalyticScore/modules/{moduleId}/source", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /modules/{moduleId}/source

    Replaces the module source of the specified module with values in the request body.

    Body parameter

    Update module source request.

    {
      "id": "endToEnd",
      "version": 1,
      "description": "Updated source for the endToEnd module.",
      "source": "package endtoend /overwrite=yes;\nmethod variable_test(varchar(32767) in_string, bigint in_int, double in_float, bigint in_boolean, in_out varchar out_string, in_out bigint out_int, in_out double out_float, in_out bigint out_boolean);\nout_int=in_int - 2;\nout_float=in_float + 1.11;\nif (in_boolean = 0) then out_boolean=1;\nelse out_boolean=0;\nout_string=reverse(in_string);\nend;\nendpackage;\n",
      "type": "text/vnd.sas.source.ds2",
      "properties": [
        {
          "name": "prop1",
          "value": "value1"
        },
        {
          "name": "prop3",
          "value": 3
        }
      ],
      "scope": "public"
    }
    
    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module to update.
    If-Match header string false The Etag returned from a GET, POST, or PUT of this module source.
    If-Unmodified-Since header string false The value of the lastModified date of the module source. If the module source has been updated since this time, the update will fail.
    body body moduleSource true The new module source to load.

    Example responses

    Update module source response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/endtoend",
          "uri": "/microanalyticScore/modules/endtoend",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/endtoend/source",
          "uri": "/microanalyticScore/modules/endtoend/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/endtoend/source",
          "uri": "/microanalyticScore/modules/endtoend/source",
          "type": "application/vnd.sas.microanalytic.module.source",
          "responseType": "application/vnd.sas.microanalytic.module.source"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-04T13:11:25.715Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-05T15:04:22.520Z",
      "moduleId": "endtoend",
      "source": "package endtoend /overwrite=yes;\nmethod variable_test(varchar(32767) in_string, bigint in_int, double in_float, bigint in_boolean, in_out varchar out_string, in_out bigint out_int, in_out double out_float, in_out bigint out_boolean);\nout_int=in_int - 2;\nout_float=in_float + 1.11;\nif (in_boolean = 0) then out_boolean=1;\nelse out_boolean=0;\nout_string=reverse(in_string);\nend;\nendpackage;\n"
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/endtoend",
          "uri": "/microanalyticScore/modules/endtoend",
          "type": "application/vnd.sas.microanalytic.module"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/endtoend/source",
          "uri": "/microanalyticScore/modules/endtoend/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/microanalyticScore/modules/endtoend/source",
          "uri": "/microanalyticScore/modules/endtoend/source",
          "type": "application/vnd.sas.microanalytic.module.source",
          "responseType": "application/vnd.sas.microanalytic.module.source"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-04T13:11:25.715Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-05T15:04:22.520Z",
      "moduleId": "endtoend",
      "source": "package endtoend /overwrite=yes;\nmethod variable_test(varchar(32767) in_string, bigint in_int, double in_float, bigint in_boolean, in_out varchar out_string, in_out bigint out_int, in_out double out_float, in_out bigint out_boolean);\nout_int=in_int - 2;\nout_float=in_float + 1.11;\nif (in_boolean = 0) then out_boolean=1;\nelse out_boolean=0;\nout_string=reverse(in_string);\nend;\nendpackage;\n"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "errorCode": 1010,
      "message": "The request header field \"If-Unmodified-Since\" has an earlier value (Fri, 17 Apr 2015 19:31:56 GMT) than the resource's last-modified timestamp (Thu, 05 May 2022 15:16:34 GMT).",
      "details": [
        "traceId: 84454323c93eca3d",
        "path: /microanalyticScore/modules/endtoend/source"
      ],
      "remediation": "Get the latest representation of the resource, and apply the desired changes. Retry the operation with the modified representation and the entity tag from the response header field \"ETag\".",
      "links": [],
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "errorCode": 1010,
      "message": "One of the following request header fields is required: \"If-Match\" or \"If-Unmodified-Since\".",
      "details": [
        "traceId: 0aa49767237e6936",
        "path: /microanalyticScore/modules/endtoend/source"
      ],
      "remediation": "In the request header, include one of the following: the resource's entity tag for the field \"If-Match\", or the resource's last-modified timestamp for the field \"If-Unmodified-Since\".",
      "links": [],
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. moduleSource
    400 Bad Request The request was invalid. The module could not be updated. error2
    404 Not Found The requested module could not be found. error2
    412 Precondition Failed The If-Match request header did not match the module's Etag or the If-Unmodified-Since request header did not match the module's last modified timestamp. error2
    428 Precondition Required The request header did not include an If-Match or If-Unmodified-Since precondition. Set the appropriate values for the If-Unmodified-Since and If-Match request headers before reattempting the request. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module was last modified.
    200 Etag string The entity tag that identifies this revision of the module.

    Submodules

    Contains the operations for submodule resources.

    Get submodules for this module

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/modules/{moduleId}/submodules \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/submodules',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/modules/{moduleId}/submodules', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/modules/{moduleId}/submodules", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /modules/{moduleId}/submodules

    Retrieves the collection of submodules contained by the specified module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the submodule collection.
    start query integer(int64) false The index of the first submodule to return.
    limit query integer false The maximum number of submodules to return.

    Example responses

    Get submodules response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/microanalyticScore/modules/driverpackage/submodules",
          "uri": "/microanalyticScore/modules/driverpackage/submodules",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/driverpackage/submodules?start=0&limit=20",
          "uri": "/microanalyticScore/modules/driverpackage/submodules?start=0&limit=20",
          "type": "application/vnd.sas.collection"
        }
      ],
      "name": "submodules",
      "accept": "application/vnd.sas.microanalytic.submodule",
      "count": 10,
      "items": [
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage6",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage6",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage6/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage6/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage6",
          "name": "subpackage6",
          "language": "ds2",
          "description": "sub package 6"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage7",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage7",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage7/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage7/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage7",
          "name": "subpackage7",
          "language": "ds2",
          "description": "sub package 7"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage8",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage8",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage8/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage8/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage8",
          "name": "subpackage8",
          "language": "ds2",
          "description": "sub package 8"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage9",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage9",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage9/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage9/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage9",
          "name": "subpackage9",
          "language": "ds2",
          "description": "sub package 9"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage0",
          "name": "subpackage0",
          "language": "ds2",
          "description": "sub package 0"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage1",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage1",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage1/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage1/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage1",
          "name": "subpackage1",
          "language": "ds2",
          "description": "sub package 1"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage2",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage2",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage2/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage2/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage2",
          "name": "subpackage2",
          "language": "ds2",
          "description": "sub package 2"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage3",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage3",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage3/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage3/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage3",
          "name": "subpackage3",
          "language": "ds2",
          "description": "sub package 3"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage4",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage4",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage4/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage4/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage4",
          "name": "subpackage4",
          "language": "ds2",
          "description": "sub package 4"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage5",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage5",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage5/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage5/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage5",
          "name": "subpackage5",
          "language": "ds2",
          "description": "sub package 5"
        }
      ],
      "version": 2
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/microanalyticScore/modules/driverpackage/submodules",
          "uri": "/microanalyticScore/modules/driverpackage/submodules",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/driverpackage/submodules?start=0&limit=20",
          "uri": "/microanalyticScore/modules/driverpackage/submodules?start=0&limit=20",
          "type": "application/vnd.sas.collection"
        }
      ],
      "name": "submodules",
      "accept": "application/vnd.sas.microanalytic.submodule",
      "count": 10,
      "items": [
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage6",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage6",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage6/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage6/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage6",
          "name": "subpackage6",
          "language": "ds2",
          "description": "sub package 6"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage7",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage7",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage7/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage7/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage7",
          "name": "subpackage7",
          "language": "ds2",
          "description": "sub package 7"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage8",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage8",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage8/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage8/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage8",
          "name": "subpackage8",
          "language": "ds2",
          "description": "sub package 8"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage9",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage9",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage9/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage9/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage9",
          "name": "subpackage9",
          "language": "ds2",
          "description": "sub package 9"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage0",
          "name": "subpackage0",
          "language": "ds2",
          "description": "sub package 0"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage1",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage1",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage1/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage1/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage1",
          "name": "subpackage1",
          "language": "ds2",
          "description": "sub package 1"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage2",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage2",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage2/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage2/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage2",
          "name": "subpackage2",
          "language": "ds2",
          "description": "sub package 2"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage3",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage3",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage3/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage3/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage3",
          "name": "subpackage3",
          "language": "ds2",
          "description": "sub package 3"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage4",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage4",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage4/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage4/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage4",
          "name": "subpackage4",
          "language": "ds2",
          "description": "sub package 4"
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/driverpackage/submodules",
              "uri": "/microanalyticScore/modules/driverpackage/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage5",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage5",
              "type": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage5/source",
              "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage5/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-05T20:03:46.066Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
          "moduleId": "driverPackage",
          "id": "subpackage5",
          "name": "subpackage5",
          "language": "ds2",
          "description": "sub package 5"
        }
      ],
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. submoduleCollection
    404 Not Found The module that contains the submodules collection could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module was last modified.
    200 Etag string The entity tag that identifies this revision of the module.

    Get headers to the submodules for this module

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/microanalyticScore/modules/{moduleId}/submodules \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/submodules',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/microanalyticScore/modules/{moduleId}/submodules', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/microanalyticScore/modules/{moduleId}/submodules", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /modules/{moduleId}/submodules

    Retrieves the headers of the collection of submodules contained by the specified module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the submodule collection.
    start query integer(int64) false The index of the first submodule to return.
    limit query integer false The maximum number of submodules to return.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found The module that contains the submodules collection could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module was last modified.
    200 Etag string The entity tag that identifies this revision of the module.

    Get a submodule of the module

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.microanalytic.submodule+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.microanalytic.submodule+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.microanalytic.submodule+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.microanalytic.submodule+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /modules/{moduleId}/submodules/{submoduleId}

    Returns detailed information about the specified submodule of the specified module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the submodule.
    submoduleId path string true The identifier of the submodule.

    Example responses

    Get submodule response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/driverpackage/submodules",
          "uri": "/microanalyticScore/modules/driverpackage/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
          "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
          "type": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
          "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        }
      ],
      "version": 1,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-05T20:03:46.066Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
      "moduleId": "driverPackage",
      "id": "subpackage0",
      "name": "subpackage0",
      "language": "ds2",
      "description": "sub package 0"
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/driverpackage/submodules",
          "uri": "/microanalyticScore/modules/driverpackage/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
          "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
          "type": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
          "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        }
      ],
      "version": 1,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-05T20:03:46.066Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
      "moduleId": "driverPackage",
      "id": "subpackage0",
      "name": "subpackage0",
      "language": "ds2",
      "description": "sub package 0"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. submodule
    404 Not Found The requested module or submodule could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module that contains this submodule was last modified.
    200 Etag string The entity tag that identifies this revision of the module that contains this submodule.

    Get headers for a submodule of the module

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /modules/{moduleId}/submodules/{submoduleId}

    Returns header information about the specified submodule of the specified module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the submodule.
    submoduleId path string true The identifier of the submodule.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found The requested module or submodule could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module that contains this submodule was last modified.
    200 Etag string The entity tag that identifies this revision of the module that contains this submodule.

    Get submodule source

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}/source \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.microanalytic.module.source+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.microanalytic.module.source+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}/source',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.microanalytic.module.source+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}/source', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.microanalytic.module.source+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}/source", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /modules/{moduleId}/submodules/{submoduleId}/source

    Retrieves the source code for the specified submodule and module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the submodule.
    submoduleId path string true The identifier of the submodule.

    Example responses

    Get submodule source response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
          "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
          "type": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
          "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-05T20:03:46.066Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
      "moduleId": "driverpackage",
      "submoduleId": "subpackage0",
      "source": "ds2_options sas;package subpackage0;method test_sub(int i);end;endpackage;"
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
          "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0",
          "type": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
          "uri": "/microanalyticScore/modules/driverpackage/submodules/subpackage0/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        }
      ],
      "version": 2,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-05T20:03:46.066Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-05T20:03:46.066Z",
      "moduleId": "driverpackage",
      "submoduleId": "subpackage0",
      "source": "ds2_options sas;package subpackage0;method test_sub(int i);end;endpackage;"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. moduleSource
    404 Not Found The requested module or submodule could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is from a SAS service.
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module that contains this submodule was last modified.
    200 Etag string The entity tag that identifies this revision of the module that contains this submodule.

    Get headers for submodule source

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}/source \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}/source',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}/source', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/microanalyticScore/modules/{moduleId}/submodules/{submoduleId}/source", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /modules/{moduleId}/submodules/{submoduleId}/source

    Retrieves the header for the source code for the specified submodule and module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the submodule.
    submoduleId path string true The identifier of the submodule.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found The requested module or submodule could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module that contains this submodule was last modified.
    200 Etag string The entity tag that identifies this revision of the module that contains this submodule.

    Steps

    Contains the operations for step resources.

    Get module steps

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/modules/{moduleId}/steps \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/steps',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/modules/{moduleId}/steps', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/modules/{moduleId}/steps", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /modules/{moduleId}/steps

    Retrieves the collection of steps that correspond to a specific module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the step collection.
    start query integer(int64) false The index of the first step to return.
    limit query integer false The maximum number of steps to return.

    Example responses

    Get module steps response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule/steps?start=0&limit=20",
          "uri": "/microanalyticScore/modules/samplemodule/steps?start=0&limit=20",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "/microanalyticScore/modules/samplemodule/steps",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.module"
        }
      ],
      "name": "steps",
      "accept": "application/vnd.sas.microanalytic.module.step",
      "count": 6,
      "items": [
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_charn_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_charn_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_charn_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "stringArray",
              "dim": 4,
              "size": 12
            }
          ],
          "outputs": [
            {
              "name": "out_array",
              "type": "stringArray",
              "dim": 4,
              "size": 12
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_varchar_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_varchar_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_varchar_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_varchar_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_varchar_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_varchar_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_varchar_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "stringArray",
              "dim": 3,
              "size": 512
            }
          ],
          "outputs": [
            {
              "name": "out_array",
              "type": "stringArray",
              "dim": 3,
              "size": 0
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_int_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_int_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_int_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_int_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_int_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_int_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_int_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "integerArray",
              "dim": 5,
              "size": 0
            }
          ],
          "outputs": [
            {
              "name": "out_array",
              "type": "integerArray",
              "dim": 5,
              "size": 0
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_float_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_float_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_float_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_float_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_float_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_float_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_float_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "decimalArray"
            }
          ],
          "dim": 2,
          "size": 0,
          "outputs": [
            {
              "name": "out_array",
              "type": "decimalArray",
              "dim": 2,
              "size": 0
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_bigint_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_bigint_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_bigint_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_bigint_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_bigint_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_bigint_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_bigint_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "bigintArray",
              "dim": 1,
              "size": 0
            }
          ],
          "outputs": [
            {
              "name": "out_array",
              "type": "bigintArray",
              "dim": 1,
              "size": 0
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_arrays",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_arrays",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_arrays",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_arrays",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_arrays",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_arrays",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_arrays",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_charn_array",
              "type": "stringArray",
              "dim": 4,
              "size": 12
            },
            {
              "name": "in_varchar_array",
              "type": "stringArray",
              "dim": 1,
              "size": 512
            },
            {
              "name": "in_int_array",
              "type": "integerArray",
              "dim": 5,
              "size": 0
            },
            {
              "name": "in_double_array",
              "type": "decimalArray",
              "dim": 2,
              "size": 0
            },
            {
              "name": "in_bigint_array",
              "type": "bigintArray",
              "dim": 1,
              "size": 0
            }
          ],
          "outputs": [
            {
              "name": "out_charn_array",
              "type": "stringArray",
              "dim": 4,
              "size": 12
            },
            {
              "name": "out_varchar_array",
              "type": "stringArray",
              "dim": 1,
              "size": 512
            },
            {
              "name": "out_int_array",
              "type": "integerArray",
              "dim": 5,
              "size": 0
            },
            {
              "name": "out_double_array",
              "type": "decimalArray",
              "dim": 2,
              "size": 0
            },
            {
              "name": "out_bigint_array",
              "type": "bigintArray",
              "dim": 1,
              "size": 0
            }
          ]
        }
      ],
      "version": 2
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule/steps?start=0&limit=20",
          "uri": "/microanalyticScore/modules/samplemodule/steps?start=0&limit=20",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "/microanalyticScore/modules/samplemodule/steps",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.module"
        }
      ],
      "name": "steps",
      "accept": "application/vnd.sas.microanalytic.module.step",
      "count": 6,
      "items": [
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_charn_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_charn_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_charn_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "stringArray",
              "dim": 4,
              "size": 12
            }
          ],
          "outputs": [
            {
              "name": "out_array",
              "type": "stringArray",
              "dim": 4,
              "size": 12
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_varchar_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_varchar_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_varchar_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_varchar_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_varchar_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_varchar_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_varchar_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "stringArray",
              "dim": 3,
              "size": 512
            }
          ],
          "outputs": [
            {
              "name": "out_array",
              "type": "stringArray",
              "dim": 3,
              "size": 0
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_int_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_int_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_int_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_int_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_int_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_int_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_int_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "integerArray",
              "dim": 5,
              "size": 0
            }
          ],
          "outputs": [
            {
              "name": "out_array",
              "type": "integerArray",
              "dim": 5,
              "size": 0
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_float_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_float_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_float_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_float_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_float_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_float_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_float_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "decimalArray"
            }
          ],
          "dim": 2,
          "size": 0,
          "outputs": [
            {
              "name": "out_array",
              "type": "decimalArray",
              "dim": 2,
              "size": 0
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_bigint_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_bigint_array",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_bigint_array",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_bigint_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_bigint_array",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_bigint_array",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_bigint_array",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_array",
              "type": "bigintArray",
              "dim": 1,
              "size": 0
            }
          ],
          "outputs": [
            {
              "name": "out_array",
              "type": "bigintArray",
              "dim": 1,
              "size": 0
            }
          ]
        },
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/modules/samplemodule/steps",
              "uri": "/microanalyticScore/modules/samplemodule/steps",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_arrays",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_arrays",
              "type": "application/vnd.sas.microanalytic.module.step"
            },
            {
              "method": "POST",
              "rel": "execute",
              "href": "/microanalyticScore/modules/samplemodule/steps/copy_arrays",
              "uri": "/microanalyticScore/modules/samplemodule/steps/copy_arrays",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.microanalytic.module.step.output"
            },
            {
              "method": "POST",
              "rel": "validateStepInput",
              "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_arrays",
              "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_arrays",
              "type": "application/vnd.sas.microanalytic.module.step.input",
              "responseType": "application/vnd.sas.validation"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-03-15T21:19:04.062Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
          "id": "copy_arrays",
          "moduleId": "samplemodule",
          "inputs": [
            {
              "name": "in_charn_array",
              "type": "stringArray",
              "dim": 4,
              "size": 12
            },
            {
              "name": "in_varchar_array",
              "type": "stringArray",
              "dim": 1,
              "size": 512
            },
            {
              "name": "in_int_array",
              "type": "integerArray",
              "dim": 5,
              "size": 0
            },
            {
              "name": "in_double_array",
              "type": "decimalArray",
              "dim": 2,
              "size": 0
            },
            {
              "name": "in_bigint_array",
              "type": "bigintArray",
              "dim": 1,
              "size": 0
            }
          ],
          "outputs": [
            {
              "name": "out_charn_array",
              "type": "stringArray",
              "dim": 4,
              "size": 12
            },
            {
              "name": "out_varchar_array",
              "type": "stringArray",
              "dim": 1,
              "size": 512
            },
            {
              "name": "out_int_array",
              "type": "integerArray",
              "dim": 5,
              "size": 0
            },
            {
              "name": "out_double_array",
              "type": "decimalArray",
              "dim": 2,
              "size": 0
            },
            {
              "name": "out_bigint_array",
              "type": "bigintArray",
              "dim": 1,
              "size": 0
            }
          ]
        }
      ],
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. stepCollection
    404 Not Found The requested module that contains the step collection could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module that contains this submodule was last modified.
    200 Etag string The entity tag that identifies this revision of the module that contains this submodule.

    Get headers for module steps

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/microanalyticScore/modules/{moduleId}/steps \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/steps',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/microanalyticScore/modules/{moduleId}/steps', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/microanalyticScore/modules/{moduleId}/steps", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /modules/{moduleId}/steps

    Retrieves the headers for collection of steps that correspond to a specific module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the step collection.
    start query integer(int64) false The index of the first step to return.
    limit query integer false The maximum number of steps to return.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found The requested module that contains the step collection could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module that contains the steps was last modified.
    200 Etag string The entity tag that identifies the module that contains the step collection.

    Get a specific step of the module

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.microanalytic.module.step+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.microanalytic.module.step+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.microanalytic.module.step+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.microanalytic.module.step+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /modules/{moduleId}/steps/{stepId}

    Returns detailed information about the input and output signatures used to execute a specific step of the module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module containing the step.
    stepId path string true The identifier of the step.

    Example responses

    Get module step response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
          "uri": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
          "type": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "POST",
          "rel": "execute",
          "href": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
          "uri": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
          "type": "application/vnd.sas.microanalytic.module.step.input",
          "responseType": "application/vnd.sas.microanalytic.module.step.output"
        },
        {
          "method": "POST",
          "rel": "validateStepInput",
          "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_charn_array",
          "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_charn_array",
          "type": "application/vnd.sas.microanalytic.module.step.input",
          "responseType": "application/vnd.sas.validation"
        }
      ],
      "version": 1,
      "createdBy": "bob",
      "creationTimeStamp": "2022-03-15T21:19:04.062Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
      "id": "copy_charn_array",
      "moduleId": "samplemodule",
      "inputs": [
        {
          "name": "in_array",
          "type": "stringArray",
          "dim": 4,
          "size": 12
        }
      ],
      "outputs": [
        {
          "name": "out_array",
          "type": "stringArray",
          "dim": 4,
          "size": 12
        }
      ]
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/modules/samplemodule/steps",
          "uri": "/microanalyticScore/modules/samplemodule/steps",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
          "uri": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
          "type": "application/vnd.sas.microanalytic.module.step"
        },
        {
          "method": "POST",
          "rel": "execute",
          "href": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
          "uri": "/microanalyticScore/modules/samplemodule/steps/copy_charn_array",
          "type": "application/vnd.sas.microanalytic.module.step.input",
          "responseType": "application/vnd.sas.microanalytic.module.step.output"
        },
        {
          "method": "POST",
          "rel": "validateStepInput",
          "href": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_charn_array",
          "uri": "/microanalyticScore/commons/validations/modules/samplemodule/steps/copy_charn_array",
          "type": "application/vnd.sas.microanalytic.module.step.input",
          "responseType": "application/vnd.sas.validation"
        }
      ],
      "version": 1,
      "createdBy": "bob",
      "creationTimeStamp": "2022-03-15T21:19:04.062Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-04T19:49:02.867Z",
      "id": "copy_charn_array",
      "moduleId": "samplemodule",
      "inputs": [
        {
          "name": "in_array",
          "type": "stringArray",
          "dim": 4,
          "size": 12
        }
      ],
      "outputs": [
        {
          "name": "out_array",
          "type": "stringArray",
          "dim": 4,
          "size": 12
        }
      ]
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. step
    404 Not Found The requested module or step could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module that contains this step was last modified.
    200 Etag string The entity tag that identifies this revision of the module that contains this step.

    Get the header for a specific step of the module

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /modules/{moduleId}/steps/{stepId}

    Returns header information of a specific step of the module.

    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module containing the step.
    stepId path string true The identifier of the step.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found The requested module or step could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the module that contains this step was last modified.
    200 Etag string The entity tag that identifies this revision of the module that contains this step.

    Execute a step

    Code samples

    # You can also use wget
    curl -X POST https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.microanalytic.module.step.input+json' \
      -H 'Accept: application/vnd.sas.microanalytic.module.step.output+json'
    
    
    const inputBody = '{
      "inputs": [
        {
          "name": "in_string",
          "value": "In String"
        },
        {
          "name": "in_int",
          "value": 1
        },
        {
          "name": "in_float",
          "value": -0.2
        },
        {
          "name": "in_boolean",
          "value": 1
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.microanalytic.module.step.input+json',
      'Accept':'application/vnd.sas.microanalytic.module.step.output+json'
    };
    
    fetch('https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId}',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.microanalytic.module.step.input+json',
      'Accept': 'application/vnd.sas.microanalytic.module.step.output+json'
    }
    
    r = requests.post('https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.microanalytic.module.step.input+json"},
            "Accept": []string{"application/vnd.sas.microanalytic.module.step.output+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/microanalyticScore/modules/{moduleId}/steps/{stepId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /modules/{moduleId}/steps/{stepId}

    Executes the step with the specified input values. Depending on the value that is assigned to the waitTime parameter, execution occurs in one of the following ways: If the assigned value is missing, the call waits until the execution is complete before it returns. The outputs variable in the reply contains the output of the execution. The executionState variable is assigned the value completed in the returned stepOutput object.

    If the assigned value is a positive number, the call waits the specified number of milliseconds. If the execution completes within the waitTime value, the outputs variable in the reply contains the output of the execution and the executionState variable is set to completed.

    If the execution does not complete within waitTime value, the outputs variable is empty and the executionState variable is assigned the value timedOut in the returned stepOutput object.

    If the assigned value is zero, the call returns immediately after validation. The outputs variable is empty and the executionState variable is assigned the value submitted in the returned stepOutput object.

    If the assigned value is non-numeric or a negative value, the execution fails with an error.

    Body parameter

    Execute step request.

    {
      "inputs": [
        {
          "name": "in_string",
          "value": "In String"
        },
        {
          "name": "in_int",
          "value": 1
        },
        {
          "name": "in_float",
          "value": -0.2
        },
        {
          "name": "in_boolean",
          "value": 1
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module that contains the step to execute.
    stepId path string true The identifier of the step to execute.
    waitTime query integer false A value that determines how to execute the step. For more information, see the operation description above and Synchronous, Asynchronous, and Timed Execution.
    body body stepInput true The input values to use for the execution.

    Example responses

    Execute step response.

    {
      "links": [],
      "version": 2,
      "moduleId": "endtoend",
      "stepId": "variable_test",
      "executionState": "completed",
      "metadata": {
        "module_id": "endtoend",
        "step_id": "variable_test"
      },
      "outputs": [
        {
          "name": "out_string",
          "value": "gnirtS nI"
        },
        {
          "name": "out_int",
          "value": -1
        },
        {
          "name": "out_float",
          "value": 0.9100000000000001
        },
        {
          "name": "out_boolean",
          "value": 0
        }
      ]
    }
    
    {
      "links": [],
      "version": 2,
      "moduleId": "endtoend",
      "stepId": "variable_test",
      "executionState": "completed",
      "metadata": {
        "module_id": "endtoend",
        "step_id": "variable_test"
      },
      "outputs": [
        {
          "name": "out_string",
          "value": "gnirtS nI"
        },
        {
          "name": "out_int",
          "value": -1
        },
        {
          "name": "out_float",
          "value": 0.9100000000000001
        },
        {
          "name": "out_boolean",
          "value": 0
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The StepOutput was created. stepOutput
    400 Bad Request The specified inputs were invalid. The step could not be executed. error2
    404 Not Found The requested module or step could not be found. error2

    Validate step inputs

    Code samples

    # You can also use wget
    curl -X POST https://example.com/microanalyticScore/commons/validations/modules/{moduleId}/steps/{stepId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.microanalytic.module.step.input+json' \
      -H 'Accept: application/vnd.sas.validation+json'
    
    
    const inputBody = '{
      "inputs": [
        {
          "name": "in_string",
          "value": "In String"
        },
        {
          "name": "in_int",
          "value": 1
        },
        {
          "name": "in_float",
          "value": -0.2
        },
        {
          "name": "in_boolean",
          "value": 1
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.microanalytic.module.step.input+json',
      'Accept':'application/vnd.sas.validation+json'
    };
    
    fetch('https://example.com/microanalyticScore/commons/validations/modules/{moduleId}/steps/{stepId}',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.microanalytic.module.step.input+json',
      'Accept': 'application/vnd.sas.validation+json'
    }
    
    r = requests.post('https://example.com/microanalyticScore/commons/validations/modules/{moduleId}/steps/{stepId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.microanalytic.module.step.input+json"},
            "Accept": []string{"application/vnd.sas.validation+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/microanalyticScore/commons/validations/modules/{moduleId}/steps/{stepId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /commons/validations/modules/{moduleId}/steps/{stepId}

    Validates input values that are used to execute the step against the expected input signature of the step. If the input is not formatted properly or does not match the input requirements of the step, one violation of each input parameter is reported.

    Body parameter

    Validate step input request.

    {
      "inputs": [
        {
          "name": "in_string",
          "value": "In String"
        },
        {
          "name": "in_int",
          "value": 1
        },
        {
          "name": "in_float",
          "value": -0.2
        },
        {
          "name": "in_boolean",
          "value": 1
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    moduleId path string true The identifier of the module to update.
    stepId path string true The identifier of the step to validate.
    body body stepInput true The input values to validate against the expected input signature of the step.

    Example responses

    Validate step input response.

    {
      "version": 1,
      "valid": true
    }
    
    {
      "version": 1,
      "valid": true
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The request succeeded. Inline
    400 Bad Request The request body is missing or invalid. error2
    404 Not Found The requested module or step could not be found. error2
    Response Schema

    Status Code 201

    Validation Response

    Name Type Required Restrictions Description
    » version integer true none This media type's schema version number. This representation is version 1.
    » valid boolean true none true if and only if the validation was successful.
    » error error2 false none The representation of an error.
    »» message string false none The message for the error.
    »» id string false none The string ID for the error.
    »» errorCode integer false none The numeric ID for the error.
    »» httpStatusCode integer true none The HTTP status code for the error.
    »» details [string] false none Messages that provide additional details about the cause of the error.
    »» remediation string false none A message that describes how to resolve the error.
    »» errors [error2] false none Any additional errors that occurred.
    »»» Error error2 false none The representation of an error.
    »» links [link] false none The links that apply to the error.
    »»» Link link false none A link to a related operation or resource.
    »»»» method string false none The HTTP method for the link.
    »»»» rel string true none The relationship of the link to the resource.
    »»»» uri string false none The relative URI for the link.
    »»»» href string false none The URL for the link.
    »»»» title string false none The title for the link.
    »»»» type string false none The media type or link type for the link.
    »»»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    »» version integer true none The version number of the error representation. This representation is version 2.
    » links [link] false none An array of links to related resources and actions.
    »» Link link false none A link to a related operation or resource.

    Jobs

    Contains the operations for job resources.

    Get jobs

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/jobs \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/microanalyticScore/jobs',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/jobs', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/jobs", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /jobs

    Retrieves the collection of jobs that have been submitted to the service. Standard paging options are supported.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first job to return.
    limit query integer false The maximum number of jobs to return.
    filter query string(filter-criteria) false The criteria for filtering the modules. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the modules. See Sorting in REST APIs.

    Example responses

    Get jobs response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/jobs?start=0&limit=20",
          "uri": "/microanalyticScore/jobs?start=0&limit=20",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "createJob",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.job"
        }
      ],
      "name": "jobs",
      "accept": "application/vnd.sas.microanalytic.job",
      "start": 0,
      "count": 1,
      "items": [
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/jobs",
              "uri": "/microanalyticScore/jobs",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.job"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
              "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
              "type": "application/vnd.sas.microanalytic.job"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/source",
              "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/submodules",
              "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
              "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9"
            },
            {
              "method": "GET",
              "rel": "module",
              "href": "/microanalyticScore/modules/driverpackage_job",
              "uri": "/microanalyticScore/modules/driverpackage_job",
              "type": "application/vnd.sas.microanalytic.module"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-10T20:16:21.416Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-10T20:16:27.336Z",
          "id": "8418e47f-0593-4fdf-9bc8-407242e4d6b9",
          "description": "driver package",
          "moduleId": "driverpackage_job",
          "state": "completed",
          "errors": []
        }
      ],
      "limit": 20,
      "version": 2
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/jobs?start=0&limit=20",
          "uri": "/microanalyticScore/jobs?start=0&limit=20",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "createJob",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.microanalytic.module.definition",
          "responseType": "application/vnd.sas.microanalytic.job"
        }
      ],
      "name": "jobs",
      "accept": "application/vnd.sas.microanalytic.job",
      "start": 0,
      "count": 1,
      "items": [
        {
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/microanalyticScore/jobs",
              "uri": "/microanalyticScore/jobs",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.job"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
              "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
              "type": "application/vnd.sas.microanalytic.job"
            },
            {
              "method": "GET",
              "rel": "source",
              "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/source",
              "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/source",
              "type": "application/vnd.sas.microanalytic.module.source"
            },
            {
              "method": "GET",
              "rel": "submodules",
              "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/submodules",
              "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/submodules",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.microanalytic.submodule"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
              "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9"
            },
            {
              "method": "GET",
              "rel": "module",
              "href": "/microanalyticScore/modules/driverpackage_job",
              "uri": "/microanalyticScore/modules/driverpackage_job",
              "type": "application/vnd.sas.microanalytic.module"
            }
          ],
          "version": 1,
          "createdBy": "bob",
          "creationTimeStamp": "2022-05-10T20:16:21.416Z",
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2022-05-10T20:16:27.336Z",
          "id": "8418e47f-0593-4fdf-9bc8-407242e4d6b9",
          "description": "driver package",
          "moduleId": "driverpackage_job",
          "state": "completed",
          "errors": []
        }
      ],
      "limit": 20,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. jobCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is from a SAS service.

    Create an asynchronous job

    Code samples

    # You can also use wget
    curl -X POST https://example.com/microanalyticScore/jobs \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.microanalytic.module.definition+json' \
      -H 'Accept: application/vnd.sas.microanalytic.job+json'
    
    
    const inputBody = '{
      "version": 1,
      "description": "Driver package job request.",
      "scope": "public",
      "source": "ds2_options sas;package driverPackage_job;method test_driver();dcl package subpackage0_job\nsub0();dcl int i;i = 1;sub0.test_sub(i);end;endpackage;\n",
      "submodules": [
        {
          "name": "subpackage0_job",
          "description": "sub package 0",
          "language": "ds2",
          "source": "ds2_options sas;package subpackage0_job;method test_sub(int i);end;endpackage;"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.microanalytic.module.definition+json',
      'Accept':'application/vnd.sas.microanalytic.job+json'
    };
    
    fetch('https://example.com/microanalyticScore/jobs',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.microanalytic.module.definition+json',
      'Accept': 'application/vnd.sas.microanalytic.job+json'
    }
    
    r = requests.post('https://example.com/microanalyticScore/jobs', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.microanalytic.module.definition+json"},
            "Accept": []string{"application/vnd.sas.microanalytic.job+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/microanalyticScore/jobs", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /jobs

    Create a job to asynchronously publish the submitted module definition. If moduleId is set, the specified module is updated with the submitted module definition.

    Body parameter

    Create job request.

    {
      "version": 1,
      "description": "Driver package job request.",
      "scope": "public",
      "source": "ds2_options sas;package driverPackage_job;method test_driver();dcl package subpackage0_job\nsub0();dcl int i;i = 1;sub0.test_sub(i);end;endpackage;\n",
      "submodules": [
        {
          "name": "subpackage0_job",
          "description": "sub package 0",
          "language": "ds2",
          "source": "ds2_options sas;package subpackage0_job;method test_sub(int i);end;endpackage;"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    moduleId query string false The moduleId of the existing module to update asynchronously.
    body body moduleDefinition true A definition of the module to be applied in the update.

    Example responses

    Create job response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "type": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/source",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/submodules",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea"
        }
      ],
      "version": 1,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-10T13:09:46.154Z",
      "modifiedBy": "sasboot",
      "modifiedTimeStamp": "2022-05-10T13:09:46.154Z",
      "id": "d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
      "description": "driver package",
      "moduleId": "driverpackage_job",
      "state": "completed",
      "errors": []
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "type": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/source",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/submodules",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea"
        }
      ],
      "version": 1,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-10T13:09:46.154Z",
      "modifiedBy": "sasboot",
      "modifiedTimeStamp": "2022-05-10T13:09:46.154Z",
      "id": "d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
      "description": "driver package",
      "moduleId": "driverpackage_job",
      "state": "completed",
      "errors": []
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "type": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/source",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/submodules",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea"
        }
      ],
      "version": 1,
      "createdBy": "sasboot",
      "creationTimeStamp": "2022-05-10T13:09:46.154Z",
      "modifiedBy": "sasboot",
      "modifiedTimeStamp": "2022-05-10T13:09:46.154Z",
      "id": "d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
      "description": "driver package",
      "moduleId": "driverpackage_job",
      "state": "pending",
      "errors": []
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "type": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/source",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/submodules",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
          "uri": "/microanalyticScore/jobs/d831b1d3-fc00-49c1-ac39-a9c4ed76bbea"
        }
      ],
      "version": 1,
      "createdBy": "sasboot",
      "creationTimeStamp": "2022-05-10T13:09:46.154Z",
      "modifiedBy": "sasboot",
      "modifiedTimeStamp": "2022-05-10T13:09:46.154Z",
      "id": "d831b1d3-fc00-49c1-ac39-a9c4ed76bbea",
      "description": "driver package",
      "moduleId": "driverpackage_job",
      "state": "pending",
      "errors": []
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The request succeeded. The job completed compilation before the POST operation returned. job
    202 Accepted The job accepted the module for compilation and has not completed (typical). job
    400 Bad Request The submitted module definition was invalid or the module specified by moduleId was not found. The job could not be created. error2
    Response Headers
    Status Header Type Format Description
    201 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the job was last modified.
    201 Etag string The entity tag that identifies this revision of this job.
    201 Location string uri The URL of the job.
    202 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the job was last modified.
    202 Etag string The entity tag that identifies the revision of this job.
    202 Location string uri The URL of the job.

    Get job

    Code samples

    # You can also use wget
    curl -X GET https://example.com/microanalyticScore/jobs/{jobId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.microanalytic.job+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.microanalytic.job+json'
    };
    
    fetch('https://example.com/microanalyticScore/jobs/{jobId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.microanalytic.job+json'
    }
    
    r = requests.get('https://example.com/microanalyticScore/jobs/{jobId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.microanalytic.job+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/microanalyticScore/jobs/{jobId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /jobs/{jobId}

    Returns detailed information about the job with the specified ID.

    Parameters
    Name In Type Required Description
    jobId path string true The identifier of the job to retrieve.

    Example responses

    Get job response.

    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
          "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
          "type": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/source",
          "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/submodules",
          "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
          "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9"
        },
        {
          "method": "GET",
          "rel": "module",
          "href": "/microanalyticScore/modules/driverpackage_job",
          "uri": "/microanalyticScore/modules/driverpackage_job",
          "type": "application/vnd.sas.microanalytic.module"
        }
      ],
      "version": 1,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-10T20:16:21.416Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-10T20:16:27.336Z",
      "id": "8418e47f-0593-4fdf-9bc8-407242e4d6b9",
      "description": "driver package",
      "moduleId": "driverpackage_job",
      "state": "completed",
      "errors": []
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/microanalyticScore/jobs",
          "uri": "/microanalyticScore/jobs",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
          "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
          "type": "application/vnd.sas.microanalytic.job"
        },
        {
          "method": "GET",
          "rel": "source",
          "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/source",
          "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/source",
          "type": "application/vnd.sas.microanalytic.module.source"
        },
        {
          "method": "GET",
          "rel": "submodules",
          "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/submodules",
          "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9/submodules",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.microanalytic.submodule"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9",
          "uri": "/microanalyticScore/jobs/8418e47f-0593-4fdf-9bc8-407242e4d6b9"
        },
        {
          "method": "GET",
          "rel": "module",
          "href": "/microanalyticScore/modules/driverpackage_job",
          "uri": "/microanalyticScore/modules/driverpackage_job",
          "type": "application/vnd.sas.microanalytic.module"
        }
      ],
      "version": 1,
      "createdBy": "bob",
      "creationTimeStamp": "2022-05-10T20:16:21.416Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2022-05-10T20:16:27.336Z",
      "id": "8418e47f-0593-4fdf-9bc8-407242e4d6b9",
      "description": "driver package",
      "moduleId": "driverpackage_job",
      "state": "completed",
      "errors": []
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. job
    404 Not Found The requested job could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the job was last modified.
    200 Etag string The entity tag that identifies this revision of this job.

    Get headers for a job

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/microanalyticScore/jobs/{jobId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/microanalyticScore/jobs/{jobId}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/microanalyticScore/jobs/{jobId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/microanalyticScore/jobs/{jobId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /jobs/{jobId}

    Returns header information about the job with the specified ID.

    Parameters
    Name In Type Required Description
    jobId path string true The identifier of the job.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found The requested job could not be found. error2
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string The timestamp (in EEE, dd MMM yyyy HH:mm:ss GMT format) that indicates when the job was last modified.
    200 Etag string The entity tag that identifies this job.

    Delete job

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/microanalyticScore/jobs/{jobId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/microanalyticScore/jobs/{jobId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/microanalyticScore/jobs/{jobId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/microanalyticScore/jobs/{jobId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /jobs/{jobId}

    Deletes the job with the specified ID.

    Parameters
    Name In Type Required Description
    jobId path string true The identifier of the job to delete.
    Responses
    Status Meaning Description Schema
    204 No Content The job was deleted or not found. None

    Schemas

    module

    {
      "id": "string",
      "name": "string",
      "revision": 0,
      "description": "string",
      "scope": "public",
      "language": "ds2",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "stepsIds": [
        "string"
      ],
      "properties": [
        {
          "name": "string",
          "value": "string"
        }
      ],
      "warnings": [
        {
          "message": "string",
          "id": "string",
          "errorCode": 0,
          "httpStatusCode": 0,
          "details": [
            "string"
          ],
          "remediation": "string",
          "errors": [
            null
          ],
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 2
    }
    
    

    Module

    Properties
    Name Type Required Restrictions Description
    id string false none A generated unique string that identifies a module in an installation.
    name string false none The name that is associated with a module.
    revision integer false none A whole number that indicates the revision of a module. It starts at 1 and increments by 1 each time the module is revised.
    description string false none Text that describes the rules and logic performed by the module.
    scope string false none The scope restricts how a module can be used. The value 'public' indicates the module is available to be called outside another module. The value 'private' indicates that a module can be called only from within another module.
    language string false none The language of the module source. DS2 indicates that the module source is written in the DS2 language.
    creationTimeStamp string(date-time) false none The initial creation time of the module.
    modifiedTimeStamp string(date-time) false none The last revision time of the module.
    stepsIds [string] false none An array of step IDs in the module.
    properties [property] false none The properties specified for the module.
    warnings [object] false none Optional object that is included if warnings are generated when this resource is compiled.
    » Error object false none The representation of an error.
    »» message string false none The message for the error.
    »» id string false none The string ID for the error.
    »» errorCode integer false none The numeric ID for the error.
    »» httpStatusCode integer true none The HTTP status code for the error.
    »» details [string] false none Messages that provide additional details about the cause of the error.
    »» remediation string false none A message that describes how to resolve the error.
    »» errors [error2] false none Any additional errors that occurred.
    »» links [link] false none The links that apply to the error.
    »» version integer true none The version number of the error representation. This representation is version 2.
    links [object] false none The link relations for the module.
    » Link object false none A link to a related operation or resource.
    »» method string false none The HTTP method for the link.
    »» rel string true none The relationship of the link to the resource.
    »» uri string false none The relative URI for the link.
    »» href string false none The URL for the link.
    »» title string false none The title for the link.
    »» type string false none The media type or link type for the link.
    »» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    version integer false none The media type's schema version number. The current version is 2.
    Enumerated Values
    Property Value
    scope public
    scope private
    language ds2

    submodule

    {
      "id": "string",
      "name": "string",
      "moduleId": "string",
      "language": "ds2",
      "description": "string",
      "attributes": {
        "keyValue": "string"
      },
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 1
    }
    
    

    Submodule

    Properties
    Name Type Required Restrictions Description
    id string false none A string that, together with the moduleId, uniquely identifies the submodule.
    name string false none The name that is associated with the submodule.
    moduleId string false none A unique string that identifies the module that contains this submodule.
    language string false none A string that describes the type or language of the submodule.
    description string false none Text that describes the rules and logic performed by the submodule.
    attributes object false none Optional attributes that are determined by the language.
    » keyValue string false none Contains the key value that is needed to access the keystore. It is required for ASTORE submodules and ignored for DS2 submodules.
    creationTimeStamp string(date-time) false none The initial creation time of the submodule.
    modifiedTimeStamp string(date-time) false none The last revision time of the submodule.
    links [link] false none The link relations for the submodule.
    version integer false none The media type's schema version number. The current version is 1.
    Enumerated Values
    Property Value
    language ds2
    language astore

    moduleDefinition

    {
      "id": "string",
      "description": "",
      "scope": "public",
      "type": "text/vnd.sas.source.ds2",
      "source": "string",
      "properties": [],
      "submodules": [
        {
          "name": "string",
          "language": "ds2",
          "description": "",
          "source": "string",
          "attributes": {
            "keyValue": "string"
          }
        }
      ],
      "version": 2
    }
    
    

    Module Definition

    Properties
    Name Type Required Restrictions Description
    id string false none An optional identifier for the module. If not specified, the source code of the module is parsed to determine the value of the module identifier.
    description string false none Optional text that describes the logic or functionality of the module.
    scope string true none The scope restricts how a module can be used. The value 'public' indicates the module is available to be called outside another module. The value 'private' indicates that a module can be called only from within another module.
    type string false none Optional text that describes the source code type. Currently, the only valid value is text/vnd.sas.source.ds2.
    source string true none The source code of the module.
    properties [property] false none Additional metadata about the module. If a property definition is not needed, this can be omitted or specified as an empty array.
    submodules [submoduleDefinition] false none Optional list of submodules for this module.
    version integer false none The media type's schema version number. The current version is 2.
    Enumerated Values
    Property Value
    scope public
    scope private
    type text/vnd.sas.source.ds2

    submoduleDefinition

    {
      "name": "string",
      "language": "ds2",
      "description": "",
      "source": "string",
      "attributes": {
        "keyValue": "string"
      }
    }
    
    

    Submodule Definition

    Properties
    Name Type Required Restrictions Description
    name string false none An optional name of the submodule module. If not present, the source code of the submodule is parsed to determine the value of the submodule name.
    language string true none String that describes the type or language of the submodule.
    description string false none Optional text that describes the logic or functionality of the submodule.
    source string true none For DS2 modules, this must contain the source code of the module. For analytic store (ASTORE) modules, this contains the absolute path to a file that contains the ASTORE module. The file must be accessible to the Micro Analytic Service server, not the client. For a clustered deployment, the file must be accessible from each cluster member. Locating the file on a network share is one way to accomplish this.
    attributes object false none Optional attributes that are determined by the language.
    » keyValue string false none Contains the key value that is needed to access the keystore. It is required for ASTORE submodules and ignored for DS2 submodules.
    Enumerated Values
    Property Value
    language ds2
    language astore

    moduleSource

    {
      "version": 2,
      "moduleId": "string",
      "submoduleId": "string",
      "source": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Module Source

    Properties
    Name Type Required Restrictions Description
    version integer false none The media type's schema version number. The current version is 2.
    moduleId string false none A unique string that identifies the module that contains this source.
    submoduleId string false none Optional unique string that identifies the submodule that contains this source. This is omitted if the source code is for a module.
    source string false none The source code used.
    links [link] false none A collection of links to related resources or operations.

    step

    {
      "id": "string",
      "moduleId": "string",
      "description": "string",
      "inputs": [
        {
          "name": "string",
          "type": "decimal",
          "size": 0,
          "dim": 0
        }
      ],
      "outputs": [
        {
          "name": "string",
          "type": "decimal",
          "size": 0,
          "dim": 0
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 1
    }
    
    

    Step

    Properties
    Name Type Required Restrictions Description
    id string false none The identifier of a step that is included in the compiled module. The identifier is user-specified and is often a name for the step.
    moduleId string false none The identifier of the module that contains the step.
    description string false none Text that describes the logic performed by the step.
    inputs [stepParameter] false none Describes information about the specific input values that should be specified in the request body when a step is executed.
    outputs [stepParameter] false none Describes information about the specific output values that should be expected in the response body of step execution.
    links [link] false none A collection of links to related resources or operations.
    version integer false none The media type's schema version number. The current version is 1.

    stepInput

    {
      "inputs": [
        {
          "name": "string",
          "value": 0
        }
      ],
      "version": 1,
      "metadata": {
        "property1": "string",
        "property2": "string"
      }
    }
    
    

    Step Input

    Properties
    Name Type Required Restrictions Description
    inputs [anyOf] true none The values to pass to the step as inputs for validation or execution. The order of the variables should match the order presented in the input signature.

    anyOf

    Name Type Required Restrictions Description
    » anonymous numberVariable false none A name/value pair that represents an input or output variable of type number.

    or

    Name Type Required Restrictions Description
    » anonymous stringVariable false none A name/value pair that represents an input or output variable of type String.

    or

    Name Type Required Restrictions Description
    » anonymous booleanVariable false none A name/value pair that represents an input or output variable of type boolean.

    or

    Name Type Required Restrictions Description
    » anonymous arrayVariable false none A name/value pair that represents an input or output variable of type array

    or

    Name Type Required Restrictions Description
    » anonymous objectVariable false none A name/value pair that represents an input or output variable of type object

    continued

    Name Type Required Restrictions Description
    version integer false none The media type's schema version number. The current version is 1.
    metadata object false none A map of name-value pairs that are used to pass metadata from the client to the server. For more information, see Using Transaction Metadata during Step Execution.
    » additionalProperties string false none none

    stepOutput

    {
      "moduleId": "string",
      "stepId": "string",
      "executionState": "string",
      "outputs": [
        {
          "name": "string",
          "value": 0
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 2,
      "metadata": {
        "property1": "string",
        "property2": "string"
      }
    }
    
    

    Step Output

    Properties
    Name Type Required Restrictions Description
    moduleId string false none The identifier of the module that contains the executed step.
    stepId string false none The name of the step that produced this output.
    executionState string false none The state of execution. Valid values are 'completed', 'submitted' and 'timedOut'.
    outputs [anyOf] false none The output values that are returned from an executed step. The order of the variables matches the order presented in the output signature.

    anyOf

    Name Type Required Restrictions Description
    » anonymous numberVariable false none A name/value pair that represents an input or output variable of type number.

    or

    Name Type Required Restrictions Description
    » anonymous stringVariable false none A name/value pair that represents an input or output variable of type String.

    or

    Name Type Required Restrictions Description
    » anonymous booleanVariable false none A name/value pair that represents an input or output variable of type boolean.

    or

    Name Type Required Restrictions Description
    » anonymous arrayVariable false none A name/value pair that represents an input or output variable of type array

    or

    Name Type Required Restrictions Description
    » anonymous objectVariable false none A name/value pair that represents an input or output variable of type object

    continued

    Name Type Required Restrictions Description
    links [link] false none The link relations for the step output.
    version integer false none The media type's schema version number. The current version is 2.
    metadata object false none A map of name-value pairs that are used to pass metadata from the server to the client.
    » additionalProperties string false none none

    stepParameter

    {
      "name": "string",
      "type": "decimal",
      "size": 0,
      "dim": 0
    }
    
    

    Step Parameter

    Properties
    Name Type Required Restrictions Description
    name string false none The name of the input or output variable.
    type string false none The data type of a variable. If the variable's type is (array of) integer, long, or decimal, the value must be a JSON (array of) number. If the variable's type is (array of) string or char, the value must be a JSON (array of) string. Only one-dimensional arrays are supported. Null is used to represent missing values. For DS2, decimal corresponds to the double data type.
    size integer false none For a string type, this field indicates the length of the string and is at least one. For non-string types, this field is ignored.
    dim integer false none For an array type, this field indicates the length of the array and is at least one. For non-array types, this field is ignored.
    Enumerated Values
    Property Value
    type decimal
    type bigint
    type integer
    type string
    type binary
    type decimalArray
    type bigintArray
    type integerArray
    type stringArray
    type binaryArray

    property

    {
      "name": "string",
      "value": "string"
    }
    
    

    Property

    Properties
    Name Type Required Restrictions Description
    name string false none Name of the property.
    value string false none Value of the property.

    numberVariable

    {
      "name": "string",
      "value": 0
    }
    
    

    NumberVariable

    Properties
    Name Type Required Restrictions Description
    name string false none Name of the variable.
    value number false none The value of the variable of type number.

    stringVariable

    {
      "name": "string",
      "value": "string",
      "encoding": "string"
    }
    
    

    StringVariable

    Properties
    Name Type Required Restrictions Description
    name string false none Name of the variable.
    value string false none The value of the variable of type string.
    encoding string false none The encoding of the variable value. It can be null or 'b64'.

    booleanVariable

    {
      "name": "string",
      "value": true
    }
    
    

    BooleanVariable

    Properties
    Name Type Required Restrictions Description
    name string false none Name of the variable.
    value boolean false none The value of the variable of type boolean.

    arrayVariable

    {
      "name": "string",
      "value": []
    }
    
    

    ArrayVariable

    Properties
    Name Type Required Restrictions Description
    name string false none Name of the variable.
    value array false none The value of the variable of type array.

    objectVariable

    {
      "name": "string",
      "value": {}
    }
    
    

    ObjectVariable

    Properties
    Name Type Required Restrictions Description
    name string false none Name of the variable.
    value object false none The value of the variable of type object.

    job

    {
      "id": "string",
      "state": "string",
      "links": [
        null
      ],
      "errors": [
        {
          "message": "string",
          "id": "string",
          "errorCode": 0,
          "httpStatusCode": 0,
          "details": [
            "string"
          ],
          "remediation": "string",
          "errors": [
            null
          ],
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ],
      "version": 1
    }
    
    

    Job

    Properties
    Name Type Required Restrictions Description
    id string false none A generated unique string that identifies a job.
    state string false none The state of the job. It can be 'pending', 'running', 'completed', 'failed', 'cancelled' or 'timedOut'.
    links [any] false none The link relations for the job.
    errors [error2] false none Optional object that is included if compiling the provided module produced errors.
    version integer false none The media type's schema version number. The current version is 1.

    moduleCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "revision": 0,
          "description": "string",
          "scope": "public",
          "language": "ds2",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "stepsIds": [
            "string"
          ],
          "properties": [
            {
              "name": "string",
              "value": "string"
            }
          ],
          "warnings": [
            {
              "message": "string",
              "id": "string",
              "errorCode": 0,
              "httpStatusCode": 0,
              "details": [
                "string"
              ],
              "remediation": "string",
              "errors": [
                null
              ],
              "links": [
                {
                  "method": "string",
                  "rel": "string",
                  "uri": "string",
                  "href": "string",
                  "title": "string",
                  "type": "string",
                  "itemType": "string",
                  "responseType": "string",
                  "responseItemType": "string"
                }
              ],
              "version": 0
            }
          ],
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 2
        }
      ]
    }
    
    

    Module Collection

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [link] false none The links that apply to the collection.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [module] true none An array that contains module resources.

    submoduleCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "moduleId": "string",
          "language": "ds2",
          "description": "string",
          "attributes": {
            "keyValue": "string"
          },
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 1
        }
      ]
    }
    
    

    Submodule Collection

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous moduleCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [submodule] true none An array that contains module resources.

    stepCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "moduleId": "string",
          "description": "string",
          "inputs": [
            {
              "name": "string",
              "type": "decimal",
              "size": 0,
              "dim": 0
            }
          ],
          "outputs": [
            {
              "name": "string",
              "type": "decimal",
              "size": 0,
              "dim": 0
            }
          ],
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 1
        }
      ]
    }
    
    

    Step Collection

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous moduleCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [step] true none An array that contains step resources.

    jobCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "state": "string",
          "links": [
            null
          ],
          "errors": [
            {
              "message": "string",
              "id": "string",
              "errorCode": 0,
              "httpStatusCode": 0,
              "details": [
                "string"
              ],
              "remediation": "string",
              "errors": [
                null
              ],
              "links": [
                {
                  "method": "string",
                  "rel": "string",
                  "uri": "string",
                  "href": "string",
                  "title": "string",
                  "type": "string",
                  "itemType": "string",
                  "responseType": "string",
                  "responseItemType": "string"
                }
              ],
              "version": 0
            }
          ],
          "version": 1
        }
      ]
    }
    
    

    Job Collection

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous moduleCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [job] true none An array that contains job resources.

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Data Mining

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Data Mining API provides resources for training, scoring, and comparing data mining models.

    Usage Notes

    Overview

    The Data Mining API provides resources for training, scoring, and comparing data mining models.

    Terminology

    project

    a collection of resources (pipelines, components, variable metadata, and so on) related to a data mining process.

    pipeline

    a collection of connected components that define a data mining process.

    component

    a unit of work in a data mining pipeline.

    model

    a formula or algorithm that computes outputs from inputs. An example is a predictive model that derives information about the conditional distribution of the target variables, given the input variables.

    analytic store (ASTORE)

    a transportable binary file that contains information about the state of an analytic object. It stores information that enables the analytic object to be loaded, restored, and set in a "score-ready" mode.

    scoring

    a process of applying the result (score code or analytic store) of a model to obtain a set of scores or predictions for the records in the table that is being scored.

    Error Codes

    HTTP Status Code Error code Description
    400 16403 The retraining table must be on the same CAS server as the original project data.
    400 16476 The page size is invalid.
    400 16540 The scoring table is not in CAS.
    400 16674 The retraining job is already running.
    400 16748 Cannot perform retraining since a pipeline in the project is currently running.
    400 16749 Cannot perform retraining since the target variable does not exist in the table selected for retraining.
    400 16894 The retraining state was not specified in the request parameters.
    400 16905 The starting page index is invalid.
    400 16910 The requested table action is not supported.
    400 31006 A required method argument is null or empty.
    400 31013 A required method argument is empty.
    404 16401 There was an error finding the table.
    404 16454 The model was not found in the project.
    404 16593 The metadata in the results could not be found.
    404 16779 No retraining job was found for the project.
    404 16780 The current retraining job is in a non-running state.
    500 16401 There was an error finding the table.
    500 16406 There was an error finding the specified caslib.
    500 16407 There was an error listing tables.
    500 16411 The URI syntax is invalid.
    500 16432 The project could not be retrieved.
    500 16450 An error occurred while listing the resources that are associated with the project.
    500 16467 The pipeline could not be retrieved.
    500 16472 A service returned an unexpected empty response.
    500 16491 There was an error creating the score execution request.
    500 16521 There was an error retrieving the CAS server information.
    500 16527 There was an error calling the results link.
    500 16531 A resource link could not be found.
    500 16535 An error occurred while updating the project.
    500 16545 User information could not be retrieved.
    500 16546 There was an error retrieving a user access token.
    500 16549 There was an error creating a CAS session.
    500 16552 There was an error retrieving table column information.
    500 16576 There was an error authenticating.
    500 16588 A query to the table service to get the attributes for a table failed.
    500 16589 There was an error retrieving a model.
    500 16597 There was an error finding the table from a URI provided by another service.
    500 16610 Unable to retrieve a service root api.
    500 16616 An error occurred while retrieving the list of project pipelines.
    500 16623 There was an error submitting the job to initiate retraining.
    500 16624 There was an error submitting a batch retraining job.
    500 16655 There was an error listing caslibs.
    500 16659 Retraining failed because components were not marked as modified.
    500 16677 Too many retraining job members were returned.
    500 16854 There was an error retrieving sessions from the CAS server.
    500 16855 There was an error finding a session in the CAS server.
    500 16906 An error occurred while updating the state of a table.
    500 16908 The table does not contain source information.
    500 16909 An error occurred while deleting the table.
    500 67003 The CAS management server link is invalid.

    Security

    Data Mining API Security Considerations

    The data mining service submits jobs as part of the data mining project life cycle.

    These jobs may be long running. In order to ensure that the job will continue to run, even if the user logs out, the data mining service bootstraps an authorization rule that allows the service to retrieve a special authorization token for the user that will not be invalidated when the user logs out.

    Operations

    Retraining

    Contains the operations for data mining project retraining.

    Perform project retrain

    Code samples

    # You can also use wget
    curl -X POST https://example.com/dataMining/projects/{projectId}/retrainJobs?dataUri=string \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/dataMining/projects/{projectId}/retrainJobs?dataUri=string',
    {
      method: 'POST',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.post('https://example.com/dataMining/projects/{projectId}/retrainJobs', params={
      'dataUri': 'string'
    }, headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/dataMining/projects/{projectId}/retrainJobs", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /projects/{projectId}/retrainJobs

    Performs project retrain by passing a data table to use for retraining. If action=batch is set in the request, this API call performs all the operations required to retrain the project including running the pipelines. If not, retraining is initiated but the pipelines are not run. The response object contains the job created for performing retraining.

    Parameters
    Name In Type Required Description
    projectId path string true The identifier of the project.
    dataUri query string true The URL of the data table.
    action query string false The retraining action.

    Example responses

    202 Response

    {
      "version": 0,
      "id": "string",
      "state": "string",
      "results": {},
      "error": {
        "message": "string",
        "id": "string",
        "errorCode": 0,
        "httpStatusCode": 0,
        "details": [
          "string"
        ],
        "remediation": "string",
        "errors": [
          null
        ],
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "version": 0
      },
      "jobRequest": {
        "version": 0,
        "id": "string",
        "name": "string",
        "description": "string",
        "creationTimeStamp": "string",
        "modifiedTimeStamp": "string",
        "createdBy": "string",
        "modifiedBy": "string",
        "jobDefinitionUri": "string",
        "jobDefinition": {},
        "expiresAfter": "string",
        "arguments": {},
        "properties": {
          "property1": "string",
          "property2": "string"
        },
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ]
      },
      "heartbeatInterval": 0,
      "heartbeatTimeStamp": "string",
      "creationTimeStamp": "string",
      "modifiedTimeStamp": "string",
      "endTimeStamp": "string",
      "expirationTimeStamp": "string",
      "createdBy": "string",
      "modifiedBy": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    202 Accepted The project retrain request has been accepted for processing, but the processing has not been completed. job
    400 Bad Request The project retrain request was invalid. error2
    Response Headers
    Status Header Type Format Description
    202 ETag string The entity tag for the retraining job.
    202 Location string The location of the retraining job.

    Set the retraining state

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/dataMining/projects/{projectId}/retrainJobs?state=needed \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json' \
      -H 'If-Match: string'
    
    
    
    const headers = {
      'Accept':'application/json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/dataMining/projects/{projectId}/retrainJobs?state=needed',
    {
      method: 'PUT',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/dataMining/projects/{projectId}/retrainJobs', params={
      'state': 'needed'
    }, headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/dataMining/projects/{projectId}/retrainJobs", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /projects/{projectId}/retrainJobs

    Sets the retraining state for the project. The retraining state can be set as needed or completed. The response object contains the job created for performing the batch retraining.

    Parameters
    Name In Type Required Description
    projectId path string true The identifier of the project.
    state query string true The state of the project retrain.
    If-Match header string false The entity tag that was returned from a GET, POST, or PUT method of the project.
    Enumerated Values
    Parameter Value
    state needed
    state completed

    Example responses

    200 Response

    {
      "containerMediaType": "string",
      "containerUri": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "dataLabel": "string",
      "dataMediaType": "string",
      "dataUri": "string",
      "description": "string",
      "id": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "lockTimeout": {
        "epochSecond": 0,
        "nano": 0
      },
      "lockedBy": "string",
      "modelImageUri": "string",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "projectStatus": "undefined",
      "projectStatusMessage": "string",
      "projectType": "string",
      "providerSpecificProperties": {
        "property1": "string",
        "property2": "string"
      },
      "readOnlySharing": true,
      "revision": 0,
      "selectedSharingGroups": [
        "string"
      ],
      "shared": true,
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. analyticsProject
    400 Bad Request The request was invalid. error2
    404 Not Found No project exists at the requested path. error2
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. error2
    428 Precondition Required The request headers did not include an If-Match precondition. error2
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the retraining state.

    Get the currently running job

    Code samples

    # You can also use wget
    curl -X GET https://example.com/dataMining/projects/{projectId}/retrainJobs/@currentJob \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/dataMining/projects/{projectId}/retrainJobs/@currentJob',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.get('https://example.com/dataMining/projects/{projectId}/retrainJobs/@currentJob', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/dataMining/projects/{projectId}/retrainJobs/@currentJob", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/retrainJobs/@currentJob

    Returns the currently running job. The response object contains the representation of the job that is currently running.

    Parameters
    Name In Type Required Description
    projectId path string true The identifier of the project.

    Example responses

    200 Response

    {
      "version": 0,
      "id": "string",
      "state": "string",
      "results": {},
      "error": {
        "message": "string",
        "id": "string",
        "errorCode": 0,
        "httpStatusCode": 0,
        "details": [
          "string"
        ],
        "remediation": "string",
        "errors": [
          null
        ],
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "version": 0
      },
      "jobRequest": {
        "version": 0,
        "id": "string",
        "name": "string",
        "description": "string",
        "creationTimeStamp": "string",
        "modifiedTimeStamp": "string",
        "createdBy": "string",
        "modifiedBy": "string",
        "jobDefinitionUri": "string",
        "jobDefinition": {},
        "expiresAfter": "string",
        "arguments": {},
        "properties": {
          "property1": "string",
          "property2": "string"
        },
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ]
      },
      "heartbeatInterval": 0,
      "heartbeatTimeStamp": "string",
      "creationTimeStamp": "string",
      "modifiedTimeStamp": "string",
      "endTimeStamp": "string",
      "expirationTimeStamp": "string",
      "createdBy": "string",
      "modifiedBy": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. job
    400 Bad Request The request was invalid. error2
    404 Not Found No currently running job exists at the requested path. error2
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the response.

    Get the champion model

    Code samples

    # You can also use wget
    curl -X GET https://example.com/dataMining/projects/{projectId}/retrainJobs/@lastJob/champion \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/dataMining/projects/{projectId}/retrainJobs/@lastJob/champion',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.get('https://example.com/dataMining/projects/{projectId}/retrainJobs/@lastJob/champion', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/dataMining/projects/{projectId}/retrainJobs/@lastJob/champion", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /projects/{projectId}/retrainJobs/@lastJob/champion

    Returns the champion model from the last retraining job. The response object contains the model.

    Parameters
    Name In Type Required Description
    projectId path string true The identifier of the project.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "string",
      "modifiedTimeStamp": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "algorithmName": "string",
      "arguments": {},
      "assessmentMap": {},
      "calculatedPipelineChampion": true,
      "champion": true,
      "contentUri": "string",
      "published": true,
      "registered": true,
      "userCreatedModel": true,
      "projectOverridingChampion": true,
      "registrationId": "string",
      "retrainingRequired": true
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. model
    400 Bad Request The request was invalid. error2
    404 Not Found No project or model exists at the requested path. error2
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the champion model.

    Models

    Contains the operations for managing data mining models.

    Score the execution request

    Code samples

    # You can also use wget
    curl -X POST https://example.com/dataMining/projects/{projectId}/models/{modelId}/scoreExecutions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/json' \
      -H 'Accept: application/vnd.sas.score.execution+json'
    
    
    const inputBody = '{
      "dataTableUri": "string",
      "outputCaslibName": "string",
      "outputTableName": "string",
      "version": 0
    }';
    const headers = {
      'Content-Type':'application/json',
      'Accept':'application/vnd.sas.score.execution+json'
    };
    
    fetch('https://example.com/dataMining/projects/{projectId}/models/{modelId}/scoreExecutions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/json',
      'Accept': 'application/vnd.sas.score.execution+json'
    }
    
    r = requests.post('https://example.com/dataMining/projects/{projectId}/models/{modelId}/scoreExecutions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/json"},
            "Accept": []string{"application/vnd.sas.score.execution+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/dataMining/projects/{projectId}/models/{modelId}/scoreExecutions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /projects/{projectId}/models/{modelId}/scoreExecutions

    Scores a model using the Score Execution Service.

    Body parameter

    {
      "dataTableUri": "string",
      "outputCaslibName": "string",
      "outputTableName": "string",
      "version": 0
    }
    
    Parameters
    Name In Type Required Description
    projectId path string true The identifier of the project.
    modelId path string true The identifier of the model.
    body body modelScoreRequest true The modelScoreRequest schema.

    Example responses

    201 Response

    {
      "id": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "scoreExecutionRequest": [
        {
          "name": "My Score Execution Request",
          "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
          "mappedCodeUri": "http://files/files/0c7281d8-063d-49dd-be6b-392e9c9e930c",
          "outputTable": "example-table",
          "hints": {
            "outputLibraryName": "PUBLIC"
          }
        }
      ],
      "state": "pending",
      "outputTable": [
        {
          "tableName": "string",
          "libraryName": "string",
          "serverName": "string"
        }
      ],
      "codeFileUri": "https://example.com",
      "logFileUri": "https://example.com",
      "haveWarnings": true,
      "error": [
        {
          "message": "string",
          "id": "string",
          "errorCode": 0,
          "httpStatusCode": 0,
          "details": [
            "string"
          ],
          "remediation": "string",
          "errors": [
            null
          ],
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ],
      "results": {
        "property1": "string",
        "property2": "string"
      },
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The score execution request was created. scoreExecution
    400 Bad Request The model score request was invalid. error2
    404 Not Found No project, model, or score table exists at the requested path. error2
    Response Headers
    Status Header Type Format Description
    201 Location string The location of the newly-created resource.
    201 ETag string The entity tag for the response.

    Schemas

    modelScoreRequest

    {
      "dataTableUri": "string",
      "outputCaslibName": "string",
      "outputTableName": "string",
      "version": 0
    }
    
    

    Model Score Request

    Properties
    Name Type Required Restrictions Description
    dataTableUri string false none The URI of the data table to score.
    outputCaslibName string false none The name of the CAS library where the output table is to be saved.
    outputTableName string false none The name of the table for storing the score output.
    version integer(int32) false none The version of the resource. This is version 1.

    analyticsProviderDetails

    {
      "providerName": "string",
      "description": "string",
      "enumerationGroups": [
        {
          "id": "string",
          "items": [
            {
              "id": "string",
              "name": "string"
            }
          ]
        }
      ],
      "productIds": [
        0
      ],
      "providedLinks": {
        "property1": {},
        "property2": {}
      },
      "providerCapabilities": {
        "property1": {},
        "property2": {}
      },
      "toolboxItems": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "type": "string",
      "version": 0
    }
    
    

    Analytics Provider Details

    Properties
    Name Type Required Restrictions Description
    providerName string false none The localized name of the provider. This is only for informational purposes.
    description string false none A brief, localized description of the provider. This is optional, and only used for informational purposes.
    enumerationGroups [enumerationGroup] false none The list of provider enumeration groups. This provides the list of valid values and localized display names for the properties of provider-specific resources. An enumeration group can be used by an Analytics Gateway client to populate a provider-specific menu, for example.
    productIds [integer] false none List of licensed product ids associated with the provider. Each id must have an existing, unexpired license in order for the provider to be made available to gateway clients.
    providedLinks object false none Map that indicates provider links that should be added to various media types.
    » additionalProperties object false none none
    providerCapabilities object false none Map that indicates the capabilities this provider supports.
    » additionalProperties object false none none
    toolboxItems [link] false none List of links to provider toolbox items. Toolbox items include provider-specific component templates, pipeline templates, and validation models.
    type string false none Localized string that describes the project type handled by the provider.
    version integer(int32) false none The API representation version.

    tableRef

    {
      "name": "string",
      "label": "string",
      "changedSinceLastRun": true,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    

    Reference to a Data Table

    Properties
    Name Type Required Restrictions Description
    name string false none A unique identifier for the table.
    label string false none The localized name of the table.
    changedSinceLastRun boolean false none true if the is an input table to a project and has changed since the last time it was processed by this project. null if the table changed status of the table is unknown or this TableRef is output table of an AnalyticsComponent.
    links [link] false none The links that apply to the policy.
    version integer(int32) false none The version number of this representation schema.

    tableGroup

    {
      "id": "string",
      "name": "string",
      "tableRefs": [
        {
          "name": "string",
          "label": "string",
          "changedSinceLastRun": true,
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    

    Table Group

    Properties
    Name Type Required Restrictions Description
    id string false none A unique identifier for the group.
    name string false none The group name.
    tableRefs [tableRef] false none The members of this group
    links [link] false none The links that apply to the group.
    version integer(int32) false none The version number of this representation schema.

    api

    {
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    API

    Properties
    Name Type Required Restrictions Description
    version integer true none The version number of the API representation. This is version 1.
    links [link] true none The API's top-level links.

    attributes

    {
      "version": 1,
      "description": "string",
      "label": "string",
      "attributes": {},
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Attributes

    Properties
    Name Type Required Restrictions Description
    version integer true none The version number of the API representation. This is version 1.
    description string false none A description of the set of attributes.
    label string false none A brief description or label for the set of attributes.
    attributes object true none The map of attribute names to values. The set of names is open, though individual services may define a closed set needed for a given resource in that service. The value of each attribute may be of types: number, string, boolean, array, or object. Although property this is required, the mapping object can be empty, unless stated otherwise by specific documentation for resources where the application/vnd.sas.attributes type is used.
    links [link] true none Links to associated resources and operations. APIs may provide links for the link relations self',update(to replace the attributes),patch` (to update some attributes) or others.

    pipeline

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "systemAttributes": {},
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "revision": 0,
      "componentType": "application/vnd.sas.summary",
      "swimLanes": [
        {
          "name": "string",
          "orderConstraints": [
            {
              "predecessor": "string",
              "successor": "string"
            }
          ],
          "orderedComponentIds": [
            "string"
          ],
          "components": {
            "property1": {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "id": "string",
              "name": "string",
              "description": "string",
              "group": "string",
              "classification": "string",
              "state": "undefined",
              "iconCode": "string",
              "imageUri": "string",
              "links": [
                {
                  "method": "string",
                  "rel": "string",
                  "uri": "string",
                  "href": "string",
                  "title": "string",
                  "type": "string",
                  "itemType": "string",
                  "responseType": "string",
                  "responseItemType": "string"
                }
              ],
              "version": 0
            },
            "property2": {
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "id": "string",
              "name": "string",
              "description": "string",
              "group": "string",
              "classification": "string",
              "state": "undefined",
              "iconCode": "string",
              "imageUri": "string",
              "links": [
                {
                  "method": "string",
                  "rel": "string",
                  "uri": "string",
                  "href": "string",
                  "title": "string",
                  "type": "string",
                  "itemType": "string",
                  "responseType": "string",
                  "responseItemType": "string"
                }
              ],
              "version": 0
            }
          }
        }
      ],
      "connections": {
        "property1": {
          "id": "string",
          "from": "string",
          "to": "string"
        },
        "property2": {
          "id": "string",
          "from": "string",
          "to": "string"
        }
      },
      "annotation": "string"
    }
    
    

    Pipeline

    Properties
    Name Type Required Restrictions Description
    Pipeline any false none A process flow for analytic components. Pipelines group individual components into a higher-level workflow

    allOf

    Name Type Required Restrictions Description
    anonymous pipelineSummary false none A summary of a pipeline representation

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » revision integer(int64) false none A revision number that is incremented on every update to the pipeline.
    » componentType string false none Media type for pipeline components.
    » swimLanes [any] false none The pipeline's swim lanes, ordered as they are defined in the pipeline policy. A swim lane is a container for components with the same policy constraints.
    »» name string false none A unique, descriptive identifier for the swim lane.
    »» orderConstraints [any] false none Display order constraints for components in a swim lane. Each predecessor/successor pair is a hint for the preferred display order for components. These constraints do not affect execution order.
    »»» predecessor string false none The id of the predecessor component. For added components, this is a placeholder id.
    »»» successor string false none The id of the successor component. For added components, this is a placeholder id.
    »» orderedComponentIds [string] false none Ids for each component in the swim lane in display order. The defined connections and display order contraints contribute to this ordering.
    »» components object false none The swim lane's components, indexed by id.
    »»» additionalProperties analyticsComponentSummary false none A summary of an analytics component representation. It omits revision, code, executionProviderId, componentProperties, systemAttributes, and validationModel
    » connections object false none The pipeline's component connections, indexed by connection id. Connections add sequential execution constraints to pairs of components.
    »» additionalProperties pipelineComponentConnection false none A representation of a connection between two pipeline components. Connected components are executed sequentially.
    » version integer(int32) false none The version number of this representation schema. This representation is version 3.
    » annotation string false none A user specified annotation for the pipeline.
    Enumerated Values
    Property Value
    componentType application/vnd.sas.summary
    componentType application/vnd.sas.analytics.component.summary
    componentType application/vnd.sas.analytics.component

    projectSettings

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "name": "string",
      "description": "string",
      "revision": 0,
      "assessmentSettings": {
        "numberOfRocBins": "10",
        "version": 0
      },
      "advisorSettings": {
        "applyMaxPercentMissing": true,
        "intervalCutoff": 0,
        "maxClassLevels": 0,
        "maxPercentMissing": 0,
        "globalMetadataEnabled": true,
        "version": 0
      },
      "compareSettings": {
        "classStatistic": "ks",
        "cutoff": "5",
        "intervalStatistic": "ase",
        "selectionDepth": "5",
        "selectionTable": "default",
        "version": 0
      },
      "cutoffSettings": {
        "classificationCutoffEnabled": true,
        "classificationCutoffValue": 0,
        "version": 0
      },
      "foldingSettings": {
        "enableFolding": true,
        "enableManualFoldingSelection": true,
        "numberOfFolds": 0,
        "eventProportion": 0,
        "nonEventProportion": 0,
        "version": 0
      },
      "jobLoggingSettings": {
        "detailsEnabled": true,
        "infoEnabled": true,
        "mPrintEnabled": true,
        "symbolGenEnabled": true,
        "version": 0
      },
      "partitionSettings": {
        "partitionEnabled": true,
        "partitionMethod": "simpleRandom",
        "test": 0,
        "train": 0,
        "valid": 0,
        "version": 0
      },
      "projectId": "string",
      "saveDataUri": "string",
      "samplingSettings": {
        "samplingEnabled": true,
        "samplingPercentage": 0,
        "version": 0
      },
      "pythonConfigurationCodeSettings": {
        "pythonConfigurationCodeEnabled": true,
        "pythonConfigurationCode": "string",
        "version": 0
      },
      "version": 0
    }
    
    

    Project Settings

    Properties
    Name Type Required Restrictions Description
    Project Settings any false none Settings for data mining projects.

    allOf

    Name Type Required Restrictions Description
    anonymous revisionTrackingResource false none A TrackedResource subclass which contains additional information for HATEOAS and persistence.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » assessmentSettings assessmentSettings false none Assessment configuration settings for modeling nodes in a project.
    » advisorSettings advisorSettings false none A collection of advanced settings that are passed to the advisor job during project creation.
    » compareSettings compareSettings false none The parameters that control the comparison of models.
    » cutoffSettings classificationCutoffSettings false none The classification cutoff settings to be used when running a data mining component.
    » foldingSettings foldingSettings false none Settings for configuring k-fold partitioning for modeling nodes in a project.
    » jobLoggingSettings jobLoggingSettings false none The logging and debug settings for the SAS code run during data mining operations.
    » partitionSettings partitionSettings false none Settings that indicate how and if a data mining project source data will be partitioned.
    » projectId string false none ID of the project to which the settings belong
    » saveDataUri string false none The Caslib URI where a data mining project's save data nodes will save data
    » samplingSettings samplingSettings false none The sampling settings to be used when creating the partition table for a data mining project.
    » pythonConfigurationCodeSettings pythonConfigurationCodeSettings false none Settings for enabling and defining configuration Python pre-code for open source Python components in a project.
    » version integer(int32) false none Version of the resource.

    model

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "string",
      "modifiedTimeStamp": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "algorithmName": "string",
      "arguments": {},
      "assessmentMap": {},
      "calculatedPipelineChampion": true,
      "champion": true,
      "contentUri": "string",
      "published": true,
      "registered": true,
      "userCreatedModel": true,
      "projectOverridingChampion": true,
      "registrationId": "string",
      "retrainingRequired": true
    }
    
    

    Model

    Properties
    Name Type Required Restrictions Description
    id string false none The unique model identifier
    name string false none The model name
    description string false none The model description
    createdBy string false none The user who created this model
    modifiedBy string false none The user who modified this model
    creationTimeStamp string false none The formatted time stamp when the model was created, in yyyy-mm-ddThh:mm:ssZ format
    modifiedTimeStamp string false none The formatted time stamp when the model was modified, in yyyy-mm-ddThh:mm:ssZ format
    version integer(int32) false none Version of the resource
    links [link] false none [A link to a related operation or resource.]
    algorithmName string false none The localized model algorithm name, for example regression or model tree
    arguments object false none Holds compare arguments for the model
    assessmentMap object false none Holds assessment criteria for the model mapped by partition with partition name as the key. Each value holds a Map of String key value pairs representing the statistic name and its value.
    calculatedPipelineChampion boolean false none True if a user has explicitly created this model or declared it an adhoc champion. False if the model was created through the model compare component for a calculated pipeline champion.
    champion boolean false none True if this model is the champion of models returned as part of a collection.
    contentUri string false none Used to locate the content generated by the server tier
    published boolean false none True if the model has been published using the model manager publishing service, if ignored default to false
    registered boolean false none True if the model is registered with model manager, if ignored default to false
    userCreatedModel boolean false none True if a user has explicitly created this model or declared it an adhoc champion. False if the model was created through the model compare component for a calculated pipeline champion.
    projectOverridingChampion boolean false none True if the user has designated that this model overrides all other champions for a project.
    registrationId string false none The registration id associated with the Common Model Repository.
    retrainingRequired boolean false none True if the model manager has flagged this model as requiring retraining, if ignored default to false

    {
      "method": "string",
      "rel": "string",
      "uri": "string",
      "href": "string",
      "title": "string",
      "type": "string",
      "itemType": "string",
      "responseType": "string",
      "responseItemType": "string"
    }
    
    

    Link

    Properties
    Name Type Required Restrictions Description
    method string false none The HTTP method for the link.
    rel string true none The relationship of the link to the resource.
    uri string false none The relative URI for the link.
    href string false none The URL for the link.
    title string false none The title for the link.
    type string false none The media type or link type for the link.
    itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.

    pipelineTemplate

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 0,
      "id": "string",
      "name": "string",
      "description": "string",
      "application": "string",
      "provider": "string",
      "systemAttributes": {},
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "revision": 0,
      "prototype": {
        "createdBy": "string",
        "modifiedBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "id": "string",
        "name": "string",
        "description": "string",
        "systemAttributes": {},
        "version": 0,
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "revision": 0,
        "componentType": "application/vnd.sas.summary",
        "swimLanes": [
          {
            "name": "string",
            "orderConstraints": [
              {
                "predecessor": "string",
                "successor": "string"
              }
            ],
            "orderedComponentIds": [
              "string"
            ],
            "components": {
              "property1": {
                "createdBy": "string",
                "modifiedBy": "string",
                "creationTimeStamp": "2019-08-24T14:15:22Z",
                "modifiedTimeStamp": "2019-08-24T14:15:22Z",
                "id": "string",
                "name": "string",
                "description": "string",
                "group": "string",
                "classification": "string",
                "state": "undefined",
                "iconCode": "string",
                "imageUri": "string",
                "links": [
                  {
                    "method": "string",
                    "rel": "string",
                    "uri": "string",
                    "href": "string",
                    "title": "string",
                    "type": "string",
                    "itemType": "string",
                    "responseType": "string",
                    "responseItemType": "string"
                  }
                ],
                "version": 0
              },
              "property2": {
                "createdBy": "string",
                "modifiedBy": "string",
                "creationTimeStamp": "2019-08-24T14:15:22Z",
                "modifiedTimeStamp": "2019-08-24T14:15:22Z",
                "id": "string",
                "name": "string",
                "description": "string",
                "group": "string",
                "classification": "string",
                "state": "undefined",
                "iconCode": "string",
                "imageUri": "string",
                "links": [
                  {
                    "method": "string",
                    "rel": "string",
                    "uri": "string",
                    "href": "string",
                    "title": "string",
                    "type": "string",
                    "itemType": "string",
                    "responseType": "string",
                    "responseItemType": "string"
                  }
                ],
                "version": 0
              }
            }
          }
        ],
        "connections": {
          "property1": {
            "id": "string",
            "from": "string",
            "to": "string"
          },
          "property2": {
            "id": "string",
            "from": "string",
            "to": "string"
          }
        },
        "annotation": "string"
      },
      "hidden": false
    }
    
    

    Pipeline Template

    Properties
    Name Type Required Restrictions Description
    Pipeline Template any false none A template from which new pipelines can be generated.

    allOf

    Name Type Required Restrictions Description
    anonymous pipelineTemplateSummary false none A summary representation of a pipeline template.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » revision integer(int64) false none A revision number that is incremented on every update to the template.
    » prototype pipeline false none A process flow for analytic components. Pipelines group individual components into a higher-level workflow
    » version integer(int32) false none The version number of this representation schema. This representation is version 3.
    » hidden boolean false none A flag indicating whether this template is visible in user interfaces. When true, the template should not be visible.

    analyticsProject

    {
      "containerMediaType": "string",
      "containerUri": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "dataLabel": "string",
      "dataMediaType": "string",
      "dataUri": "string",
      "description": "string",
      "id": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "lockTimeout": {
        "epochSecond": 0,
        "nano": 0
      },
      "lockedBy": "string",
      "modelImageUri": "string",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "name": "string",
      "projectStatus": "undefined",
      "projectStatusMessage": "string",
      "projectType": "string",
      "providerSpecificProperties": {
        "property1": "string",
        "property2": "string"
      },
      "readOnlySharing": true,
      "revision": 0,
      "selectedSharingGroups": [
        "string"
      ],
      "shared": true,
      "version": 0
    }
    
    

    Analytics Project

    Properties
    Name Type Required Restrictions Description
    containerMediaType string false none The media type of the project's parent container
    containerUri string false none The uri of the project's parent container
    createdBy string false none The userid who created this resource.
    creationTimeStamp string(date-time) false none The timestamp when this resource was created.
    dataLabel string false none Label associated with the data table
    dataMediaType string false none The media type of the resource
    dataUri string false none The uri to the CAS table that contains the data
    description string false none A description of this resource
    id string false none A unique identifier for this resource
    links [link] false none Links that apply to this resource
    lockTimeout instant false none An instantaneous point on the time-line.
    lockedBy string false none The user who holds the lock, if it has not expired. Only this user has write access to the project.
    modelImageUri string false none The uri of the project's image
    modifiedBy string false none The timestamp when this resource was last modified.
    modifiedTimeStamp string(date-time) false none The userid who last modified this resource.
    name string false none The name of the project
    projectStatus string false none The project status
    projectStatusMessage string false none Additional message to explain the project status
    projectType string false none The project type. Corresponds to a provider id
    providerSpecificProperties object false none A map to hold provider specific project information
    » additionalProperties string false none none
    readOnlySharing boolean false none Last selected mode of sharing. If true, and shared is true, then project is shared in read-only mode. Ignored if not shared.
    revision integer(int64) false none revision of this resource
    selectedSharingGroups [string] false none List of groups last selected for project sharing. Never cleared on unshare.
    shared boolean false none Flag indicating if project is currently being shared. If true, project is shared with selectedSharingGroups, which cannot be empty.
    version integer(int32) false none The version number of this representation schema.
    Enumerated Values
    Property Value
    projectStatus undefined
    projectStatus noProvider
    projectStatus creating
    projectStatus creatingProviderNotCalled
    projectStatus creatingProviderError
    projectStatus updatingProviderError
    projectStatus ready
    projectStatus deleting

    job

    {
      "version": 0,
      "id": "string",
      "state": "string",
      "results": {},
      "error": {
        "message": "string",
        "id": "string",
        "errorCode": 0,
        "httpStatusCode": 0,
        "details": [
          "string"
        ],
        "remediation": "string",
        "errors": [
          null
        ],
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "version": 0
      },
      "jobRequest": {
        "version": 0,
        "id": "string",
        "name": "string",
        "description": "string",
        "creationTimeStamp": "string",
        "modifiedTimeStamp": "string",
        "createdBy": "string",
        "modifiedBy": "string",
        "jobDefinitionUri": "string",
        "jobDefinition": {},
        "expiresAfter": "string",
        "arguments": {},
        "properties": {
          "property1": "string",
          "property2": "string"
        },
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ]
      },
      "heartbeatInterval": 0,
      "heartbeatTimeStamp": "string",
      "creationTimeStamp": "string",
      "modifiedTimeStamp": "string",
      "endTimeStamp": "string",
      "expirationTimeStamp": "string",
      "createdBy": "string",
      "modifiedBy": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Job

    Properties
    Name Type Required Restrictions Description
    version number false none The version number of the representation. The current version is 2.
    id string true none The unique identifier that is generated by the API.
    state string false none The current state of the job. Valid values: pending, running, canceled, completed, failed, timedOut
    results object false none The output results of the job execution (map of String, String).
    error error2 false none The representation of an error.
    jobRequest request false none The job request.
    heartbeatInterval integer(int32) false none The interval in seconds that the heartbeatTimeStamp should be updated by the provider or the job times out. The value for the heatbeatInterval is 0 when there is no heartbeat.
    heartbeatTimeStamp string false none The timestamp for when the last heartbeat was received, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    creationTimeStamp string false none The timestamp for when the job was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string false none The timestamp for when the job was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    endTimeStamp string false none The timestamp for when the state of the job changed to completed or failed, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    expirationTimeStamp string false none The timestamp for when the job expires and will be deleted by the Job Execution service, in the format of YYYY-MM-DDThh:mm:ss.sssZ. This is set by the service after the job has completed based on the value of the expiresAfter member of the job request.
    createdBy string false none The ID of the user that created or submitted the job.
    modifiedBy string false none The ID of the user that last modified the job.
    links [link] false none The links that are associated with the job.

    report

    {
      "id": "string",
      "data": [
        {
          "dataMap": {},
          "header": "string",
          "rowNumber": 0
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "parameterMap": {
        "property1": {
          "label": "string",
          "length": 0,
          "order": 0,
          "parameter": "string",
          "preformatted": true,
          "type": "undefined",
          "values": [
            "string"
          ]
        },
        "property2": {
          "label": "string",
          "length": 0,
          "order": 0,
          "parameter": "string",
          "preformatted": true,
          "type": "undefined",
          "values": [
            "string"
          ]
        }
      },
      "order": 0,
      "type": "undefined",
      "xInteger": true,
      "yInteger": true,
      "version": 0,
      "description": "string",
      "revision": 0
    }
    
    

    Analytics Report

    Properties
    Name Type Required Restrictions Description
    id string false none The unique identifier of this analytics report.
    data [dataRow] true none The rows of data.
    links [link] false none [A link to a related operation or resource.]
    parameterMap object true none The collection of parameters, categorized by parameter name.
    » additionalProperties parameter false none Metadata describing a particular variable.
    order integer(int32) false none The index in a collection of analytics reports. Useful when analytics reports are stored in an unordered collection but order is desired.
    type string true none The type of analytics report. Informs clients how this analytics report should be rendered.
    xInteger boolean false none Whether or not to suppress intermediate tick marks on the X-axis.
    yInteger boolean false none Whether or not to suppress intermediate tick marks on the Y-axis.
    version integer(int32) false none This media type's schema version number. This representation is version 1.
    description string false none A description of this analytics report.
    revision integer(int64) false none A revision number that is incremented on every update to the analytics report.
    Enumerated Values
    Property Value
    type undefined
    type table
    type barChart
    type refreshableBarChart
    type seriesPlot
    type pieChart
    type histogram
    type decisionTree
    type networkDiagram
    type html
    type textViewer
    type matrix
    type bandPlot
    type codeEditor
    type iciclePlot
    type scatterPlot
    type comboBox

    baseCollection2

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    

    Base Collection

    Properties
    Name Type Required Restrictions Description
    name string false none The name of the collection.
    start integer(int64) false none The zero-based index of the first item in the collection.
    limit integer false none The number of items that were requested for the collection.
    count integer(int64) false none If populated indicates the number of items in the collection.
    accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    links [link] false none The links that apply to the collection.
    version integer false none The version number of the collection representation. This representation is version 2.

    analyticsComponent

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "group": "string",
      "classification": "string",
      "state": "undefined",
      "iconCode": "string",
      "imageUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "revision": 0,
      "code": "string",
      "executionProviderId": "string",
      "componentProperties": {},
      "systemAttributes": {},
      "validationModel": {
        "createdBy": "string",
        "modifiedBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "id": "string",
        "name": "string",
        "description": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ],
        "version": 0,
        "revision": 0,
        "items": [
          {
            "itemType": "group",
            "id": "string",
            "name": "string",
            "displayName": "string",
            "description": "string",
            "array": true,
            "clientProperties": [
              {
                "name": "string",
                "value": "string"
              }
            ],
            "enabledWhen": "string",
            "enabledWhenValue": true
          }
        ]
      }
    }
    
    

    Analytics Component

    Properties
    Name Type Required Restrictions Description
    Analytics Component any false none An analytics component.

    allOf

    Name Type Required Restrictions Description
    anonymous analyticsComponentSummary false none A summary of an analytics component representation. It omits revision, code, executionProviderId, componentProperties, systemAttributes, and validationModel

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » revision integer(int64) false none A revision number that is incremented on every update to the component.
    » code string false none The code to execute when running the component.
    » executionProviderId string false none The job execution provider that runs the component's codeTemplate.
    » componentProperties object false none User defined properties that control component execution.
    » systemAttributes object false none Additional properties, not visible to the user, that control component execution.
    » validationModel validationModel false none The validation rules applied to a map of properties.

    scoreExecution

    {
      "id": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "scoreExecutionRequest": [
        {
          "name": "My Score Execution Request",
          "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
          "mappedCodeUri": "http://files/files/0c7281d8-063d-49dd-be6b-392e9c9e930c",
          "outputTable": "example-table",
          "hints": {
            "outputLibraryName": "PUBLIC"
          }
        }
      ],
      "state": "pending",
      "outputTable": [
        {
          "tableName": "string",
          "libraryName": "string",
          "serverName": "string"
        }
      ],
      "codeFileUri": "https://example.com",
      "logFileUri": "https://example.com",
      "haveWarnings": true,
      "error": [
        {
          "message": "string",
          "id": "string",
          "errorCode": 0,
          "httpStatusCode": 0,
          "details": [
            "string"
          ],
          "remediation": "string",
          "errors": [
            null
          ],
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ],
      "results": {
        "property1": "string",
        "property2": "string"
      },
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    

    Score Execution

    Properties
    Name Type Required Restrictions Description
    id string false none The system-assigned unique ID for this object
    createdBy string false none The user who created the score execution.
    creationTimeStamp string(date-time) false none The date and time that the score execution was created.
    modifiedBy string false none The userId of the authenticated user who last updated the score execution.
    modifiedTimeStamp string(date-time) false none The date and time that the score execution was last modified.
    scoreExecutionRequest array true none Contains request details about how to generate score.
    state string(enumeration) true none State of the score execution.
    outputTable array false none Details of the output generated by score execution.
    codeFileUri string(uri) false none File uri where the code used to generate score is saved.
    logFileUri string(uri) false none File uri where the log of the score execution is saved.
    haveWarnings boolean false none Set to true when there are warnings inside the log file.
    error array false none Contains error details if the execution is failed.
    results object false none Contains results for the score execution.
    » additionalProperties string false none none
    links [link] false none Zero or more links to related resources or operations.
    version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    state pending
    state running
    state canceled
    state completed
    state failed
    state timedOut

    fileResource

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "parentUri": "string",
      "properties": {
        "property1": "string",
        "property2": "string"
      },
      "contentDisposition": "string",
      "contentType": "string",
      "description": "string",
      "documentType": "string",
      "encoding": "string",
      "id": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "name": "string",
      "size": 0
    }
    
    

    File Resource

    Properties
    Name Type Required Restrictions Description
    File Resource any false none An object representing a file

    allOf

    Name Type Required Restrictions Description
    anonymous trackedResource false none This class is used to provide common attributes and behaviors around tracking who and when objects were created and modified to representation objects.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » parentUri string false none URI of the object which is either associated or linked with file resource
    » properties object false none Properties specific to this file. Each property uses a "key" : "value" format and a comma is used as the separator between properties.
    »» additionalProperties string false none none
    » contentDisposition string false none Value for Content Disposition header which will be set in response while downloading the file
    » contentType string false none Type of the content
    » description string false none Description of the document
    » documentType string false none Type of the document
    » encoding string false none Encoding of the document
    » id string false none Id of the file resource
    » links [link] false none Links that apply to this object. Includes "self", "content", "patch", "update" and "delete"
    » name string false none Name of the document
    » size integer false none Byte size of the document content

    dataTable

    {
      "providerId": "string",
      "dataSourceId": "string",
      "name": "string",
      "label": "string",
      "type": "string",
      "createdBy": "string",
      "modifiedBy": "string",
      "attributes": {},
      "creationTimeStamp": "string",
      "modifiedTimeStamp": "string",
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Table

    Properties
    Name Type Required Restrictions Description
    providerId string false none The table provider name.
    dataSourceId string false none The parent source name.
    name string false none The unique name of the table.
    label string false none The user visible name of this table. This value might vary depending on the Accept-Language header.
    type string false none The type of this table.
    createdBy string false none userid of the user who created/submitted the job
    modifiedBy string false none userid of the user who last modified the job
    attributes object false none Additional provider specific attributes.
    creationTimeStamp string false none creation date (date job was submitted), in yyyy-MM-ddTHH:mm:ss.SSSZ format.
    modifiedTimeStamp string false none date of last modification, in yyyy-MM-ddTHH:mm:ss.SSSZ format.
    version integer false none The table schema version.
    links [link] false none zero or more link objects

    error2

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    

    Error

    Properties
    Name Type Required Restrictions Description
    message string false none The message for the error.
    id string false none The string ID for the error.
    errorCode integer false none The numeric ID for the error.
    httpStatusCode integer true none The HTTP status code for the error.
    details [string] false none Messages that provide additional details about the cause of the error.
    remediation string false none A message that describes how to resolve the error.
    errors [error2] false none Any additional errors that occurred.
    links [link] false none The links that apply to the error.
    version integer true none The version number of the error representation. This representation is version 2.

    validationModel

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "revision": 0,
      "items": [
        {
          "itemType": "group",
          "id": "string",
          "name": "string",
          "displayName": "string",
          "description": "string",
          "array": true,
          "clientProperties": [
            {
              "name": "string",
              "value": "string"
            }
          ],
          "enabledWhen": "string",
          "enabledWhenValue": true
        }
      ]
    }
    
    

    Validation Model

    Properties
    Name Type Required Restrictions Description
    Validation Model any false none The validation rules applied to a map of properties.

    allOf

    Name Type Required Restrictions Description
    anonymous validationModelSummary false none A summary of a validation model representation.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » revision integer(int64) false none A revision number that is incremented on every update to the model.
    » id string false none A unique identifier for the model.
    » name string false none The model name.
    » description string false none The model description.
    » items [validationItem] false none The top-level validation groups and properties
    » version integer(int32) false none The version number of this representation schema.

    enumerationGroup

    {
      "id": "string",
      "items": [
        {
          "id": "string",
          "name": "string"
        }
      ]
    }
    
    

    Enumeration Group

    Properties
    Name Type Required Restrictions Description
    id string false none The group id.
    items [enumerationGroupItem] false none The enumeration group items defined for this group.

    pipelineComponentConnection

    {
      "id": "string",
      "from": "string",
      "to": "string"
    }
    
    

    Pipeline Component Connection

    Properties
    Name Type Required Restrictions Description
    id string false none A unique identifier for the connection.
    from string false none The id of the connection source component. This component must complete execution before the target component can execute.
    to string false none The id of the connection target component. This component can begin execution only after the source component completes.

    samplingSettings

    {
      "samplingEnabled": true,
      "samplingPercentage": 0,
      "version": 0
    }
    
    

    Sampling Settings

    Properties
    Name Type Required Restrictions Description
    samplingEnabled boolean false none The sampling enabled flag.
    samplingPercentage number(double) false none The sampling percentage value.
    version integer(int32) false none Version of the resource.

    pipelineTemplateSummary

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "version": 0,
      "id": "string",
      "name": "string",
      "description": "string",
      "application": "string",
      "provider": "string",
      "systemAttributes": {},
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Pipeline Template Summary

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user who created the template.
    modifiedBy string false none The user who most recently modified the template.
    creationTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the template was created.
    modifiedTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the template was last modified.
    version integer(int32) false none The version number of the template representation. This representation is version 2.
    id string false none A unique identifier for the template.
    name string false none The template name.
    description string false none The template description.
    application string false none The name of the application in which the template is used.
    provider string false none The name of the organization providing the template. For SAS-provided templates, the value is 'SAS'.
    systemAttributes object false none Client-defined attributes used to control pipeline update and execution.
    links [link] false none The links that apply to the template.

    advisorSettings

    {
      "applyMaxPercentMissing": true,
      "intervalCutoff": 0,
      "maxClassLevels": 0,
      "maxPercentMissing": 0,
      "globalMetadataEnabled": true,
      "version": 0
    }
    
    

    Advisor Settings

    Properties
    Name Type Required Restrictions Description
    applyMaxPercentMissing boolean false none Whether to reject variables based on a specified percentage of missing values.
    intervalCutoff integer(int32) false none The number of cutoff levels before a numeric variable is marked as a class variable.
    maxClassLevels integer(int32) false none The maximum number of class levels before a class variable is set to REJECTED.
    maxPercentMissing integer(int32) false none The maximum percentage of missing values before a variable is set to REJECTED.
    globalMetadataEnabled boolean false none Whether to enable global metadata for the project.
    version integer(int32) false none Version of the resource.

    pipelineSummary

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "systemAttributes": {},
      "version": 0,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Pipeline Summary

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user who created the pipeline.
    modifiedBy string false none The user who most recently modified the pipeline.
    creationTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the pipeline was created.
    modifiedTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the pipeline was last modified.
    id string false none A unique identifier for the pipeline.
    name string false none The pipeline name.
    description string false none The pipeline description.
    systemAttributes object false none Client-defined attributes used to control pipeline update and execution.
    version integer(int32) false none The version number of the pipeline representation. This representation is version 2.
    links [link] false none The links that apply to the pipeline.

    partitionSettings

    {
      "partitionEnabled": true,
      "partitionMethod": "simpleRandom",
      "test": 0,
      "train": 0,
      "valid": 0,
      "version": 0
    }
    
    

    Partition Settings

    Properties
    Name Type Required Restrictions Description
    partitionEnabled boolean false none The flag that indicates if the project source data will be partitioned. If the flag is true, the source data will be partitioned according to the partition method specified. If false, the source data will not be partitioned and the entire table will be considered training data.
    partitionMethod string false none The method by which the project source data will be partitioned.
    test integer(int32) false none The ratio value that indicates how much of the source table should be considered test data.
    train integer(int32) false none The ratio value that indicates how much of the source table should be considered training data.
    valid integer(int32) false none The ratio value that indicates how much of the source table should be considered validation data.
    version integer(int32) false none Version of the resource.
    Enumerated Values
    Property Value
    partitionMethod simpleRandom
    partitionMethod stratify

    analyticsComponentSummary

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "group": "string",
      "classification": "string",
      "state": "undefined",
      "iconCode": "string",
      "imageUri": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    

    Analytics Component Summary

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user who created the component.
    modifiedBy string false none The user who most recently modified the component.
    creationTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the component was created.
    modifiedTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the component was last modified.
    id string false none A unique identifier for the component.
    name string false none The component name.
    description string false none The component description.
    group string false none The component group name. Similar components can be grouped together by assigning the same group name to each.
    classification string false none An application-defined component classification.
    state string false none The current execution state of the component.
    iconCode string false none An application-defined value that identifies a visual representation of the component type.
    imageUri string false none A application-defined URI used to retrieve a visual representation of the component state.
    links [link] false none [A link to a related operation or resource.]
    version integer(int32) false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    state undefined
    state created
    state modified
    state pending
    state waiting
    state running
    state completed
    state canceled
    state paused
    state deleted
    state failed

    dataRow

    {
      "dataMap": {},
      "header": "string",
      "rowNumber": 0
    }
    
    

    Data Row

    Properties
    Name Type Required Restrictions Description
    dataMap object true none Map of parameter name to associated value.
    header string false none Optional title. May be localized.
    rowNumber integer(int32) true none The index of this row in the collection.

    revisionTrackingResource

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "name": "string",
      "description": "string",
      "revision": 0
    }
    
    

    Revision Tracking Resource

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous trackedResource false none This class is used to provide common attributes and behaviors around tracking who and when objects were created and modified to representation objects.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » id string false none Primary identifier of the resource in the underlying data store. This field should never be modified by a client application.
    » links [link] false none HATEOAS links related to this resource. Actions that are possible on this resource or related resources are represented by entries in this list.
    » name string false none The name of this resource.
    » description string false none The description of this resource.
    » revision integer(int64) false none The version identifier used for optimistic locking. Each time the resource is modified in the data store, this revision number is updated.

    request

    {
      "version": 0,
      "id": "string",
      "name": "string",
      "description": "string",
      "creationTimeStamp": "string",
      "modifiedTimeStamp": "string",
      "createdBy": "string",
      "modifiedBy": "string",
      "jobDefinitionUri": "string",
      "jobDefinition": {},
      "expiresAfter": "string",
      "arguments": {},
      "properties": {
        "property1": "string",
        "property2": "string"
      },
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Job Request

    Properties
    Name Type Required Restrictions Description
    version integer false none The version number of the representation. The current version is 2.
    id string true none The unique identifier for the job.
    name string false none The name of the job.
    description string false none The description of the job.
    creationTimeStamp string false none The timestamp for when the job was created, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    modifiedTimeStamp string false none The timestamp for when the job was last modified, in the format of YYYY-MM-DDThh:mm:ss.sssZ.
    createdBy string false none The ID of the user that created or submitted the job.
    modifiedBy string false none The ID of the user that last modified the job.
    jobDefinitionUri string false none The URI of the job definition that is to be executed.
    jobDefinition object false none The definition of the job that is to be executed.
    expiresAfter string false none The duration of time (in W3C XML duration format) after the completion of the job when the job should be deleted by the Job Execution service.
    arguments object false none The values of the arguments described in the job definition.
    properties object false none The value of properties in the format of (map) that contains name value pairs (map). The maximum name value length is 100.
    » additionalProperties string false none none
    links [link] false none The links that are associated with the job.

    outputTable

    {
      "tableName": "string",
      "libraryName": "string",
      "serverName": "string"
    }
    
    

    Output Table

    Properties
    Name Type Required Restrictions Description
    tableName string true none Table name where the score execution or analysis output is saved.
    libraryName string true none Library where the table is located.
    serverName string true none Server where the table is located.

    assessmentSettings

    {
      "numberOfRocBins": "10",
      "version": 0
    }
    
    

    Assessment Settings

    Properties
    Name Type Required Restrictions Description
    numberOfRocBins string false none The number of ROC bins to use for modeling node assessment.
    version integer(int32) false none Version of the resource.
    Enumerated Values
    Property Value
    numberOfRocBins 10
    numberOfRocBins 20
    numberOfRocBins 50
    numberOfRocBins 100
    numberOfRocBins 500
    numberOfRocBins 1000

    instant

    {
      "epochSecond": 0,
      "nano": 0
    }
    
    

    Instant

    Properties
    Name Type Required Restrictions Description
    epochSecond integer(int64) false none The number of seconds from the epoch of 1970-01-01T00:00:00Z.
    nano integer(int32) false none The number of nanoseconds, later along the time-line, from the seconds field. This is always positive, and never exceeds 999,999,999.

    jobLoggingSettings

    {
      "detailsEnabled": true,
      "infoEnabled": true,
      "mPrintEnabled": true,
      "symbolGenEnabled": true,
      "version": 0
    }
    
    

    Job Logging Settings

    Properties
    Name Type Required Restrictions Description
    detailsEnabled boolean false none Enable the retention of temporary CAS tables created during the data mining process. If true, sets \'%let DM_Debug=DETAILS\' If both infoEnabled and detailsEnabled are true, sets \'%let DM_DEBUG=INFO DETAILS\'
    infoEnabled boolean false none Enable generation of timings and headers for SAS code run during the data mining process. If true, sets \'%let DM_DEBUG=INFO\' If both infoEnabled and detailsEnabled are true, sets \'%let DM_DEBUG=INFO DETAILS\'
    mPrintEnabled boolean false none Enable mprint output for SAS code during the data mining process. If true, sets \'OPTIONS MPRINT\'
    symbolGenEnabled boolean false none Enable debug and macro variable functionality. If true, sets \'OPTIONS MPRINT SYMBOLGEN\'.
    version integer(int32) false none Version of the resource.

    compareSettings

    {
      "classStatistic": "ks",
      "cutoff": "5",
      "intervalStatistic": "ase",
      "selectionDepth": "5",
      "selectionTable": "default",
      "version": 0
    }
    
    

    Compare Settings

    Properties
    Name Type Required Restrictions Description
    classStatistic string false none The criteria for selecting a champion model when the using a class target variable.
    cutoff string false none The cutoff value of the champion model selection criteria. This is used for criteria originating from the ROC table.
    intervalStatistic string false none The criteria for selecting a champion model when using an interval target variable.
    selectionDepth string false none The selection depth of the champion model selection criteria. This is used for criteria originating from the FIT Statistics.
    selectionTable string false none The partition to use for champion selection. This can be Test, Train or Validate.
    version integer(int32) false none Version of the resource.
    Enumerated Values
    Property Value
    classStatistic ks
    classStatistic ase
    classStatistic rase
    classStatistic mce
    classStatistic mcll
    classStatistic c
    classStatistic f1
    classStatistic fdr
    classStatistic fpr
    classStatistic acc
    classStatistic ks2
    classStatistic lift
    classStatistic cumulativeLift
    classStatistic gain
    classStatistic gini
    classStatistic capturedResponse
    classStatistic cumulativeCapturedResponse
    classStatistic misclassificationEvent
    classStatistic misclassificationCutoff
    cutoff 5
    cutoff 10
    cutoff 15
    cutoff 20
    cutoff 25
    cutoff 30
    cutoff 35
    cutoff 40
    cutoff 45
    cutoff 50
    cutoff 55
    cutoff 60
    cutoff 65
    cutoff 70
    cutoff 75
    cutoff 80
    cutoff 85
    cutoff 90
    cutoff 95
    intervalStatistic ase
    intervalStatistic rase
    intervalStatistic rmae
    intervalStatistic rmsle
    selectionDepth 5
    selectionDepth 10
    selectionDepth 15
    selectionDepth 20
    selectionTable default
    selectionTable train
    selectionTable validate
    selectionTable test

    foldingSettings

    {
      "enableFolding": true,
      "enableManualFoldingSelection": true,
      "numberOfFolds": 0,
      "eventProportion": 0,
      "nonEventProportion": 0,
      "version": 0
    }
    
    

    Folding Settings

    Properties
    Name Type Required Restrictions Description
    enableFolding boolean false none Whether k-fold partitioning is enabled for the project.
    enableManualFoldingSelection boolean false none Whether manual number of folds selection is enabled for the project.
    numberOfFolds integer(int32) false none The number of folds to use if manual mode is selected.
    eventProportion integer(int32) false none The proportion of events in each fold.
    nonEventProportion integer(int32) false none The proportion of non-events in each fold.
    version integer(int32) false none Version of the resource.

    parameter

    {
      "label": "string",
      "length": 0,
      "order": 0,
      "parameter": "string",
      "preformatted": true,
      "type": "undefined",
      "values": [
        "string"
      ]
    }
    
    

    Parameter

    Properties
    Name Type Required Restrictions Description
    label string false none The display name. May be localized.
    length integer(int32) false none The maximum width among this parameter's values.
    order integer(int32) false none The index of this parameter in the collection.
    parameter string true none The parameter name. Should not be localized.
    preformatted boolean false none Indicates whether this parameter's values have already been formatted.
    type string true none The data type of this parameter's values.
    values [string] true none Keys used to associate this parameter with values in the rows of data.
    Enumerated Values
    Property Value
    type undefined
    type num
    type char
    type report

    classificationCutoffSettings

    {
      "classificationCutoffEnabled": true,
      "classificationCutoffValue": 0,
      "version": 0
    }
    
    

    Classification Cutoff Settings

    Properties
    Name Type Required Restrictions Description
    classificationCutoffEnabled boolean false none The classification cutoff enabled flag.
    classificationCutoffValue number(double) false none The classification cutoff value.
    version integer(int32) false none Version of the resource.

    pythonConfigurationCodeSettings

    {
      "pythonConfigurationCodeEnabled": true,
      "pythonConfigurationCode": "string",
      "version": 0
    }
    
    

    Python Configuration Code Settings

    Properties
    Name Type Required Restrictions Description
    pythonConfigurationCodeEnabled boolean false none The Python configuration code enabled flag. Setting this to true indicates that the Python configuration code should be run prior to any open source Python components in the project.
    pythonConfigurationCode string false none Python configuration pre-code to be run prior to any Python code run in open source components in the project.
    version integer(int32) false none Version of the resource.

    scoreExecutionRequest

    {
      "name": "My Score Execution Request",
      "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
      "mappedCodeUri": "http://files/files/0c7281d8-063d-49dd-be6b-392e9c9e930c",
      "outputTable": "example-table",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    

    Score Execution Request

    Properties
    Name Type Required Restrictions Description
    type string(enumeration) false none Score execution request can be either scoreDefinition or mappedCode. Default value is scoreDefinition.
    name string true none The descriptive name for the request. Which will be shown when showing executions.
    description string false none The description of the request.
    hints object false none Hints used to execute an object for score.
    » additionalProperties string false none none
    jobDefinition array false none Inline Job Definition which is used to score. Either this or jobDefinitionId should be used.
    jobDefinitionId string false none Job definition id which is used to score. Either this or the jobDefinition should be used.
    scoreDefinition array false none Inline score definition. Valid only when type is scoreDefinition. Either this or scoreDefinitionId should be used
    scoreDefinitionId string true none Score definition id which is used to score an object. Valid only when type is scoreDefinition. Either this or the scoreDefinition should be part of the request. Should not use both of them. Only valid when the type is scoreDefinition.
    overrideScoreDefinition array false none Overrides the details of the existing score definition represented by scoreDefinitionId. Valid only when type is scoreDefinition.
    mappedCode string false none Inline mapped code. Valid only when type is mappedCode. Either this or mappedCodeUri should be used.
    mappedCodeUri string true none Uri containing mapped code. Valid only when type is mappedCode. Either this or mappedCode should be used.
    outputTable array true none Table details where the output will be generated after executing the mapped code.
    version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    type scoreDefinition
    type mappedCode

    trackedResource

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z"
    }
    
    

    Tracked Resource

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The username of whoever created the resource.
    modifiedBy string false none The username of whoever last modified the resource.
    creationTimeStamp string(date-time) false none The timestamp for when the resource was created.
    modifiedTimeStamp string(date-time) false none The timestamp for when the resource was last modified.

    validationItem

    {
      "itemType": "group",
      "id": "string",
      "name": "string",
      "displayName": "string",
      "description": "string",
      "array": true,
      "clientProperties": [
        {
          "name": "string",
          "value": "string"
        }
      ],
      "enabledWhen": "string",
      "enabledWhenValue": true
    }
    
    

    Validation Item

    Properties
    Name Type Required Restrictions Description
    itemType string false none Indicates whether this item represents a single property or a group of validation items.
    id string false none A unique identifier for the validation item.
    name string false none The validation item's name, if any. If set, this value is unique among all items in the same parent group.
    displayName string false none A user-friendly name for the validation item"
    description string false none A description of the validation item
    array boolean false none An indication of whether this item represents an array of property values
    clientProperties [property] false none [A pair consisting of a string name and a string value. This is an element of application/vnd.sas.properties]
    enabledWhen string false none An expression describing when the validation item is enabled.
    enabledWhenValue boolean false none An indication of whether or not this item is enabled for a given set of property values. It is an evaluation of the enabledWhen expression over property values, when available.
    Enumerated Values
    Property Value
    itemType group
    itemType property

    scoreDefinition

    {
      "name": "My Score Definition",
      "objectDescriptor": {
        "uri": "/businessRules/ruleSets/0d25d749-24e0-4e5d-a773-ea7a1eb0fdc5"
      },
      "inputData": {
        "type": "CASTable",
        "serverName": "edmcas",
        "tableName": "BADCAR_DEMO",
        "libraryName": "HPS"
      },
      "mappings": [
        {
          "variableName": "Make",
          "mappingType": "datasource",
          "mappingValue": "make"
        },
        {
          "variableName": "Model",
          "mappingType": "datasource",
          "mappingValue": "model"
        },
        {
          "variableName": "Odometer",
          "mappingType": "datasource",
          "mappingValue": "vehodo"
        },
        {
          "variableName": "Maximum_Mileage",
          "mappingType": "static",
          "mappingValue": 100000
        }
      ]
    }
    
    

    Score Definition

    Properties
    Name Type Required Restrictions Description
    id string false none The system-assigned unique ID for this object
    name string true none The score definition name
    description string false none The score definition description
    createdBy string false none The user who created the score definition.
    creationTimeStamp string(date-time) false none The date and time that the score definition was created.
    modifiedBy string false none The userId of the authenticated user who last updated the score definition.
    modifiedTimeStamp string(date-time) false none The date and time that the score definition was last modified.
    preprocessingCode string false none Preprocessing code that is executed before executing the Mapped Code.
    objectDescriptor array true none Descriptor of a Score Object whose logic is used to produce score for Input Data.
    inputData array true none Input Data that will be scored.
    mappings [mapping] false none Array of mappings between Score Object variables and Input Data columns.
    properties object false none A set of properties for this score definition.
    » additionalProperties string false none none
    links [link] false none Zero or more links to related resources or operations.
    version integer false none This media type's schema version number. This representation is version 1.

    enumerationGroupItem

    {
      "id": "string",
      "name": "string"
    }
    
    

    Enumeration Group Item

    Properties
    Name Type Required Restrictions Description
    id string false none The enumeration item id
    name string false none The enumeration item name. It is localized based on the user locale.

    jobDefinition

    {
      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
      "name": "string",
      "type": "string",
      "code": "string",
      "parameters": [
        {
          "name": "string",
          "type": "TABLE",
          "label": "string",
          "required": true,
          "defaultValue": "string"
        }
      ],
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "properties": {
        "property1": "string",
        "property2": "string"
      },
      "version": 0
    }
    
    

    Job Definition

    Properties
    Name Type Required Restrictions Description
    id string(uuid) false none unique id
    name string true none name
    type string true none type of job - this will determine which execution provider executes this job
    code string true none execution specific code to be executed
    parameters [any] true none input parameters to be collected when executing this job definition
    » name string false none name of the parameter
    » type string(enumeration) false none type of the parameter (TABLE, NUMERIC, DATE, CHARACTER)
    » label string false none display value for the name of this parameter
    » required boolean false none is this parameter required for execution
    » defaultValue string false none default value of this parameter if one is not specified at execution time
    createdBy string false none The user who created this job
    modifiedBy string false none The user who modified this job
    creationTimeStamp string(date-time) false none The formatted time stamp when the job was created, in yyyy-mm-ddThh:mm:ssZ format
    modifiedTimeStamp string(date-time) false none The formatted time stamp when the job was modified, in yyyy-mm-ddThh:mm:ssZ format
    links [link] false none zero or more link objects. See the above link relations table for a description of the link types
    properties object false none zero or more name, value pairs (map) needed to execute job definition, maximum name length = 100
    » additionalProperties string false none none
    version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    type TABLE
    type NUMERIC
    type DATE
    type CHARACTER

    validationModelSummary

    {
      "createdBy": "string",
      "modifiedBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "id": "string",
      "name": "string",
      "description": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    

    Validation Model Summary

    Properties
    Name Type Required Restrictions Description
    createdBy string false none The user who created the model.
    modifiedBy string false none The user who most recently modified the model.
    creationTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the model was created.
    modifiedTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the model was last modified.
    id string false none A unique identifier for the model.
    name string false none The model name.
    description string false none The model description.
    links [link] false none [A link to a related operation or resource.]
    version integer(int32) false none The version number of this representation schema.

    overrideScoreDefinition

    {
      "preprocessingCode": "string",
      "objectDescriptor": [
        {
          "name": "string",
          "type": "string",
          "uri": "https://example.com"
        }
      ],
      "inputData": [
        {
          "type": "CASTable",
          "serverName": "string",
          "libraryName": "string",
          "tableName": "string",
          "code": "string",
          "outputTableName": "string"
        }
      ],
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ]
    }
    
    

    Override Score Definition

    Properties
    Name Type Required Restrictions Description
    preprocessingCode string false none Code which should be executed before executing actual code.
    objectDescriptor array false none Descriptor of a Score Object whose logic is used to produce a score for Input Data.
    inputData array false none Input Data that will be scored.
    mappings [mapping] false none Array of mappings between score object variables and input data columns.

    property

    {
      "name": "string",
      "value": "string"
    }
    
    

    Property

    Properties
    Name Type Required Restrictions Description
    name string true none The property name.
    value string true none The property value.

    mapping

    {
      "variableName": "string",
      "mappingType": "datasource",
      "mappingValue": 0
    }
    
    

    Mapping

    Properties
    Name Type Required Restrictions Description
    variableName string true none Name of the Score Object's variable.
    mappingType string(enumeration) true none The mapping type.
    mappingValue any false none 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. Required if the mappingType is datasource.

    anyOf

    Name Type Required Restrictions Description
    » anonymous integer false none none

    or

    Name Type Required Restrictions Description
    » anonymous string false none none
    Enumerated Values
    Property Value
    mappingType datasource
    mappingType static

    objectDescriptor

    {
      "name": "string",
      "type": "string",
      "uri": "https://example.com"
    }
    
    

    Object Descriptor

    Properties
    Name Type Required Restrictions Description
    name string false none Name of the Score Object.
    type string false none Type of the Score Object.
    uri string(uri) true none Uri to the Score Object.

    inputData

    {
      "type": "CASTable",
      "serverName": "string",
      "libraryName": "string",
      "tableName": "string",
      "code": "string",
      "outputTableName": "string"
    }
    
    

    Input Data

    Properties
    Name Type Required Restrictions Description
    type string(enumeration) true none The type of input data.
    serverName string true none CAS Server name where CAS table is located. Valid only if the type is CASTable.
    libraryName string true none CAS Library name where CAS table is located. Valid only if the type is CASTable.
    tableName string true none Name of the CAS table. Valid only if the type is CASTable.
    code string true none Code containing inline data. Valid only if the type is Inline.
    outputTableName string true none Name of the output table that will be generated when the inline code is executed. Valid only if the type is Inline.
    Enumerated Values
    Property Value
    type CASTable
    type Inline

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    application/vnd.sas.analytics.data.mining.model.score.request

    The model score request contains the information required to score a data mining model.

    The schema is at Model score request.

    application/vnd.sas.analytics.data.mining.model.score.request+json

    Here is an example of the JSON representation of this media type.

    
     {
      "dataTableUri": "${dataUri}",
      "outputCaslibName": "",
      "outputTableName": ""
    }
    
    Project

    The data mining service adds the following links for SAS Visual Data Mining and Machine Learning-specific functionality on a project.

    Relation Method Description
    startRetraining POST Initiates project retraining. Updates the project data source.
    Response type: application/vnd.sas.job.execution.job
    currentRetrainingJob GET Returns the currently running retraining job.
    Response type: application/vnd.sas.job.execution.job
    startBatchRetraining POST Retrains the project using new data. Updates the project data source, recreates the project partition table, and runs all of the pipelines in the project.
    Response type: application/vnd.sas.job.execution.job
    retrainingState PUT Sets the retrainingState for the project. The retraining state can be set as Needed or Completed.
    Response type: application/vnd.sas.analytics.project
    retrainingChampionModel GET Returns the champion model from the last retraining job.
    Response type: application/vnd.sas.analytics.data.mining.model
    Pipeline Comparison Table

    Returns a collection of comparison tables for each model in a data mining project. Each table in the collection represents the comparison statistics for a particular table partition.

    The following links are available on each row in each table in the collection.

    Relation Method Description
    modelScoringSampleCode GET Downloads the sample code for creating a Score Execution resource for the model.
    Response type: application/vnd.sas.source.text

    Score Execution

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Score Execution API is used to produce a score by executing the mapped code generated by score objects using the score definition.

    Usage Notes

    Overview

    The Score Execution API is used to validate a score object. First, a Score Definition is created using the score object, the input data, and the mappings. After the score execution has successfully completed, the score output table can be validated for the expected values. Currently, the validation is done manually. Further analysis can be done on the score output table by generating an analysis output table.

    The Score Execution API can also generate the score output table by providing mapped code directly instead of generating mapped code from the Score Definition.

    Why Use this API?
    1. Users can validate score objects by generating and executing the code.
    2. Score execution can be used as a consistent way to generate a score for the input data using different types of score objects such as Decisions.
    3. Score execution can generate an analysis output table on the generated score output table.
    4. Score Execution can easily choose where and how to execute to generate a score by choosing the correct job definition. The Score Execution API automatically chooses the Default Score Job Definition if one is not provided.
    5. All score executions and analyses can be managed from a single location.
    Sequence Diagram of How the Score Is Generated with the Score Definition

    Sequence score with score definition

    How is a Job Definition Selected?

    Here is the order in which a job definition is selected.

    1. An inline job definition is provided as part of the score execution request.
    2. A persisted job definition ID is provided as part of the score execution request.
    3. A job definition with the properties ''type==scoring'' and ''objecttype==< object type of the score object >''.
    4. Default Score Job Definition.
    How Job Definition Parameter Values are Assigned?

    The score object returns the mappedCode, the outputTableName, and the outputLibraryName parameters.

    1. The mappedCode parameter is assigned with the value of MappedCode.code.
    2. The outputTableName parameter is assigned with the value of MappedCode.outputTableName.
    3. The outputLibraryName parameter is assigned with the value of MappedCode.outputLibraryName.
    4. The casServerName parameter is assigned a value of the input table's CAS server name for the inputData type CASTable. For the inputData type of Inline, the value is set to the first available CAS Server.
    5. The inlineCode parameter is assigned a value of the input data code. This is valid only when InputData type is Inline.
    6. If any parameter name matches the hints provided, then the value of the hint is assigned.
    7. If any parameter name matches the property name of the score definition, then the property value is assigned.
    Sequence Diagram of How the Score Is Generated with Mapped Code

    Sequence score with mapped code

    How is a Job Definition Selected?

    Here is the order in which a job definition is selected.

    1. An inline job definition is provided as part of the score execution request.
    2. A persisted job definition ID is provided as part of the score execution request.
    3. Default Score Job Definition.
    How Job Definition Parameter Values are Assigned?

    The request contains the mappedCode, the outputTableName, and the outputLibraryName parameters.

    1. The mappedCode parameter is assigned the value of the request's mappedCode.
    2. The outputTableName parameter is assigned the value of the request's outputTableName.
    3. The outputLibraryName parameter is assigned the value of the request's outputLibraryName.
    4. If any parameter name matches the hints provided, then the value of the hint is assigned.
    Sequence Diagram of How the Analysis Is Generated

    Sequence analysis

    How is a Job Definition Selected?

    Here is the order in which a job definition is selected.

    1. The inline job definition is provided as part of the score analysis request.
    2. The persisted job definition ID is provided as part of the score analysis request.
    3. The job definition with the properties "type==scoring" and "objecttype==< object type of the score object >" and "analysistype=< analysis type >".
    4. Default Analysis Job Definition.
    How Job Definition Parameter Values are Assigned?

    The score object returns the analysisCode, the outputTableName, and the outputLibraryName parameters.

    1. The analysisCode parameter is assigned the value of AnalysisCode.code.
    2. The outputTableName parameter is assigned the value of AnalysisCode.outputTableName.
    3. The outputLibraryName parameter is assigned the value of AnalysisCode.outputLibraryName.
    4. The casServerName parameter is assigned the value of the score output table's CAS server name.
    5. If any parameter name matches the hints provided, then the value of the hint is assigned.
    6. If any parameter name matches the property name of the score definition, then that property value is assigned.

    Security

    Please see Security in SAS REST APIs for details about authentication and authorization.

    Authorization rules for the score executions:

    Authorization rules for score analyses:

    Terminology

    score

    output data set with additional computed columns produced by executing the code against a set of data.

    score execution

    creates a score for the input data using the mapped code and job definition. application/vnd.sas.score.execution

    score output table

    contains the output variables of the score object. These variables are produced from the score execution.

    score analysis

    creates the analysis output table from the score execution, the score output table, and the score object.

    application/vnd.sas.score.analysis

    analysis output table

    contains the analysis output variables of the score objects analysis code. These variables are produced from the score analysis.

    score definition

    contains details about the input data, the score object, and the mapping. application/vnd.sas.score.definition

    NOTE: For more details about score definitions, see the Score Definitions API.

    score object

    object whose generated mapped code or analysis code is used to generate the score output table or analysis output table.

    Some examples of score objects are decisions and models.

    Any object that can generate mapped code by implementing the REST endpoint shown below can be treated as a score object. POST /{score-object-uri}/mappedCode Content-Type: application/vnd.sas.score.code.generation.request Accept: application/vnd.sas.score.mapped.code

    To generate the analysis code, the score object needs to implement the REST endpoint shown below. POST /{score-object-uri}/analysisCode Content-Type: application/vnd.sas.score.analysis.code.generation.request Accept: application/vnd.sas.score.analysis.code

    analysis code

    executable code generated by the score object using the score execution and the score output table. application/vnd.sas.score.analysis.code

    analysis code generation request

    contains hints to generate the analysis code using the score execution and the score output table by the score object. application/vnd.sas.score.analysis.code.generation.request

    hints

    name value pairs that are passed to the score objects to generate the mapped code and the analysis code. These are passed to score objects for generating the mapped code and analysis code. These hints can also be used to assign values for the job definition.

    rule set

    sequenced group of related business rules that accomplish a logical business operation. See the Business Rules API for more details.

    decision

    allows users to build and retrieve a decision flow by linking statistical models in combination with deterministic logic from business rules for the purpose of integrating into an operational process. See the Decision API for more details.

    model

    a formula or algorithm that computes outputs from inputs. An example is a predictive model that derives information about the conditional distribution of the target variables, given the input variables.

    job definition

    creates a definition to be used by the job execution provider. See the Job Definitions API for more details.

    job execution

    provides a common mechanism for executing and managing asynchronous jobs across various environments. See the Job Execution API for more details.

    Default Job Definitions

    Default Job Definition

    Here is an example of a default job definition used for score execution.

    json { "name": "Default Score Job Definition", "type": "REST", "parameters": [ { "required": true, "type": "CHARACTER", "name": "casServerName" }, { "required": true, "type": "CHARACTER", "name": "outputLibraryName" }, { "required": true, "type": "CHARACTER", "name": "outputTableName" }, { "required": true, "type": "CHARACTER", "name": "mappedCode" }, { "required": false, "type": "CHARACTER", "name": "preprocessingCode" }, { "required": false, "type": "CHARACTER", "name": "inlineCode" }, { "required": false, "type": "CHARACTER", "name": "fmtLibNames" } ], "code": [ { "name": "Creating CAS session", "POST": "/casProxy/servers/{casServerName}/cas/sessions", "headers": { "Authorization": "{authtoken}", "Accept": "application/json" }, "bind": { "jsonPath": { "casSessionId": "$.session" } } }, { "name": "Loading session prop action set", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/loadActionSet", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "actionSet": "sessionProp" }, "bind": { "jsonPath" : { "result_log1": "$.log" } } }, { "name": "Setting format library searchable in session", "if": "fmtLibNames != null && fmtLibNames.length() != 0", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/setFmtSearch", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "fmtLibNames": "{fmtLibNames}" }, "bind": { "jsonPath" : { "result_log2": "$.log" } } }, { "name": "Loading ds2 action set", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/loadActionSet", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "actionSet": "ds2" }, "bind": { "jsonPath" : { "result_log3": "$.log" } } }, { "name": "Running ds2 inline code", "if": "inlineCode != null && inlineCode.length() != 0", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/runDS2", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "program": "{inlineCode}" }, "bind": { "jsonPath" : { "result_log4": "$.log" } } }, { "name": "Running pre-processing code", "if": "preprocessingCode != null && preprocessingCode.length() != 0", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/runDS2", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "program": "{preprocessingCode}" }, "bind": { "jsonPath" : { "result_log5": "$.log" } } }, { "name": "Running ds2 mapped code", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/runDS2", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "program": "{mappedCode}" }, "bind": { "jsonPath" : { "result_log6": "$.log" } } }, { "name": "Loading table action set", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/loadActionSet", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "actionSet": "table" }, "bind": { "jsonPath" : { "result_log7": "$.log" } } }, { "name": "Promoting table", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/promote", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "caslib": "{outputLibraryName}", "name": "{outputTableName}", "targetLib": "{outputLibraryName}" }, "bind": { "jsonPath" : { "result_log8": "$.log" } } }, { "name": "Deleting session", "DELETE": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}", "headers": { "Authorization": "{authtoken}" } } ] }

    Default Score Analysis Job Definition

    Here is an example of a default score analysis job definition.

    json { "name": "Default Score Analysis Job Definition", "type": "REST", "parameters": [ { "required": true, "type": "CHARACTER", "name": "casServerName" }, { "required": true, "type": "CHARACTER", "name": "outputLibraryName" }, { "required": true, "type": "CHARACTER", "name": "outputTableName" }, { "required": true, "type": "CHARACTER", "name": "analysisCode" } ], "code": [ { "name": "Creating CAS session", "POST": "/casProxy/servers/{casServerName}/cas/sessions", "headers": { "Authorization": "{authtoken}", "Accept": "application/json" }, "bind": { "jsonPath": { "casSessionId": "$.session" } } }, { "name": "Loading session prop action set", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/loadActionSet", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "actionSet": "sessionProp" }, "bind": { "jsonPath" : { "result_log1": "$.log" } } }, { "name": "Loading ds2 action set", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/loadActionSet", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "actionSet": "ds2" }, "bind": { "jsonPath" : { "result_log2": "$.log" } } }, { "name": "Running ds2 mapped code", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/runDS2", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "program": "{analysisCode}" }, "bind": { "jsonPath" : { "result_log3": "$.log" } } }, { "name": "Loading table action set", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/loadActionSet", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "actionSet": "table" }, "bind": { "jsonPath" : { "result_log4": "$.log" } } }, { "name": "Promoting table", "POST": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}/actions/promote", "headers": { "Authorization": "{authtoken}", "Content-Type": "application/json", "Accept": "application/json" }, "body": { "caslib": "{outputLibraryName}", "name": "{outputTableName}", "targetLib": "{outputLibraryName}" }, "bind": { "jsonPath" : { "result_log5": "$.log" } } }, { "name": "Deleting session", "DELETE": "/casProxy/servers/{casServerName}/cas/sessions/{casSessionId}", "headers": { "Authorization": "{authtoken}" } } ] }

    Operations

    Root

    Contains the operations for the root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreExecution/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/scoreExecution/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/scoreExecution/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreExecution/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Get a list of top level links.

    Example responses

    200 Response

    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "scoreExecutions",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "createScoreExecution",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.score.execution.request",
          "responseType": "application/vnd.sas.score.execution"
        }
      ]
    }
    
    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "scoreExecutions",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "createScoreExecution",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.score.execution.request",
          "responseType": "application/vnd.sas.score.execution"
        }
      ]
    }
    

    404 Response

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Status Meaning Description Schema
    200 OK OK. Inline
    404 Not Found Service is not available Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Content-Type string No description

    Get the headers for the APIs

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/scoreExecution/
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/scoreExecution/',
    {
      method: 'HEAD'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.head('https://example.com/scoreExecution/')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/scoreExecution/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /

    Returns the headers for the API. Also used to determine whether the service provided by the API is available.

    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Executions

    Contains the operations to create, read, and delete score executions.

    Get a list of the score executions

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreExecution/executions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/scoreExecution/executions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/scoreExecution/executions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreExecution/executions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /executions

    Returns a list of the score executions based on the specified pagination, filtering, and sorting options. The items in the list depend on the Accept-Item header.

    Parameters
    Name In Type Required Description
    Accept-Item header string(media-type) false Used for selecting the desired item representation.
    start query integer(int64) false The index of the first score execution to return.
    limit query integer(int32) false The maximum number of score executions to return.
    filter query string(filter-criteria) false The criteria for filtering the score executions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the score executions. See Sorting in REST APIs.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.score.execution+json
    Accept-Item application/vnd.sas.summary+json

    Example responses

    200 Response

    {
      "count": 3,
      "items": [
        {
          "createdBy": "sasuser",
          "creationTimeStamp": "2021-12-22T22:01:24.90638Z",
          "id": "feed27ef-988f-4b6e-ba84-aa399c786253",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions",
              "uri": "/scoreExecution/executions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "type": "application/vnd.sas.score.execution"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253"
            },
            {
              "method": "GET",
              "rel": "analyses",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analyses",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analyses"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/state",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/state",
              "type": "text/plain"
            },
            {
              "method": "POST",
              "rel": "analysisCode",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analysisCode",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analysisCode",
              "type": "application/vnd.sas.score.analysis.code.generation.request",
              "responseType": "application/vnd.sas.score.analysis.code"
            }
          ],
          "modifiedBy": "sasuser",
          "modifiedTimeStamp": "2021-12-22T22:01:31.360206Z",
          "name": "Execution for Decision_Scenario",
          "type": "scoreExecution",
          "version": 2
        },
        {
          "createdBy": "sasuser",
          "creationTimeStamp": "2022-01-04T17:25:17.891027Z",
          "id": "63385326-b719-44f5-91f9-d45f9c9b998a",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions",
              "uri": "/scoreExecution/executions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "type": "application/vnd.sas.score.execution"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a"
            },
            {
              "method": "GET",
              "rel": "analyses",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/analyses",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/analyses"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/state",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/state",
              "type": "text/plain"
            },
            {
              "method": "POST",
              "rel": "analysisCode",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/analysisCode",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/analysisCode",
              "type": "application/vnd.sas.score.analysis.code.generation.request",
              "responseType": "application/vnd.sas.score.analysis.code"
            }
          ],
          "modifiedBy": "sasuser",
          "modifiedTimeStamp": "2022-01-04T17:25:22.598809Z",
          "name": "Execution for Decision_Test_1",
          "type": "scoreExecution",
          "version": 2
        },
        {
          "createdBy": "sasuser",
          "creationTimeStamp": "2022-01-04T17:32:37.868805Z",
          "id": "eb665a58-1b3f-421b-985c-b5514fc1ae45",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions",
              "uri": "/scoreExecution/executions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "type": "application/vnd.sas.score.execution"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45"
            },
            {
              "method": "GET",
              "rel": "analyses",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/analyses",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/analyses"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/state",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/state",
              "type": "text/plain"
            },
            {
              "method": "POST",
              "rel": "analysisCode",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/analysisCode",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/analysisCode",
              "type": "application/vnd.sas.score.analysis.code.generation.request",
              "responseType": "application/vnd.sas.score.analysis.code"
            }
          ],
          "modifiedBy": "sasuser",
          "modifiedTimeStamp": "2022-01-04T17:32:40.042255Z",
          "name": "Execution for Decision1_0_2022-01-04T17:32:18.561Z",
          "type": "scoreExecution",
          "version": 2
        }
      ],
      "limit": 500,
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.score.execution"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions?start=0&limit=500",
          "uri": "/scoreExecution/executions?start=0&limit=500",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.score.execution.request",
          "responseType": "application/vnd.sas.score.execution"
        }
      ],
      "name": "scoreExecutions",
      "start": 0,
      "version": 2
    }
    
    {
      "count": 3,
      "items": [
        {
          "createdBy": "sasuser",
          "creationTimeStamp": "2021-12-22T22:01:24.90638Z",
          "id": "feed27ef-988f-4b6e-ba84-aa399c786253",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions",
              "uri": "/scoreExecution/executions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "type": "application/vnd.sas.score.execution"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253"
            },
            {
              "method": "GET",
              "rel": "analyses",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analyses",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analyses"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/state",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/state",
              "type": "text/plain"
            },
            {
              "method": "POST",
              "rel": "analysisCode",
              "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analysisCode",
              "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analysisCode",
              "type": "application/vnd.sas.score.analysis.code.generation.request",
              "responseType": "application/vnd.sas.score.analysis.code"
            }
          ],
          "modifiedBy": "sasuser",
          "modifiedTimeStamp": "2021-12-22T22:01:31.360206Z",
          "name": "Execution for Decision_Scenario",
          "type": "scoreExecution",
          "version": 2
        },
        {
          "createdBy": "sasuser",
          "creationTimeStamp": "2022-01-04T17:25:17.891027Z",
          "id": "63385326-b719-44f5-91f9-d45f9c9b998a",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions",
              "uri": "/scoreExecution/executions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "type": "application/vnd.sas.score.execution"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a"
            },
            {
              "method": "GET",
              "rel": "analyses",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/analyses",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/analyses"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/state",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/state",
              "type": "text/plain"
            },
            {
              "method": "POST",
              "rel": "analysisCode",
              "href": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/analysisCode",
              "uri": "/scoreExecution/executions/63385326-b719-44f5-91f9-d45f9c9b998a/analysisCode",
              "type": "application/vnd.sas.score.analysis.code.generation.request",
              "responseType": "application/vnd.sas.score.analysis.code"
            }
          ],
          "modifiedBy": "sasuser",
          "modifiedTimeStamp": "2022-01-04T17:25:22.598809Z",
          "name": "Execution for Decision_Test_1",
          "type": "scoreExecution",
          "version": 2
        },
        {
          "createdBy": "sasuser",
          "creationTimeStamp": "2022-01-04T17:32:37.868805Z",
          "id": "eb665a58-1b3f-421b-985c-b5514fc1ae45",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions",
              "uri": "/scoreExecution/executions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "type": "application/vnd.sas.score.execution"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45"
            },
            {
              "method": "GET",
              "rel": "analyses",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/analyses",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/analyses"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/state",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/state",
              "type": "text/plain"
            },
            {
              "method": "POST",
              "rel": "analysisCode",
              "href": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/analysisCode",
              "uri": "/scoreExecution/executions/eb665a58-1b3f-421b-985c-b5514fc1ae45/analysisCode",
              "type": "application/vnd.sas.score.analysis.code.generation.request",
              "responseType": "application/vnd.sas.score.analysis.code"
            }
          ],
          "modifiedBy": "sasuser",
          "modifiedTimeStamp": "2022-01-04T17:32:40.042255Z",
          "name": "Execution for Decision1_0_2022-01-04T17:32:18.561Z",
          "type": "scoreExecution",
          "version": 2
        }
      ],
      "limit": 500,
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.score.execution"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions?start=0&limit=500",
          "uri": "/scoreExecution/executions?start=0&limit=500",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.score.execution.request",
          "responseType": "application/vnd.sas.score.execution"
        }
      ],
      "name": "scoreExecutions",
      "start": 0,
      "version": 2
    }
    

    400 Response

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. scoreExecutionCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new score execution

    Code samples

    # You can also use wget
    curl -X POST https://example.com/scoreExecution/executions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/json' \
      -H 'Accept: application/vnd.sas.score.execution+json'
    
    
    const inputBody = '{
      "type": "scoreDefinition",
      "name": "string",
      "description": "string",
      "hints": {
        "property1": "string",
        "property2": "string"
      },
      "jobDefinition": {
        "version": 0,
        "id": "string",
        "name": "string",
        "description": "string",
        "type": "string",
        "code": "string",
        "parameters": [
          {
            "version": 0,
            "name": "string",
            "type": "string",
            "label": "string",
            "required": true,
            "defaultValue": "string"
          }
        ],
        "properties": [
          {
            "name": "string",
            "value": "string"
          }
        ],
        "createdBy": "string",
        "modifiedBy": "string",
        "creationTimeStamp": "string",
        "modifiedTimeStamp": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ]
      },
      "jobDefinitionId": "string",
      "scoreDefinition": {
        "name": "string",
        "description": "string",
        "preprocessingCode": "string",
        "objectDescriptor": {
          "name": "string",
          "type": "string",
          "uri": "https://example.com"
        },
        "inputData": {
          "type": "CASTable",
          "serverName": "string",
          "libraryName": "string",
          "tableName": "string",
          "code": "string",
          "outputTableName": "string"
        },
        "mappings": [
          {
            "variableName": "string",
            "mappingType": "datasource",
            "mappingValue": 0
          }
        ],
        "properties": {
          "property1": "string",
          "property2": "string"
        }
      },
      "scoreDefinitionId": "string",
      "overrideScoreDefinition": {
        "preprocessingCode": "string",
        "objectDescriptor": {
          "name": "string",
          "type": "string",
          "uri": "https://example.com"
        },
        "inputData": {
          "type": "CASTable",
          "serverName": "string",
          "libraryName": "string",
          "tableName": "string",
          "code": "string",
          "outputTableName": "string"
        },
        "mappings": [
          {
            "variableName": "string",
            "mappingType": "datasource",
            "mappingValue": 0
          }
        ]
      },
      "mappedCode": "string",
      "mappedCodeUri": "string",
      "outputTable": {
        "tableName": "string",
        "libraryName": "string",
        "serverName": "string"
      }
    }';
    const headers = {
      'Content-Type':'application/json',
      'Accept':'application/vnd.sas.score.execution+json'
    };
    
    fetch('https://example.com/scoreExecution/executions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/json',
      'Accept': 'application/vnd.sas.score.execution+json'
    }
    
    r = requests.post('https://example.com/scoreExecution/executions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/json"},
            "Accept": []string{"application/vnd.sas.score.execution+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/scoreExecution/executions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /executions

    Creates a new score execution based on the representation in the request body.

    Body parameter

    {
      "type": "scoreDefinition",
      "name": "string",
      "description": "string",
      "hints": {
        "property1": "string",
        "property2": "string"
      },
      "jobDefinition": {
        "version": 0,
        "id": "string",
        "name": "string",
        "description": "string",
        "type": "string",
        "code": "string",
        "parameters": [
          {
            "version": 0,
            "name": "string",
            "type": "string",
            "label": "string",
            "required": true,
            "defaultValue": "string"
          }
        ],
        "properties": [
          {
            "name": "string",
            "value": "string"
          }
        ],
        "createdBy": "string",
        "modifiedBy": "string",
        "creationTimeStamp": "string",
        "modifiedTimeStamp": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ]
      },
      "jobDefinitionId": "string",
      "scoreDefinition": {
        "name": "string",
        "description": "string",
        "preprocessingCode": "string",
        "objectDescriptor": {
          "name": "string",
          "type": "string",
          "uri": "https://example.com"
        },
        "inputData": {
          "type": "CASTable",
          "serverName": "string",
          "libraryName": "string",
          "tableName": "string",
          "code": "string",
          "outputTableName": "string"
        },
        "mappings": [
          {
            "variableName": "string",
            "mappingType": "datasource",
            "mappingValue": 0
          }
        ],
        "properties": {
          "property1": "string",
          "property2": "string"
        }
      },
      "scoreDefinitionId": "string",
      "overrideScoreDefinition": {
        "preprocessingCode": "string",
        "objectDescriptor": {
          "name": "string",
          "type": "string",
          "uri": "https://example.com"
        },
        "inputData": {
          "type": "CASTable",
          "serverName": "string",
          "libraryName": "string",
          "tableName": "string",
          "code": "string",
          "outputTableName": "string"
        },
        "mappings": [
          {
            "variableName": "string",
            "mappingType": "datasource",
            "mappingValue": 0
          }
        ]
      },
      "mappedCode": "string",
      "mappedCodeUri": "string",
      "outputTable": {
        "tableName": "string",
        "libraryName": "string",
        "serverName": "string"
      }
    }
    
    Parameters
    Name In Type Required Description
    body body #/paths/~1executions/post/requestBody/content/application~1json/schema true The representation of a score execution request.

    Example responses

    201 Response

    {
      "codeFileUri": "/files/files/6d36a764-6a46-401a-bb89-bc24ac864374",
      "createdBy": "sasuser",
      "creationTimeStamp": "2022-01-05T00:31:45.864991Z",
      "id": "c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "type": "application/vnd.sas.score.execution"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5"
        },
        {
          "method": "GET",
          "rel": "analyses",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/analyses",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/analyses"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/state",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/state",
          "type": "text/plain"
        },
        {
          "method": "POST",
          "rel": "analysisCode",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/analysisCode",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/analysisCode",
          "type": "application/vnd.sas.score.analysis.code.generation.request",
          "responseType": "application/vnd.sas.score.analysis.code"
        }
      ],
      "modifiedBy": "sasuser",
      "modifiedTimeStamp": "2022-01-05T00:31:45.864991Z",
      "outputTable": {
        "libraryName": "Public",
        "serverName": "cas-shared-default"
      },
      "results": {
        "jobRequestId": "8dc7f798-34d9-49aa-a23e-f5cff8daf96b",
        "mappedCodeJobId": "c167600d-7a9f-444c-b7c4-9de1de7d3338"
      },
      "scoreExecutionRequest": {
        "version": 1,
        "name": "My Score Request",
        "hints": {
          "asyncMappedCode": "true",
          "inputLibraryName": "CASUSER(edmdev)",
          "inputTableName": "Scenario_8fc3a739_55a8_4057_9e0d_b5148dafa32a",
          "outputLibraryName": "PUBLIC"
        },
        "type": "scoreDefinition",
        "scoreDefinitionId": "8fc3a739-55a8-4057-9e0d-b5148dafa32a"
      },
      "state": "running",
      "version": 1
    }
    
    {
      "codeFileUri": "/files/files/6d36a764-6a46-401a-bb89-bc24ac864374",
      "createdBy": "sasuser",
      "creationTimeStamp": "2022-01-05T00:31:45.864991Z",
      "id": "c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "type": "application/vnd.sas.score.execution"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5"
        },
        {
          "method": "GET",
          "rel": "analyses",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/analyses",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/analyses"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/state",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/state",
          "type": "text/plain"
        },
        {
          "method": "POST",
          "rel": "analysisCode",
          "href": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/analysisCode",
          "uri": "/scoreExecution/executions/c56894cc-130d-4cc5-a15a-d6dedcc5a2b5/analysisCode",
          "type": "application/vnd.sas.score.analysis.code.generation.request",
          "responseType": "application/vnd.sas.score.analysis.code"
        }
      ],
      "modifiedBy": "sasuser",
      "modifiedTimeStamp": "2022-01-05T00:31:45.864991Z",
      "outputTable": {
        "libraryName": "Public",
        "serverName": "cas-shared-default"
      },
      "results": {
        "jobRequestId": "8dc7f798-34d9-49aa-a23e-f5cff8daf96b",
        "mappedCodeJobId": "c167600d-7a9f-444c-b7c4-9de1de7d3338"
      },
      "scoreExecutionRequest": {
        "version": 1,
        "name": "My Score Request",
        "hints": {
          "asyncMappedCode": "true",
          "inputLibraryName": "CASUSER(edmdev)",
          "inputTableName": "Scenario_8fc3a739_55a8_4057_9e0d_b5148dafa32a",
          "outputLibraryName": "PUBLIC"
        },
        "type": "scoreDefinition",
        "scoreDefinitionId": "8fc3a739-55a8-4057-9e0d-b5148dafa32a"
      },
      "state": "running",
      "version": 1
    }
    

    400 Response

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A score execution was created. scoreExecutionCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string uri The URL of the score execution.
    201 ETag string The entity tag for the score execution.
    201 Last-Modified string date-time The timestamp when the score execution was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Get a score execution

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreExecution/executions/{executionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.score.execution+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.score.execution+json'
    };
    
    fetch('https://example.com/scoreExecution/executions/{executionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.score.execution+json'
    }
    
    r = requests.get('https://example.com/scoreExecution/executions/{executionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.score.execution+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreExecution/executions/{executionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /executions/{executionId}

    Returns the representation of the specified score execution.

    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.

    Example responses

    200 Response

    {
      "codeFileUri": "/files/files/a26709f1-efec-4eb8-a5eb-a9b3fe7715c2",
      "createdBy": "sasuser",
      "creationTimeStamp": "2021-12-22T22:01:24.90638Z",
      "id": "feed27ef-988f-4b6e-ba84-aa399c786253",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "type": "application/vnd.sas.score.execution"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253"
        },
        {
          "method": "GET",
          "rel": "analyses",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analyses",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analyses"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/state",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/state",
          "type": "text/plain"
        },
        {
          "method": "POST",
          "rel": "analysisCode",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analysisCode",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analysisCode",
          "type": "application/vnd.sas.score.analysis.code.generation.request",
          "responseType": "application/vnd.sas.score.analysis.code"
        }
      ],
      "logFileUri": "/files/files/d56daac3-5411-4a8f-949c-f5a7cad4a643",
      "modifiedBy": "sasuser",
      "modifiedTimeStamp": "2021-12-22T22:01:31.360206Z",
      "outputTable": {
        "tableName": "Decision_Scenario_2021-12-22_22-01-24_output",
        "libraryName": "Public",
        "serverName": "cas-shared-default"
      },
      "results": {
        "debuginfo_1": "",
        "elapsedTime": "2574",
        "executedCode": "outputLibraryName=\"Public\";\noutputTableName=\"Decision_Scenario_2021-12-22_22-01-24_output\";\nmappedCode=\"http://sas-files/files/files/7d613eca-cad2-487e-bf12-22add29c59f5\";\ninputLibraryName=\"CASUSER(sasuser)\";\ninputTableName=\"Scenario_8fc3a739_55a8_4057_9e0d_b5148dafa32a\";\npreprocessingCode=\"null\";\ninlineCode=\"data \"\"CASUSER(sasuser)\"\".\"\"Scenario_8fc3a739_55a8_4057_9e0d_b5148dafa32a\"\"; dcl double foo; enddata;\";\nfmtLibNames=\"userformats3\";\nastoreNames=\"null\";\ncode = '';\nmappedCodeFromRestAPI = '';\nmodelLibName = outputLibraryName;\nmodelTableName = 'TempModel_' || uuidgen();\nmodelName = modelTableName;\nstoreTables = {};\n\nloadActionSet \"modelPublishing\";\nloadActionSet \"ds2\";\nloadActionSet \"table\";\n\naction dropTable / caslib=outputLibraryName, name=outputTableName, quiet=true;\n\nif(astoreNames != \"null\") then do;\n  count=0;\n  t='x';\n  do until (t = ' ');\n    count=count+1;\n    t=scan(astoreNames, count, ' ');\n    if (length(t)>3) then do;\n      table.tableExists result=e / caslib='ModelStore' name=t;\n      haveTable = dictionary(e, 'exists');\n      storeTables = storeTables + {{ caslib='ModelStore', name=t }};\n      if haveTable < 1 then do;\n        rr = reverse(t);\n        pp = index(rr, '/');\n        if pp = 0 then do;\n          mn = t;\n        end;\n        else do;\n          ll = length(t);\n          mn = substr(t, ll-pp+2);\n        end;\n        table.loadTable result=r / caslib='ModelStore' casOut={caslib='ModelStore', name=mn} path=mn||'.sashdat';\n      end;\n    end;\n  end;\nend;\n\nif(fmtLibNames != \"null\") then action setFmtSearch status=status / fmtLibNames=fmtLibNames;\n\nif(inlineCode != \"null\") then action runDS2 / program=inlineCode;\n\nif(preprocessingCode != \"null\") then action runDS2 / program=preprocessingCode;\n\nif(find(mappedCode, 'http') == 1) then do;\n  code = '';\n  code = code || 'data xyz;';\n  code = code || '  declare int size;';\n  code = code || '  method init();';\n  code = code || '    declare package http h();';\n  code = code || '    declare package json j();';\n  code = code || '    declare varchar(10485760) character set utf8 body;';\n  code = code || '    dcl int internalTokenType internalParseFlags;';\n  code = code || '    dcl varchar(4000) internalToken;';\n  code = code || '    declare int rc;';\n  code = code || '    h.createGetMethod(''' || mappedCode || ''');';\n  code = code || '    h.addSASOauthToken();';\n  code = code || '    h.executeMethod();';\n  code = code || '    h.getResponseBodyAsString(body, rc);';\n  code = code || '    rc = j.createParser(body);';\n  code = code || '    do while (rc = 0);';\n  code = code || '      j.getNextToken(rc, internalToken, internalTokenType, internalParseFlags);';\n  code = code || '      if (internalToken eq ''size'') then do;';\n  code = code || '        j.getNextToken(rc, internalToken, internalTokenType, internalParseFlags);';\n  code = code || '        size = internalToken;';\n  code = code || '      end;';\n  code = code || '    end;';\n  code = code || '  end;';\n  code = code || 'enddata;';\n  action runDS2 / program=code;\n  table.fetch result=e index=FALSE sasTypes=FALSE table='xyz';\n  mappedCodeContentLength = (INT64)e['Fetch'][1]['size'];\n  table.dropTable name='xyz';\n\n  chunkSize = 10485760;\n  from = 0;\n  to = chunkSize-1;\n  do while (from < mappedCodeContentLength);\n    if to >= mappedCodeContentLength then\n      to = mappedCodeContentLength-1;\n\n    code = '';\n    code = code || 'data xyz;';\n    code = code || '  declare VARCHAR(' || chunkSize || ') character set utf8 body;';\n    code = code || '  method init();';\n    code = code || '    declare package http h();';\n    code = code || '    declare int rc;';\n    code = code || '    h.createGetMethod(''' || mappedCode || '/content'');';\n    code = code || '    h.addRequestHeader(''Range'', ''bytes=' || from || '-' || to || ''');';\n    code = code || '    h.addSASOauthToken();';\n    code = code || '    h.executeMethod();';\n    code = code || '    h.getResponseBodyAsString(body, rc);';\n    code = code || '  end;';\n    code = code || 'enddata;';\n    action runDS2 / program=code;\n    table.fetch result=e index=FALSE sasTypes=FALSE table='xyz';\n    mappedCodeFromRestAPI = mappedCodeFromRestAPI || e['Fetch'][1]['body'];\n    table.dropTable name='xyz';\n\n    from = to + 1;\n    to = to + chunkSize;\n  end;\n  mappedCode = mappedCodeFromRestAPI;\nend;\n\n\nif(astoreNames != \"null\") then action publishModel submit / modelTable={name=modelTableName, caslib=modelLibName} modelName=modelName program=mappedCode storeTables=storeTables;\nelse action publishModel submit / modelTable={name=modelTableName, caslib=modelLibName} modelName=modelName program=mappedCode;\n\nparmlist={\n  modelTable={\n    name=modelTableName,\n    caslib=modelLibName\n  },\n  modelName=modelName,\n  inTable={\n    name=inputTableName,\n    caslib=inputLibraryName\n  },\n  outTable={\n    name=outputTableName,\n    caslib=outputLibraryName\n  }\n};\naction runModelLocal submit / parmlist;\nrun;\n\naction promote / caslib=outputLibraryName, name=outputTableName, targetLib=outputLibraryName;\n\naction dropTable / caslib=outputLibraryName, name=modelTableName;\naction endSession;\n",
        "jobId": "58c39c14-2b35-4589-88c1-a10c3ad309ad",
        "jobRequestId": "ebbf704f-59f0-4f1a-8603-3d83574f15c0",
        "mappedCodeJobId": "e3c51767-9e11-4e8d-968b-432560b7e6bc",
        "reason_1": "ok",
        "severity_1": "error",
        "statusCode_1": "0",
        "status_1": ""
      },
      "scoreExecutionRequest": {
        "version": 1,
        "name": "Execution for Decision_Scenario",
        "hints": {
          "asyncMappedCode": "true",
          "inputLibraryName": "CASUSER(sasuser)",
          "inputTableName": "Scenario_8fc3a739_55a8_4057_9e0d_b5148dafa32a",
          "modelLib": "public",
          "modelTable": "4485f766-b13f-44b5-6a3b-a605e06a9eb3",
          "objectURI": "/decisions/flows/4672704b-aad4-4e2f-8b8e-64fd89fbe0ff/revisions/56b8939b-4224-425d-8211-0206188b4d60",
          "scoreRequestGuid": "2489a059-7564-400e-1f89-3f72721772f1",
          "useGlobalVariableCurrentValues": "true"
        },
        "type": "scoreDefinition",
        "scoreDefinitionId": "8fc3a739-55a8-4057-9e0d-b5148dafa32a"
      },
      "state": "failed",
      "version": 1
    }
    
    {
      "codeFileUri": "/files/files/a26709f1-efec-4eb8-a5eb-a9b3fe7715c2",
      "createdBy": "sasuser",
      "creationTimeStamp": "2021-12-22T22:01:24.90638Z",
      "id": "feed27ef-988f-4b6e-ba84-aa399c786253",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "type": "application/vnd.sas.score.execution"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253"
        },
        {
          "method": "GET",
          "rel": "analyses",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analyses",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analyses"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/state",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/state",
          "type": "text/plain"
        },
        {
          "method": "POST",
          "rel": "analysisCode",
          "href": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analysisCode",
          "uri": "/scoreExecution/executions/feed27ef-988f-4b6e-ba84-aa399c786253/analysisCode",
          "type": "application/vnd.sas.score.analysis.code.generation.request",
          "responseType": "application/vnd.sas.score.analysis.code"
        }
      ],
      "logFileUri": "/files/files/d56daac3-5411-4a8f-949c-f5a7cad4a643",
      "modifiedBy": "sasuser",
      "modifiedTimeStamp": "2021-12-22T22:01:31.360206Z",
      "outputTable": {
        "tableName": "Decision_Scenario_2021-12-22_22-01-24_output",
        "libraryName": "Public",
        "serverName": "cas-shared-default"
      },
      "results": {
        "debuginfo_1": "",
        "elapsedTime": "2574",
        "executedCode": "outputLibraryName=\"Public\";\noutputTableName=\"Decision_Scenario_2021-12-22_22-01-24_output\";\nmappedCode=\"http://sas-files/files/files/7d613eca-cad2-487e-bf12-22add29c59f5\";\ninputLibraryName=\"CASUSER(sasuser)\";\ninputTableName=\"Scenario_8fc3a739_55a8_4057_9e0d_b5148dafa32a\";\npreprocessingCode=\"null\";\ninlineCode=\"data \"\"CASUSER(sasuser)\"\".\"\"Scenario_8fc3a739_55a8_4057_9e0d_b5148dafa32a\"\"; dcl double foo; enddata;\";\nfmtLibNames=\"userformats3\";\nastoreNames=\"null\";\ncode = '';\nmappedCodeFromRestAPI = '';\nmodelLibName = outputLibraryName;\nmodelTableName = 'TempModel_' || uuidgen();\nmodelName = modelTableName;\nstoreTables = {};\n\nloadActionSet \"modelPublishing\";\nloadActionSet \"ds2\";\nloadActionSet \"table\";\n\naction dropTable / caslib=outputLibraryName, name=outputTableName, quiet=true;\n\nif(astoreNames != \"null\") then do;\n  count=0;\n  t='x';\n  do until (t = ' ');\n    count=count+1;\n    t=scan(astoreNames, count, ' ');\n    if (length(t)>3) then do;\n      table.tableExists result=e / caslib='ModelStore' name=t;\n      haveTable = dictionary(e, 'exists');\n      storeTables = storeTables + {{ caslib='ModelStore', name=t }};\n      if haveTable < 1 then do;\n        rr = reverse(t);\n        pp = index(rr, '/');\n        if pp = 0 then do;\n          mn = t;\n        end;\n        else do;\n          ll = length(t);\n          mn = substr(t, ll-pp+2);\n        end;\n        table.loadTable result=r / caslib='ModelStore' casOut={caslib='ModelStore', name=mn} path=mn||'.sashdat';\n      end;\n    end;\n  end;\nend;\n\nif(fmtLibNames != \"null\") then action setFmtSearch status=status / fmtLibNames=fmtLibNames;\n\nif(inlineCode != \"null\") then action runDS2 / program=inlineCode;\n\nif(preprocessingCode != \"null\") then action runDS2 / program=preprocessingCode;\n\nif(find(mappedCode, 'http') == 1) then do;\n  code = '';\n  code = code || 'data xyz;';\n  code = code || '  declare int size;';\n  code = code || '  method init();';\n  code = code || '    declare package http h();';\n  code = code || '    declare package json j();';\n  code = code || '    declare varchar(10485760) character set utf8 body;';\n  code = code || '    dcl int internalTokenType internalParseFlags;';\n  code = code || '    dcl varchar(4000) internalToken;';\n  code = code || '    declare int rc;';\n  code = code || '    h.createGetMethod(''' || mappedCode || ''');';\n  code = code || '    h.addSASOauthToken();';\n  code = code || '    h.executeMethod();';\n  code = code || '    h.getResponseBodyAsString(body, rc);';\n  code = code || '    rc = j.createParser(body);';\n  code = code || '    do while (rc = 0);';\n  code = code || '      j.getNextToken(rc, internalToken, internalTokenType, internalParseFlags);';\n  code = code || '      if (internalToken eq ''size'') then do;';\n  code = code || '        j.getNextToken(rc, internalToken, internalTokenType, internalParseFlags);';\n  code = code || '        size = internalToken;';\n  code = code || '      end;';\n  code = code || '    end;';\n  code = code || '  end;';\n  code = code || 'enddata;';\n  action runDS2 / program=code;\n  table.fetch result=e index=FALSE sasTypes=FALSE table='xyz';\n  mappedCodeContentLength = (INT64)e['Fetch'][1]['size'];\n  table.dropTable name='xyz';\n\n  chunkSize = 10485760;\n  from = 0;\n  to = chunkSize-1;\n  do while (from < mappedCodeContentLength);\n    if to >= mappedCodeContentLength then\n      to = mappedCodeContentLength-1;\n\n    code = '';\n    code = code || 'data xyz;';\n    code = code || '  declare VARCHAR(' || chunkSize || ') character set utf8 body;';\n    code = code || '  method init();';\n    code = code || '    declare package http h();';\n    code = code || '    declare int rc;';\n    code = code || '    h.createGetMethod(''' || mappedCode || '/content'');';\n    code = code || '    h.addRequestHeader(''Range'', ''bytes=' || from || '-' || to || ''');';\n    code = code || '    h.addSASOauthToken();';\n    code = code || '    h.executeMethod();';\n    code = code || '    h.getResponseBodyAsString(body, rc);';\n    code = code || '  end;';\n    code = code || 'enddata;';\n    action runDS2 / program=code;\n    table.fetch result=e index=FALSE sasTypes=FALSE table='xyz';\n    mappedCodeFromRestAPI = mappedCodeFromRestAPI || e['Fetch'][1]['body'];\n    table.dropTable name='xyz';\n\n    from = to + 1;\n    to = to + chunkSize;\n  end;\n  mappedCode = mappedCodeFromRestAPI;\nend;\n\n\nif(astoreNames != \"null\") then action publishModel submit / modelTable={name=modelTableName, caslib=modelLibName} modelName=modelName program=mappedCode storeTables=storeTables;\nelse action publishModel submit / modelTable={name=modelTableName, caslib=modelLibName} modelName=modelName program=mappedCode;\n\nparmlist={\n  modelTable={\n    name=modelTableName,\n    caslib=modelLibName\n  },\n  modelName=modelName,\n  inTable={\n    name=inputTableName,\n    caslib=inputLibraryName\n  },\n  outTable={\n    name=outputTableName,\n    caslib=outputLibraryName\n  }\n};\naction runModelLocal submit / parmlist;\nrun;\n\naction promote / caslib=outputLibraryName, name=outputTableName, targetLib=outputLibraryName;\n\naction dropTable / caslib=outputLibraryName, name=modelTableName;\naction endSession;\n",
        "jobId": "58c39c14-2b35-4589-88c1-a10c3ad309ad",
        "jobRequestId": "ebbf704f-59f0-4f1a-8603-3d83574f15c0",
        "mappedCodeJobId": "e3c51767-9e11-4e8d-968b-432560b7e6bc",
        "reason_1": "ok",
        "severity_1": "error",
        "statusCode_1": "0",
        "status_1": ""
      },
      "scoreExecutionRequest": {
        "version": 1,
        "name": "Execution for Decision_Scenario",
        "hints": {
          "asyncMappedCode": "true",
          "inputLibraryName": "CASUSER(sasuser)",
          "inputTableName": "Scenario_8fc3a739_55a8_4057_9e0d_b5148dafa32a",
          "modelLib": "public",
          "modelTable": "4485f766-b13f-44b5-6a3b-a605e06a9eb3",
          "objectURI": "/decisions/flows/4672704b-aad4-4e2f-8b8e-64fd89fbe0ff/revisions/56b8939b-4224-425d-8211-0206188b4d60",
          "scoreRequestGuid": "2489a059-7564-400e-1f89-3f72721772f1",
          "useGlobalVariableCurrentValues": "true"
        },
        "type": "scoreDefinition",
        "scoreDefinitionId": "8fc3a739-55a8-4057-9e0d-b5148dafa32a"
      },
      "state": "failed",
      "version": 1
    }
    

    404 Response

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. scoreExecutionCollection
    404 Not Found No score execution exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the score execution.
    200 Last-Modified string date-time The timestamp when the score execution was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Get the headers for a score execution

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/scoreExecution/executions/{executionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/scoreExecution/executions/{executionId}',
    {
      method: 'HEAD'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.head('https://example.com/scoreExecution/executions/{executionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/scoreExecution/executions/{executionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /executions/{executionId}

    Returns the headers for the specified score execution. Also used to determine whether a particular score execution exists.

    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the score execution.
    200 Last-Modified string date-time The timestamp when the score execution was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Delete a score execution

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/scoreExecution/executions/{executionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/scoreExecution/executions/{executionId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/scoreExecution/executions/{executionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/scoreExecution/executions/{executionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /executions/{executionId}

    Deletes the specified score execution.

    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.

    Example responses

    404 Response

    Responses
    Status Meaning Description Schema
    204 No Content The score execution was deleted. None
    404 Not Found No score execution exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a score execution state

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreExecution/executions/{executionId}/state \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/plain'
    
    
    
    const headers = {
      'Accept':'text/plain'
    };
    
    fetch('https://example.com/scoreExecution/executions/{executionId}/state',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/plain'
    }
    
    r = requests.get('https://example.com/scoreExecution/executions/{executionId}/state', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/plain"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreExecution/executions/{executionId}/state", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /executions/{executionId}/state

    Returns the state of the specified score execution.

    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.

    Example responses

    Score execution state

    "completed"
    

    404 Response

    {"httpStatusCode":404,"version":2}
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    404 Not Found No score execution exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Generate analysis code

    Code samples

    # You can also use wget
    curl -X POST https://example.com/scoreExecution/executions/{executionId}/analysisCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.analysis.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.analysis.code+json'
    
    
    const inputBody = '{
      "scoreExecutionId": "string",
      "analysisType": "string",
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept':'application/vnd.sas.score.analysis.code+json'
    };
    
    fetch('https://example.com/scoreExecution/executions/{executionId}/analysisCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.analysis.code+json'
    }
    
    r = requests.post('https://example.com/scoreExecution/executions/{executionId}/analysisCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.analysis.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.analysis.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/scoreExecution/executions/{executionId}/analysisCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /executions/{executionId}/analysisCode

    Generate analysis code for an analysis type from a score execution by forwarding the analysis code to the score object.

    Body parameter

    {
      "scoreExecutionId": "string",
      "analysisType": "string",
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }
    
    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.
    body body #/paths/~1executions~1%7BexecutionId%7D~1analysisCode/post/requestBody/content/application~1vnd.sas.score.analysis.code.generation.request%2Bjson/schema false The representation of an analysis code generation request.

    Example responses

    200 Response

    {
      "code": "/* ds2 code of an object which generates XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS",
      "analysisType": "ruleFiredSummary"
    }
    
    {
      "code": "/* ds2 code of an object which generates XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS",
      "analysisType": "ruleFiredSummary"
    }
    

    400 Response

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    404 Response

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No score execution exists at the requested path. Inline
    Response Schema

    Status Code 200

    Analysis Code

    Name Type Required Restrictions Description
    » code string true none Executable code generated by a Score Object.
    » codeType string(media-type) true none Type of the code.
    » outputTableName string true none Name of the table that will be generated when the generated code is executed.
    » outputLibraryName string true none Name of the library where the table will be generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 1.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Analyses

    Contains the operations to create, read, and delete analyses.

    Get a list of score analyses

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreExecution/executions/{executionId}/analyses \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/scoreExecution/executions/{executionId}/analyses',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/scoreExecution/executions/{executionId}/analyses', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreExecution/executions/{executionId}/analyses", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /executions/{executionId}/analyses

    Returns a list of score analyses based on the specified pagination, filtering, and sorting options. The items in the list depend on the Accept-Item header.

    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.
    Accept-Item header string(media-type) false Used for selecting desired item representation.
    start query integer(int64) false The index of the first score analysis to return.
    limit query integer(int32) false The maximum number of score analyses to return.
    filter query string(filter-criteria) false The criteria for filtering the score analyses. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the score analyses. See Sorting in REST APIs.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.score.analysis+json
    Accept-Item application/vnd.sas.summary+json

    Example responses

    200 Response

    {
      "accept": "application/vnd.sas.summary",
      "count": 2,
      "items": [
        {
          "createdBy": "edmdev",
          "creationTimeStamp": "2022-12-26T07:34:10.69495Z",
          "id": "1fc42c82-47de-415a-86ef-11a3a6b94330",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "type": "application/vnd.sas.score.analysis"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
              "type": "text/plain"
            }
          ],
          "modifiedBy": "edmdev",
          "modifiedTimeStamp": "2022-12-26T07:34:11.848218Z",
          "name": "ruleFiredDetails",
          "type": "scoreAnalysis",
          "version": 2
        },
        {
          "createdBy": "edmdev",
          "creationTimeStamp": "2022-12-26T07:34:15.857613Z",
          "id": "8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "type": "application/vnd.sas.score.analysis"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042/state",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042/state",
              "type": "text/plain"
            }
          ],
          "modifiedBy": "edmdev",
          "modifiedTimeStamp": "2022-12-26T07:34:17.258806Z",
          "name": "ruleFiredSummary",
          "type": "scoreAnalysis",
          "version": 2
        }
      ],
      "limit": 20,
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.score.analysis"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses?start=0&limit=20",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses?start=0&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "type": "application/vnd.sas.score.analysis.request",
          "responseType": "application/vnd.sas.score.analysis"
        }
      ],
      "name": "scoreAnalyses",
      "start": 0,
      "version": 2
    }
    
    {
      "accept": "application/vnd.sas.summary",
      "count": 2,
      "items": [
        {
          "createdBy": "edmdev",
          "creationTimeStamp": "2022-12-26T07:34:10.69495Z",
          "id": "1fc42c82-47de-415a-86ef-11a3a6b94330",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "type": "application/vnd.sas.score.analysis"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
              "type": "text/plain"
            }
          ],
          "modifiedBy": "edmdev",
          "modifiedTimeStamp": "2022-12-26T07:34:11.848218Z",
          "name": "ruleFiredDetails",
          "type": "scoreAnalysis",
          "version": 2
        },
        {
          "createdBy": "edmdev",
          "creationTimeStamp": "2022-12-26T07:34:15.857613Z",
          "id": "8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "type": "application/vnd.sas.score.analysis"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042"
            },
            {
              "method": "GET",
              "rel": "state",
              "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042/state",
              "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/8ef3db5b-a65c-4bd0-99c6-d9c5c8f4b042/state",
              "type": "text/plain"
            }
          ],
          "modifiedBy": "edmdev",
          "modifiedTimeStamp": "2022-12-26T07:34:17.258806Z",
          "name": "ruleFiredSummary",
          "type": "scoreAnalysis",
          "version": 2
        }
      ],
      "limit": 20,
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.score.analysis"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses?start=0&limit=20",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses?start=0&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "type": "application/vnd.sas.score.analysis.request",
          "responseType": "application/vnd.sas.score.analysis"
        }
      ],
      "name": "scoreAnalyses",
      "start": 0,
      "version": 2
    }
    

    400 Response

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. scoreAnalysisCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new score analysis

    Code samples

    # You can also use wget
    curl -X POST https://example.com/scoreExecution/executions/{executionId}/analyses \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/json' \
      -H 'Accept: application/vnd.sas.score.analysis+json'
    
    
    const inputBody = '{
      "scoreExecutionId": "string",
      "name": "string",
      "analysisType": "string",
      "description": "string",
      "hints": {
        "property1": "string",
        "property2": "string"
      },
      "jobDefinition": {
        "version": 0,
        "id": "string",
        "name": "string",
        "description": "string",
        "type": "string",
        "code": "string",
        "parameters": [
          {
            "version": 0,
            "name": "string",
            "type": "string",
            "label": "string",
            "required": true,
            "defaultValue": "string"
          }
        ],
        "properties": [
          {
            "name": "string",
            "value": "string"
          }
        ],
        "createdBy": "string",
        "modifiedBy": "string",
        "creationTimeStamp": "string",
        "modifiedTimeStamp": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ]
      },
      "jobDefinitionId": "string",
      "version": 0
    }';
    const headers = {
      'Content-Type':'application/json',
      'Accept':'application/vnd.sas.score.analysis+json'
    };
    
    fetch('https://example.com/scoreExecution/executions/{executionId}/analyses',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/json',
      'Accept': 'application/vnd.sas.score.analysis+json'
    }
    
    r = requests.post('https://example.com/scoreExecution/executions/{executionId}/analyses', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/json"},
            "Accept": []string{"application/vnd.sas.score.analysis+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/scoreExecution/executions/{executionId}/analyses", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /executions/{executionId}/analyses

    Creates a new score analysis based on the representation in the request body.

    Body parameter

    {
      "scoreExecutionId": "string",
      "name": "string",
      "analysisType": "string",
      "description": "string",
      "hints": {
        "property1": "string",
        "property2": "string"
      },
      "jobDefinition": {
        "version": 0,
        "id": "string",
        "name": "string",
        "description": "string",
        "type": "string",
        "code": "string",
        "parameters": [
          {
            "version": 0,
            "name": "string",
            "type": "string",
            "label": "string",
            "required": true,
            "defaultValue": "string"
          }
        ],
        "properties": [
          {
            "name": "string",
            "value": "string"
          }
        ],
        "createdBy": "string",
        "modifiedBy": "string",
        "creationTimeStamp": "string",
        "modifiedTimeStamp": "string",
        "links": [
          {
            "method": "string",
            "rel": "string",
            "uri": "string",
            "href": "string",
            "title": "string",
            "type": "string",
            "itemType": "string",
            "responseType": "string",
            "responseItemType": "string"
          }
        ]
      },
      "jobDefinitionId": "string",
      "version": 0
    }
    
    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.
    body body #/paths/~1executions~1%7BexecutionId%7D~1analyses/post/requestBody/content/application~1json/schema true The representation of a score analysis request.

    Example responses

    201 Response

    {
      "codeFileUri": "/files/files/0267d01f-4824-44e5-9abc-4ad3fb0a6414",
      "createdBy": "edmdev",
      "creationTimeStamp": "2022-12-26T07:34:10.69495Z",
      "id": "1fc42c82-47de-415a-86ef-11a3a6b94330",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "type": "application/vnd.sas.score.analysis"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
          "type": "text/plain"
        }
      ],
      "logFileUri": "/files/files/7494ca81-f2a2-44b7-aa41-49b9d01f05db",
      "modifiedBy": "edmdev",
      "modifiedTimeStamp": "2022-12-26T07:34:11.848218Z",
      "outputTable": {
        "tableName": "d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired",
        "libraryName": "Public",
        "serverName": "cas-shared-default"
      },
      "results": {
        "debuginfo_1": "",
        "elapsedTime": "1036",
        "executedCode": "outputLibraryName=\"Public\";\noutputTableName=\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired\";\nanalysisCode=\"\n\n/* decision rule fired detail*/\nthread dcm_rf_detail_thread / inline;\n  dcl varchar(100)  \"\"DECISION_NAME\"\";\n  dcl char(36)      \"\"DECISION_ID\"\";\n  dcl char(36)      \"\"DECISION_VERSION_ID\"\";\n  dcl varchar(100)  \"\"RULE_NM\"\";\n  dcl varchar(100)  \"\"RULE_SET_NM\"\";\n  dcl char(36)      \"\"RULE_SET_ID\"\";\n  dcl varchar(100)  \"\"RULE_SET_VERSION\"\";\n  dcl char(36)      \"\"RULE_SET_VERSION_ID\"\";\n  dcl char(36)      \"\"RULE_ID\"\";\n  dcl varchar(0)      \"\"NODE_ID\"\";\n  dcl char(36)      \"\"rule_action_fire_id\"\";\n  dcl integer       \"\"ruleFiredSequence\"\";\n\n  dcl package hash  ruleFireFlagOffsetHash;\n  dcl package hiter ruleFiredHashIterator;\n  dcl integer       ruleFiredFlagPosition;\n\n  keep \"\"decision_name\"\" \"\"decision_id\"\" \"\"decision_version_id\"\"\n       \"\"rule_action_fire_id\"\" \"\"RULE_NM\"\" \"\"RULE_SET_ID\"\" \"\"RULE_SET_VERSION_ID\"\"\n       \"\"RULE_SET_NM\"\" \"\"NODE_ID\"\" \"\"RULE_ID\"\" \"\"ruleFiredSequence\"\" \"\"_recordCorrelationKey\"\";\n\n  retain \"\"DECISION_NAME\"\";\n  retain \"\"DECISION_ID\"\"         '18a63cf2-c51e-41d0-8fee-2ac4eb134844';\n  retain \"\"DECISION_VERSION_ID\"\" '676f5d0f-bc32-4c75-972e-cc122b45684b';\n\n  method init(); \n    ruleFireFlagOffsetHash = _new_ [this] hash();\n    ruleFireFlagOffsetHash.keys([RULE_ID NODE_ID]);\n    ruleFireFlagOffsetHash.data([RULE_ID NODE_ID ruleFiredFlagPosition RULE_NM RULE_SET_ID RULE_SET_VERSION_ID RULE_SET_NM]);\n    ruleFireFlagOffsetHash.defineDone();\n    ruleFiredFlagPosition = 1;\n    \"\"DECISION_NAME\"\"='d_single_treatment_group';\n\n    ruleFiredHashIterator = _new_ hiter('ruleFireFlagOffsetHash');\n  end;\n\n  method run();\n    dcl double rfLen;   \n    set \"\"Public\"\".\"\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_output\"\" \n      (keep=(\"\"rulesfiredforrecordcount\"\" \"\"_recordCorrelationKey\"\" \"\"ruleFiredFlags\"\"));\n\n    if \"\"rulesfiredforrecordcount\"\" > 0 then do;\n\n      rfLen = lengthc(\"\"ruleFiredFlags\"\");\n      ruleFiredHashIterator.first();\n      do until (ruleFiredHashIterator.next());\n        if ruleFiredFlagPosition > 0 and ruleFiredFlagPosition <= rfLen then do;\n          if (substr(\"\"ruleFiredFlags\"\",ruleFiredFlagPosition,1) = '1') then do;\n            \"\"rule_action_fire_id\"\"=uuidgen();\n            \"\"ruleFiredSequence\"\" = ruleFiredFlagPosition;\n            output ;\n          end;\n        end;\n      end;\n\n    end;\n  end;\n\n  method term();\n    ruleFiredHashIterator.delete();\n    rulefireFlagoffsethash.delete();\n  end;\nendthread;\n\ndata \"\"Public\"\".\"\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired\"\" (overwrite=yes) ;\n  dcl thread dcm_rf_detail_thread _t;\n\n  method run();\n    set from _t ;\n    output;\n  end;\nenddata;\n\";\ninputLibraryName=\"Public\";\ninputTableName=\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_output\";\nmodelLibName = outputLibraryName;\nmodelTableName = 'TempModel_' || uuidgen();\nmodelName = modelTableName;\n\nloadActionSet \"modelPublishing\";\nloadActionSet \"ds2\";\nloadActionSet \"table\";\n\naction publishModel submit / modelTable={name=modelTableName, caslib=modelLibName} modelName=modelName program=analysisCode;\n\nparmlist={\n  modelTable={\n    name=modelTableName,\n    caslib=modelLibName\n  },\n  modelName=modelName,\n  inTable={\n    name=inputTableName,\n    caslib=inputLibraryName\n  },\n  outTable={\n    name=outputTableName,\n    caslib=outputLibraryName\n  }\n};\naction runModelLocal submit / parmlist;\nrun;\n\naction promote / caslib=outputLibraryName, name=outputTableName, targetLib=outputLibraryName;\n\naction dropTable / caslib=outputLibraryName, name=modelTableName;\naction endSession;\n",
        "jobId": "c21c592e-8294-41d7-99f9-75116ae4c3ba",
        "reason_1": "ok",
        "severity_1": "error",
        "statusCode_1": "0",
        "status_1": ""
      },
      "scoreAnalysisRequest": {
        "version": 1,
        "scoreExecutionId": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
        "name": "ruleFiredDetails",
        "hints": {
          "modelLib": "public",
          "modelName": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
          "modelTable": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7"
        },
        "analysisType": "ruleFiredDetails"
      },
      "scoreExecutionId": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
      "state": "failed",
      "version": 1
    }
    
    {
      "codeFileUri": "/files/files/0267d01f-4824-44e5-9abc-4ad3fb0a6414",
      "createdBy": "edmdev",
      "creationTimeStamp": "2022-12-26T07:34:10.69495Z",
      "id": "1fc42c82-47de-415a-86ef-11a3a6b94330",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "type": "application/vnd.sas.score.analysis"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
          "type": "text/plain"
        }
      ],
      "logFileUri": "/files/files/7494ca81-f2a2-44b7-aa41-49b9d01f05db",
      "modifiedBy": "edmdev",
      "modifiedTimeStamp": "2022-12-26T07:34:11.848218Z",
      "outputTable": {
        "tableName": "d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired",
        "libraryName": "Public",
        "serverName": "cas-shared-default"
      },
      "results": {
        "debuginfo_1": "",
        "elapsedTime": "1036",
        "executedCode": "outputLibraryName=\"Public\";\noutputTableName=\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired\";\nanalysisCode=\"\n\n/* decision rule fired detail*/\nthread dcm_rf_detail_thread / inline;\n  dcl varchar(100)  \"\"DECISION_NAME\"\";\n  dcl char(36)      \"\"DECISION_ID\"\";\n  dcl char(36)      \"\"DECISION_VERSION_ID\"\";\n  dcl varchar(100)  \"\"RULE_NM\"\";\n  dcl varchar(100)  \"\"RULE_SET_NM\"\";\n  dcl char(36)      \"\"RULE_SET_ID\"\";\n  dcl varchar(100)  \"\"RULE_SET_VERSION\"\";\n  dcl char(36)      \"\"RULE_SET_VERSION_ID\"\";\n  dcl char(36)      \"\"RULE_ID\"\";\n  dcl varchar(0)      \"\"NODE_ID\"\";\n  dcl char(36)      \"\"rule_action_fire_id\"\";\n  dcl integer       \"\"ruleFiredSequence\"\";\n\n  dcl package hash  ruleFireFlagOffsetHash;\n  dcl package hiter ruleFiredHashIterator;\n  dcl integer       ruleFiredFlagPosition;\n\n  keep \"\"decision_name\"\" \"\"decision_id\"\" \"\"decision_version_id\"\"\n       \"\"rule_action_fire_id\"\" \"\"RULE_NM\"\" \"\"RULE_SET_ID\"\" \"\"RULE_SET_VERSION_ID\"\"\n       \"\"RULE_SET_NM\"\" \"\"NODE_ID\"\" \"\"RULE_ID\"\" \"\"ruleFiredSequence\"\" \"\"_recordCorrelationKey\"\";\n\n  retain \"\"DECISION_NAME\"\";\n  retain \"\"DECISION_ID\"\"         '18a63cf2-c51e-41d0-8fee-2ac4eb134844';\n  retain \"\"DECISION_VERSION_ID\"\" '676f5d0f-bc32-4c75-972e-cc122b45684b';\n\n  method init(); \n    ruleFireFlagOffsetHash = _new_ [this] hash();\n    ruleFireFlagOffsetHash.keys([RULE_ID NODE_ID]);\n    ruleFireFlagOffsetHash.data([RULE_ID NODE_ID ruleFiredFlagPosition RULE_NM RULE_SET_ID RULE_SET_VERSION_ID RULE_SET_NM]);\n    ruleFireFlagOffsetHash.defineDone();\n    ruleFiredFlagPosition = 1;\n    \"\"DECISION_NAME\"\"='d_single_treatment_group';\n\n    ruleFiredHashIterator = _new_ hiter('ruleFireFlagOffsetHash');\n  end;\n\n  method run();\n    dcl double rfLen;   \n    set \"\"Public\"\".\"\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_output\"\" \n      (keep=(\"\"rulesfiredforrecordcount\"\" \"\"_recordCorrelationKey\"\" \"\"ruleFiredFlags\"\"));\n\n    if \"\"rulesfiredforrecordcount\"\" > 0 then do;\n\n      rfLen = lengthc(\"\"ruleFiredFlags\"\");\n      ruleFiredHashIterator.first();\n      do until (ruleFiredHashIterator.next());\n        if ruleFiredFlagPosition > 0 and ruleFiredFlagPosition <= rfLen then do;\n          if (substr(\"\"ruleFiredFlags\"\",ruleFiredFlagPosition,1) = '1') then do;\n            \"\"rule_action_fire_id\"\"=uuidgen();\n            \"\"ruleFiredSequence\"\" = ruleFiredFlagPosition;\n            output ;\n          end;\n        end;\n      end;\n\n    end;\n  end;\n\n  method term();\n    ruleFiredHashIterator.delete();\n    rulefireFlagoffsethash.delete();\n  end;\nendthread;\n\ndata \"\"Public\"\".\"\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired\"\" (overwrite=yes) ;\n  dcl thread dcm_rf_detail_thread _t;\n\n  method run();\n    set from _t ;\n    output;\n  end;\nenddata;\n\";\ninputLibraryName=\"Public\";\ninputTableName=\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_output\";\nmodelLibName = outputLibraryName;\nmodelTableName = 'TempModel_' || uuidgen();\nmodelName = modelTableName;\n\nloadActionSet \"modelPublishing\";\nloadActionSet \"ds2\";\nloadActionSet \"table\";\n\naction publishModel submit / modelTable={name=modelTableName, caslib=modelLibName} modelName=modelName program=analysisCode;\n\nparmlist={\n  modelTable={\n    name=modelTableName,\n    caslib=modelLibName\n  },\n  modelName=modelName,\n  inTable={\n    name=inputTableName,\n    caslib=inputLibraryName\n  },\n  outTable={\n    name=outputTableName,\n    caslib=outputLibraryName\n  }\n};\naction runModelLocal submit / parmlist;\nrun;\n\naction promote / caslib=outputLibraryName, name=outputTableName, targetLib=outputLibraryName;\n\naction dropTable / caslib=outputLibraryName, name=modelTableName;\naction endSession;\n",
        "jobId": "c21c592e-8294-41d7-99f9-75116ae4c3ba",
        "reason_1": "ok",
        "severity_1": "error",
        "statusCode_1": "0",
        "status_1": ""
      },
      "scoreAnalysisRequest": {
        "version": 1,
        "scoreExecutionId": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
        "name": "ruleFiredDetails",
        "hints": {
          "modelLib": "public",
          "modelName": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
          "modelTable": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7"
        },
        "analysisType": "ruleFiredDetails"
      },
      "scoreExecutionId": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
      "state": "failed",
      "version": 1
    }
    

    400 Response

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A score analysis was created. scoreAnalysisCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string uri The URL of the score analysis.
    201 ETag string The entity tag for the score analysis.
    201 Last-Modified string date-time The timestamp when the score analysis was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Get a score analysis

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.score.analysis+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.score.analysis+json'
    };
    
    fetch('https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.score.analysis+json'
    }
    
    r = requests.get('https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.score.analysis+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /executions/{executionId}/analyses/{analysisId}

    Returns the representation of the specified score analysis.

    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.
    analysisId path string true The unique identifier for the score analysis.

    Example responses

    200 Response

    {
      "codeFileUri": "/files/files/0267d01f-4824-44e5-9abc-4ad3fb0a6414",
      "createdBy": "edmdev",
      "creationTimeStamp": "2022-12-26T07:34:10.69495Z",
      "id": "1fc42c82-47de-415a-86ef-11a3a6b94330",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "type": "application/vnd.sas.score.analysis"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
          "type": "text/plain"
        }
      ],
      "logFileUri": "/files/files/7494ca81-f2a2-44b7-aa41-49b9d01f05db",
      "modifiedBy": "edmdev",
      "modifiedTimeStamp": "2022-12-26T07:34:11.848218Z",
      "outputTable": {
        "tableName": "d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired",
        "libraryName": "Public",
        "serverName": "cas-shared-default"
      },
      "results": {
        "debuginfo_1": "",
        "elapsedTime": "1036",
        "executedCode": "outputLibraryName=\"Public\";\noutputTableName=\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired\";\nanalysisCode=\"\n\n/* decision rule fired detail*/\nthread dcm_rf_detail_thread / inline;\n  dcl varchar(100)  \"\"DECISION_NAME\"\";\n  dcl char(36)      \"\"DECISION_ID\"\";\n  dcl char(36)      \"\"DECISION_VERSION_ID\"\";\n  dcl varchar(100)  \"\"RULE_NM\"\";\n  dcl varchar(100)  \"\"RULE_SET_NM\"\";\n  dcl char(36)      \"\"RULE_SET_ID\"\";\n  dcl varchar(100)  \"\"RULE_SET_VERSION\"\";\n  dcl char(36)      \"\"RULE_SET_VERSION_ID\"\";\n  dcl char(36)      \"\"RULE_ID\"\";\n  dcl varchar(0)      \"\"NODE_ID\"\";\n  dcl char(36)      \"\"rule_action_fire_id\"\";\n  dcl integer       \"\"ruleFiredSequence\"\";\n\n  dcl package hash  ruleFireFlagOffsetHash;\n  dcl package hiter ruleFiredHashIterator;\n  dcl integer       ruleFiredFlagPosition;\n\n  keep \"\"decision_name\"\" \"\"decision_id\"\" \"\"decision_version_id\"\"\n       \"\"rule_action_fire_id\"\" \"\"RULE_NM\"\" \"\"RULE_SET_ID\"\" \"\"RULE_SET_VERSION_ID\"\"\n       \"\"RULE_SET_NM\"\" \"\"NODE_ID\"\" \"\"RULE_ID\"\" \"\"ruleFiredSequence\"\" \"\"_recordCorrelationKey\"\";\n\n  retain \"\"DECISION_NAME\"\";\n  retain \"\"DECISION_ID\"\"         '18a63cf2-c51e-41d0-8fee-2ac4eb134844';\n  retain \"\"DECISION_VERSION_ID\"\" '676f5d0f-bc32-4c75-972e-cc122b45684b';\n\n  method init(); \n    ruleFireFlagOffsetHash = _new_ [this] hash();\n    ruleFireFlagOffsetHash.keys([RULE_ID NODE_ID]);\n    ruleFireFlagOffsetHash.data([RULE_ID NODE_ID ruleFiredFlagPosition RULE_NM RULE_SET_ID RULE_SET_VERSION_ID RULE_SET_NM]);\n    ruleFireFlagOffsetHash.defineDone();\n    ruleFiredFlagPosition = 1;\n    \"\"DECISION_NAME\"\"='d_single_treatment_group';\n\n    ruleFiredHashIterator = _new_ hiter('ruleFireFlagOffsetHash');\n  end;\n\n  method run();\n    dcl double rfLen;   \n    set \"\"Public\"\".\"\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_output\"\" \n      (keep=(\"\"rulesfiredforrecordcount\"\" \"\"_recordCorrelationKey\"\" \"\"ruleFiredFlags\"\"));\n\n    if \"\"rulesfiredforrecordcount\"\" > 0 then do;\n\n      rfLen = lengthc(\"\"ruleFiredFlags\"\");\n      ruleFiredHashIterator.first();\n      do until (ruleFiredHashIterator.next());\n        if ruleFiredFlagPosition > 0 and ruleFiredFlagPosition <= rfLen then do;\n          if (substr(\"\"ruleFiredFlags\"\",ruleFiredFlagPosition,1) = '1') then do;\n            \"\"rule_action_fire_id\"\"=uuidgen();\n            \"\"ruleFiredSequence\"\" = ruleFiredFlagPosition;\n            output ;\n          end;\n        end;\n      end;\n\n    end;\n  end;\n\n  method term();\n    ruleFiredHashIterator.delete();\n    rulefireFlagoffsethash.delete();\n  end;\nendthread;\n\ndata \"\"Public\"\".\"\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired\"\" (overwrite=yes) ;\n  dcl thread dcm_rf_detail_thread _t;\n\n  method run();\n    set from _t ;\n    output;\n  end;\nenddata;\n\";\ninputLibraryName=\"Public\";\ninputTableName=\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_output\";\nmodelLibName = outputLibraryName;\nmodelTableName = 'TempModel_' || uuidgen();\nmodelName = modelTableName;\n\nloadActionSet \"modelPublishing\";\nloadActionSet \"ds2\";\nloadActionSet \"table\";\n\naction publishModel submit / modelTable={name=modelTableName, caslib=modelLibName} modelName=modelName program=analysisCode;\n\nparmlist={\n  modelTable={\n    name=modelTableName,\n    caslib=modelLibName\n  },\n  modelName=modelName,\n  inTable={\n    name=inputTableName,\n    caslib=inputLibraryName\n  },\n  outTable={\n    name=outputTableName,\n    caslib=outputLibraryName\n  }\n};\naction runModelLocal submit / parmlist;\nrun;\n\naction promote / caslib=outputLibraryName, name=outputTableName, targetLib=outputLibraryName;\n\naction dropTable / caslib=outputLibraryName, name=modelTableName;\naction endSession;\n",
        "jobId": "c21c592e-8294-41d7-99f9-75116ae4c3ba",
        "reason_1": "ok",
        "severity_1": "error",
        "statusCode_1": "0",
        "status_1": ""
      },
      "scoreAnalysisRequest": {
        "version": 1,
        "scoreExecutionId": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
        "name": "ruleFiredDetails",
        "hints": {
          "modelLib": "public",
          "modelName": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
          "modelTable": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7"
        },
        "analysisType": "ruleFiredDetails"
      },
      "scoreExecutionId": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
      "state": "failed",
      "version": 1
    }
    
    {
      "codeFileUri": "/files/files/0267d01f-4824-44e5-9abc-4ad3fb0a6414",
      "createdBy": "edmdev",
      "creationTimeStamp": "2022-12-26T07:34:10.69495Z",
      "id": "1fc42c82-47de-415a-86ef-11a3a6b94330",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "type": "application/vnd.sas.score.analysis"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
          "uri": "/scoreExecution/executions/c35f3134-64ad-49f5-b031-e5f4b5bc9ef7/analyses/1fc42c82-47de-415a-86ef-11a3a6b94330/state",
          "type": "text/plain"
        }
      ],
      "logFileUri": "/files/files/7494ca81-f2a2-44b7-aa41-49b9d01f05db",
      "modifiedBy": "edmdev",
      "modifiedTimeStamp": "2022-12-26T07:34:11.848218Z",
      "outputTable": {
        "tableName": "d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired",
        "libraryName": "Public",
        "serverName": "cas-shared-default"
      },
      "results": {
        "debuginfo_1": "",
        "elapsedTime": "1036",
        "executedCode": "outputLibraryName=\"Public\";\noutputTableName=\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired\";\nanalysisCode=\"\n\n/* decision rule fired detail*/\nthread dcm_rf_detail_thread / inline;\n  dcl varchar(100)  \"\"DECISION_NAME\"\";\n  dcl char(36)      \"\"DECISION_ID\"\";\n  dcl char(36)      \"\"DECISION_VERSION_ID\"\";\n  dcl varchar(100)  \"\"RULE_NM\"\";\n  dcl varchar(100)  \"\"RULE_SET_NM\"\";\n  dcl char(36)      \"\"RULE_SET_ID\"\";\n  dcl varchar(100)  \"\"RULE_SET_VERSION\"\";\n  dcl char(36)      \"\"RULE_SET_VERSION_ID\"\";\n  dcl char(36)      \"\"RULE_ID\"\";\n  dcl varchar(0)      \"\"NODE_ID\"\";\n  dcl char(36)      \"\"rule_action_fire_id\"\";\n  dcl integer       \"\"ruleFiredSequence\"\";\n\n  dcl package hash  ruleFireFlagOffsetHash;\n  dcl package hiter ruleFiredHashIterator;\n  dcl integer       ruleFiredFlagPosition;\n\n  keep \"\"decision_name\"\" \"\"decision_id\"\" \"\"decision_version_id\"\"\n       \"\"rule_action_fire_id\"\" \"\"RULE_NM\"\" \"\"RULE_SET_ID\"\" \"\"RULE_SET_VERSION_ID\"\"\n       \"\"RULE_SET_NM\"\" \"\"NODE_ID\"\" \"\"RULE_ID\"\" \"\"ruleFiredSequence\"\" \"\"_recordCorrelationKey\"\";\n\n  retain \"\"DECISION_NAME\"\";\n  retain \"\"DECISION_ID\"\"         '18a63cf2-c51e-41d0-8fee-2ac4eb134844';\n  retain \"\"DECISION_VERSION_ID\"\" '676f5d0f-bc32-4c75-972e-cc122b45684b';\n\n  method init(); \n    ruleFireFlagOffsetHash = _new_ [this] hash();\n    ruleFireFlagOffsetHash.keys([RULE_ID NODE_ID]);\n    ruleFireFlagOffsetHash.data([RULE_ID NODE_ID ruleFiredFlagPosition RULE_NM RULE_SET_ID RULE_SET_VERSION_ID RULE_SET_NM]);\n    ruleFireFlagOffsetHash.defineDone();\n    ruleFiredFlagPosition = 1;\n    \"\"DECISION_NAME\"\"='d_single_treatment_group';\n\n    ruleFiredHashIterator = _new_ hiter('ruleFireFlagOffsetHash');\n  end;\n\n  method run();\n    dcl double rfLen;   \n    set \"\"Public\"\".\"\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_output\"\" \n      (keep=(\"\"rulesfiredforrecordcount\"\" \"\"_recordCorrelationKey\"\" \"\"ruleFiredFlags\"\"));\n\n    if \"\"rulesfiredforrecordcount\"\" > 0 then do;\n\n      rfLen = lengthc(\"\"ruleFiredFlags\"\");\n      ruleFiredHashIterator.first();\n      do until (ruleFiredHashIterator.next());\n        if ruleFiredFlagPosition > 0 and ruleFiredFlagPosition <= rfLen then do;\n          if (substr(\"\"ruleFiredFlags\"\",ruleFiredFlagPosition,1) = '1') then do;\n            \"\"rule_action_fire_id\"\"=uuidgen();\n            \"\"ruleFiredSequence\"\" = ruleFiredFlagPosition;\n            output ;\n          end;\n        end;\n      end;\n\n    end;\n  end;\n\n  method term();\n    ruleFiredHashIterator.delete();\n    rulefireFlagoffsethash.delete();\n  end;\nendthread;\n\ndata \"\"Public\"\".\"\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_ruleFired\"\" (overwrite=yes) ;\n  dcl thread dcm_rf_detail_thread _t;\n\n  method run();\n    set from _t ;\n    output;\n  end;\nenddata;\n\";\ninputLibraryName=\"Public\";\ninputTableName=\"d_single_treatment_group_Test_1_d_single_treatment_group_2022-12-26_07-33-38_output\";\nmodelLibName = outputLibraryName;\nmodelTableName = 'TempModel_' || uuidgen();\nmodelName = modelTableName;\n\nloadActionSet \"modelPublishing\";\nloadActionSet \"ds2\";\nloadActionSet \"table\";\n\naction publishModel submit / modelTable={name=modelTableName, caslib=modelLibName} modelName=modelName program=analysisCode;\n\nparmlist={\n  modelTable={\n    name=modelTableName,\n    caslib=modelLibName\n  },\n  modelName=modelName,\n  inTable={\n    name=inputTableName,\n    caslib=inputLibraryName\n  },\n  outTable={\n    name=outputTableName,\n    caslib=outputLibraryName\n  }\n};\naction runModelLocal submit / parmlist;\nrun;\n\naction promote / caslib=outputLibraryName, name=outputTableName, targetLib=outputLibraryName;\n\naction dropTable / caslib=outputLibraryName, name=modelTableName;\naction endSession;\n",
        "jobId": "c21c592e-8294-41d7-99f9-75116ae4c3ba",
        "reason_1": "ok",
        "severity_1": "error",
        "statusCode_1": "0",
        "status_1": ""
      },
      "scoreAnalysisRequest": {
        "version": 1,
        "scoreExecutionId": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
        "name": "ruleFiredDetails",
        "hints": {
          "modelLib": "public",
          "modelName": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
          "modelTable": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7"
        },
        "analysisType": "ruleFiredDetails"
      },
      "scoreExecutionId": "c35f3134-64ad-49f5-b031-e5f4b5bc9ef7",
      "state": "failed",
      "version": 1
    }
    

    404 Response

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. scoreAnalysisCollection
    404 Not Found No score analysis exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the score analysis.
    200 Last-Modified string date-time The timestamp when the score analysis was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Get the headers for a score analysis

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}',
    {
      method: 'HEAD'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.head('https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /executions/{executionId}/analyses/{analysisId}

    Returns the headers for the specified score analysis. Also used to determine whether a particular score analysis exists.

    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.
    analysisId path string true The unique identifier for the score analysis.
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found No score analysis exists at the requested path. None
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the score analysis.
    200 Last-Modified string date-time The timestamp when the score analysis was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Delete a score analysis

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: */*'
    
    
    
    const headers = {
      'Accept':'*/*'
    };
    
    fetch('https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': '*/*'
    }
    
    r = requests.delete('https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"*/*"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /executions/{executionId}/analyses/{analysisId}

    Deletes the specified score analysis.

    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.
    analysisId path string true The unique identifier for the score analysis.

    Example responses

    404 Response

    Responses
    Status Meaning Description Schema
    204 No Content The score analysis was deleted. None
    404 Not Found No score analysis exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get a score analysis state

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}/state \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/plain'
    
    
    
    const headers = {
      'Accept':'text/plain'
    };
    
    fetch('https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}/state',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/plain'
    }
    
    r = requests.get('https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}/state', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/plain"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreExecution/executions/{executionId}/analyses/{analysisId}/state", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /executions/{executionId}/analyses/{analysisId}/state

    Returns the state of the specified score analysis.

    Parameters
    Name In Type Required Description
    executionId path string true The unique identifier for the score execution.
    analysisId path string true The unique identifier for the score analysis.

    Example responses

    Score execution state

    "completed"
    

    404 Response

    {"httpStatusCode":404,"version":2}
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    404 Not Found No score execution exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Schemas

    scoreExecutionCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "scoreExecutionRequest": {
            "type": "scoreDefinition",
            "name": "string",
            "description": "string",
            "hints": {
              "property1": "string",
              "property2": "string"
            },
            "jobDefinition": {
              "version": 0,
              "id": "string",
              "name": "string",
              "description": "string",
              "type": "string",
              "code": "string",
              "parameters": [
                {
                  "version": 0,
                  "name": "string",
                  "type": "string",
                  "label": "string",
                  "required": true,
                  "defaultValue": "string"
                }
              ],
              "properties": [
                {
                  "name": "string",
                  "value": "string"
                }
              ],
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "string",
              "modifiedTimeStamp": "string",
              "links": [
                {
                  "method": "string",
                  "rel": "string",
                  "uri": "string",
                  "href": "string",
                  "title": "string",
                  "type": "string",
                  "itemType": "string",
                  "responseType": "string",
                  "responseItemType": "string"
                }
              ]
            },
            "jobDefinitionId": "string",
            "scoreDefinition": {
              "id": "string",
              "name": "string",
              "description": "string",
              "createdBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedBy": "string",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "preprocessingCode": "string",
              "objectDescriptor": {
                "name": "string",
                "type": "string",
                "uri": "https://example.com"
              },
              "inputData": {
                "type": "CASTable",
                "serverName": "string",
                "libraryName": "string",
                "tableName": "string",
                "code": "string",
                "outputTableName": "string"
              },
              "mappings": [
                {
                  "variableName": "string",
                  "mappingType": "datasource",
                  "mappingValue": 0
                }
              ],
              "properties": {
                "property1": "string",
                "property2": "string"
              },
              "folderType": "string",
              "links": [
                {
                  "method": "string",
                  "rel": "string",
                  "uri": "string",
                  "href": "string",
                  "title": "string",
                  "type": "string",
                  "itemType": "string",
                  "responseType": "string",
                  "responseItemType": "string"
                }
              ],
              "version": 0
            },
            "scoreDefinitionId": "string",
            "overrideScoreDefinition": {
              "preprocessingCode": "string",
              "objectDescriptor": {
                "name": "string",
                "type": "string",
                "uri": "https://example.com"
              },
              "inputData": {
                "type": "CASTable",
                "serverName": "string",
                "libraryName": "string",
                "tableName": "string",
                "code": "string",
                "outputTableName": "string"
              },
              "mappings": [
                {
                  "variableName": "string",
                  "mappingType": "datasource",
                  "mappingValue": 0
                }
              ]
            },
            "mappedCode": "string",
            "mappedCodeUri": "string",
            "outputTable": {
              "tableName": "string",
              "libraryName": "string",
              "serverName": "string"
            },
            "version": 0
          },
          "state": "pending",
          "outputTable": {
            "tableName": "string",
            "libraryName": "string",
            "serverName": "string"
          },
          "codeFileUri": "string",
          "logFileUri": "string",
          "haveWarnings": true,
          "error": {
            "message": "string",
            "id": "string",
            "errorCode": 0,
            "httpStatusCode": 0,
            "details": [
              "string"
            ],
            "remediation": "string",
            "errors": [
              null
            ],
            "links": [
              {
                "method": "string",
                "rel": "string",
                "uri": "string",
                "href": "string",
                "title": "string",
                "type": "string",
                "itemType": "string",
                "responseType": "string",
                "responseItemType": "string"
              }
            ],
            "version": 0
          },
          "results": {
            "property1": "string",
            "property2": "string"
          },
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    
    

    Score Execution Collection

    Properties
    Name Type Required Restrictions Description
    Score Execution Collection any false none One page of score execution representations, with optional links to first, prev, next, and last page of the list.

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [object] false none The links that apply to the collection.
    »» Link object false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none Array consisting of one page of score execution resources.
    »» Score Execution object false none Contains details about execution results. This represents application/vnd.sas.score.execution media type (version 1).
    »»» id string false none The system-assigned unique ID for this object
    »»» createdBy string false none The user who created the score execution.
    »»» creationTimeStamp string(date-time) false none The date and time that the score execution was created.
    »»» modifiedBy string false none The userId of the authenticated user who last updated the score execution.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the score execution was last modified.
    »»» scoreExecutionRequest #/paths/~1executions/post/requestBody/content/application~1json/schema true none Contains request details about how to generate score. This represents application/vnd.sas.score.execution.request media type (version 1).
    »»» state string(enumeration) true none State of the score execution.
    »»» outputTable object false none Output generated by score execution or analysis. This doesn't represent any top-level media type.
    »»»» tableName string true none Table name where the score execution or analysis output is saved.
    »»»» libraryName string true none Library where the table is located.
    »»»» serverName string true none Server where the table is located.
    »»» codeFileUri string false none File uri where the code used to generate score is saved.
    »»» logFileUri string false none File uri where the log of the score execution is saved.
    »»» haveWarnings boolean false none Set to true when there are warnings inside the log file.
    »»» error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» results object false none Contains results for the score execution.
    »»»» additionalProperties string false none none
    »»» links [link] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    state pending
    state running
    state canceled
    state completed
    state failed
    state timedOut

    scoreAnalysisCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "scoreExecutionId": "string",
          "scoreAnalysisRequest": {
            "scoreExecutionId": "string",
            "name": "string",
            "analysisType": "string",
            "description": "string",
            "hints": {
              "property1": "string",
              "property2": "string"
            },
            "jobDefinition": {
              "version": 0,
              "id": "string",
              "name": "string",
              "description": "string",
              "type": "string",
              "code": "string",
              "parameters": [
                {
                  "version": 0,
                  "name": "string",
                  "type": "string",
                  "label": "string",
                  "required": true,
                  "defaultValue": "string"
                }
              ],
              "properties": [
                {
                  "name": "string",
                  "value": "string"
                }
              ],
              "createdBy": "string",
              "modifiedBy": "string",
              "creationTimeStamp": "string",
              "modifiedTimeStamp": "string",
              "links": [
                {
                  "method": "string",
                  "rel": "string",
                  "uri": "string",
                  "href": "string",
                  "title": "string",
                  "type": "string",
                  "itemType": "string",
                  "responseType": "string",
                  "responseItemType": "string"
                }
              ]
            },
            "jobDefinitionId": "string",
            "version": 0
          },
          "state": "pending",
          "outputTable": {
            "tableName": "string",
            "libraryName": "string",
            "serverName": "string"
          },
          "codeFileUri": "https://example.com",
          "logFileUri": "https://example.com",
          "haveWarnings": true,
          "error": {
            "message": "string",
            "id": "string",
            "errorCode": 0,
            "httpStatusCode": 0,
            "details": [
              "string"
            ],
            "remediation": "string",
            "errors": [
              null
            ],
            "links": [
              {
                "method": "string",
                "rel": "string",
                "uri": "string",
                "href": "string",
                "title": "string",
                "type": "string",
                "itemType": "string",
                "responseType": "string",
                "responseItemType": "string"
              }
            ],
            "version": 0
          },
          "results": {},
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    
    

    Score Analysis Collection

    Properties
    Name Type Required Restrictions Description
    Score Analysis Collection any false none One page of score analysis representations, with optional links to first, prev, next, and last page of the list.

    allOf

    Name Type Required Restrictions Description
    anonymous scoreExecutionCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none Array consisting of one page of score analysis resources.
    »» Score Analysis object false none Contains details about score analysis results. This represents application/vnd.sas.score.analysis media type (version 1).
    »»» id string false none The score analysis ID.
    »»» createdBy string false none The user who created the score analysis.
    »»» creationTimeStamp string(date-time) false none The date and time that the score analysis was created.
    »»» modifiedBy string false none The user ID of the authenticated user who last updated the score analysis.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the score analysis was last modified.
    »»» scoreExecutionId string true none The score execution ID.
    »»» scoreAnalysisRequest #/paths/~1executions~1%7BexecutionId%7D~1analyses/post/requestBody/content/application~1json/schema true none Score Analysis Request contains details about how to generate an analysis using score execution, a score object and a score output table. This represents application/vnd.sas.score.analysis.request media type (version 2).
    »»» state string(enumeration) true none State of the score analysis.
    »»» outputTable object false none Output generated by score execution or analysis. This doesn't represent any top-level media type.
    »»»» tableName string true none Table name where the score execution or analysis output is saved.
    »»»» libraryName string true none Library where the table is located.
    »»»» serverName string true none Server where the table is located.
    »»» codeFileUri string(uri) false none The file URI where the code used to generate a score is saved.
    »»» logFileUri string(uri) false none The file URI where the log of the score execution is saved.
    »»» haveWarnings boolean false none Set to true when there are warnings inside the log file.
    »»» error #/paths/~1/get/responses/404/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» results object false none Contains results for the score execution.
    »»» links [link] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 2.
    Enumerated Values
    Property Value
    state pending
    state running
    state canceled
    state completed
    state failed
    state timedOut

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    application/vnd.sas.score.execution.request

    The score execution request contains details about how to score inputData using the score objects.

    The schema is at scoreExecutionRequest.

    application/vnd.sas.score.execution.request+json

    Here is an example of the JSON representation of this media type.

    
     {
      "version": 1,
      "name": "My score execution",
      "description": "Execute my score execution.",
      "scoreDefinitionId": "29e8ab40-3b86-459b-a8fa-b0779c47e76d",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    application/vnd.sas.score.execution

    Contains details about the execution results.

    The schema is at scoreExecution.

    application/vnd.sas.score.execution+json

    Here is an example of the JSON representation of this media type.

    
     {
      "version": 1,
      "id": "60efc048-7383-4ced-bc3d-4f5258171472",
      "createdBy": "bob",
      "creationTimeStamp": "2014-07-15T04:11:53.040Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2014-08-15T04:11:53.040Z",
      "scoreExecutionRequest": {
        "name": "My score request",
        "description": "Generates score for my request",
        "scoreDefinitionId": "805de80e-63d5-11e6-8b77-86f30ca893d3",
        "hints": {
          "outputLibraryName": "PUBLIC"
        }
      },
      "state": "completed",
      "outputTable": {
        "serverName": "edmcas",
        "libraryName": "PUBLIC",
        "tableName": "BADCAR_DEMO_SCORE_OUTPUT",
        "links": [
          {
            "method": "GET",
            "rel": "self",
            "href": "/casManagement/servers/edmcas/caslibs/PUBLIC/tables/BADCAR_DEMO_SCORE_OUTPUT",
            "uri": "/casManagement/servers/edmcas/caslibs/PUBLIC/tables/BADCAR_DEMO_SCORE_OUTPUT",
            "type": "application/vnd.sas.cas.table"
          }
        ]
      },
      "codeFileUri": "/files/files/f0e3b361-af85-4283-a9c3-d912e95ff3b5",
      "logFileUri": "/files/files/0cb5aedb-0c01-44e7-8250-d432082ebef9",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions",
          "uri": "/scoreExecution/executions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.score.execution application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472",
          "type": "application/vnd.sas.score.execution"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/state",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/state",
          "type": "text/plain"
        },
        {
          "method": "GET",
          "rel": "analyses",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.score.analysis"
        },
        {
          "method": "POST",
          "rel": "analysisCode",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analysisCode",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analysisCode",
          "type": "application/vnd.sas.score.analysis.code.generation.request",
          "responseType": "application/vnd.sas.score.analysis.code"
        }
      ]
    }
    
    application/vnd.sas.score.analysis.code.generation.request

    The score analysis request contains details about how to analyze the execution results and produce the output table.

    The schema is at analysisCodeGenerationRequest.

    application/vnd.sas.score.analysis.code.generation.request+json

    Here is an example of the JSON representation of this media type.

    
     {
      "version": 1,
      "scoreExecutionId": "b5c8a03a-63dd-11e6-8b77-86f30ca893d3",
      "name": "My Analysis Request",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    application/vnd.sas.score.analysis.code

    Contains details about the executable code returned by the score object using the score execution.

    The schema is at analysisCode.

    application/vnd.sas.score.analysis.code+json

    Here is an example of the JSON representation of this media type.

    
     {
      "version": 1,
      "code": "/*DS2 code that creates BADCAR_DEMO_SUMMARY_OUTPUT inside PUBLIC library when executed.*/",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "BADCAR_DEMO_SUMMARY_OUTPUT",
      "outputLibraryName": "PUBLIC"
    }
    
    application/vnd.sas.score.analysis.request

    The score analysis request contains details about how to generate an analysis using the score execution, the score object, and the score output table.

    The schema is at scoreAnalysisRequest.

    application/vnd.sas.score.analysis.request+json

    Here is an example of the JSON representation of this media type.

    
     {
      "scoreExecutionId": "b5c8a03a-63dd-11e6-8b77-86f30ca893d3",
      "name": "My Score Analysis Request",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    application/vnd.sas.score.analysis

    Contains details about the score analysis results.

    The schema is at scoreAnalysis.

    application/vnd.sas.score.analysis+json

    Here is an example of the JSON representation of this media type.

    
     {
      "version": 1,
      "id": "17ebf6d4-0377-11e7-93ae-92361f002671",
      "createdBy": "bob",
      "creationTimeStamp": "2014-07-15T04:11:53.040Z",
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2014-08-15T04:11:53.040Z",
      "scoreAnalysisRequest": {
        "scoreExecutionId": "b5c8a03a-63dd-11e6-8b77-86f30ca893d3",
        "name": "My Score Analysis Request",
        "analysisType": "ruleFiredSummary",
        "hints": {
          "outputLibraryName": "PUBLIC"
        }
      },
      "state": "completed",
      "outputTable": {
        "serverName": "edmcas",
        "libraryName": "PUBLIC",
        "tableName": "BADCAR_DEMO_SUMMARY_OUTPUT",
        "links": [
          {
            "method": "GET",
            "rel": "self",
            "href": "/casManagement/servers/edmcas/caslibs/PUBLIC/tables/BADCAR_DEMO_SUMMARY_OUTPUT",
            "uri": "/casManagement/servers/edmcas/caslibs/PUBLIC/tables/CARS_DATA_output",
            "type": "application/vnd.sas.cas.table"
          }
        ]
      },
      "codeFileUri": "/files/files/f0e3b361-af85-4283-a9c3-d912e95ff3b5",
      "logFileUri": "/files/files/4dee9f34-0377-11e7-93ae-92361f002671",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.score.analysis application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/17ebf6d4-0377-11e7-93ae-92361f002671",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/17ebf6d4-0377-11e7-93ae-92361f002671",
          "type": "application/vnd.sas.score.analysis"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/17ebf6d4-0377-11e7-93ae-92361f002671",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/17ebf6d4-0377-11e7-93ae-92361f002671",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/17ebf6d4-0377-11e7-93ae-92361f002671",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/17ebf6d4-0377-11e7-93ae-92361f002671"
        },
        {
          "method": "GET",
          "rel": "state",
          "href": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/17ebf6d4-0377-11e7-93ae-92361f002671/state",
          "uri": "/scoreExecution/executions/60efc048-7383-4ced-bc3d-4f5258171472/analyses/17ebf6d4-0377-11e7-93ae-92361f002671/state",
          "type": "text/plain"
        }
      ]
    }
    
    application/vnd.sas.summary

    Used to provide base summary information for any objects.

    The schema is at resourceSummary.

    Resource Relationships

    Resource relationship diagram

    Root

    Path: /

    The root of the API. This resource contains links to the top-level resources in the API. The response uses the application/vnd.sas.api media type.

    The GET / response includes the following links:

    Relation Method Description
    scoreExecutions GET Returns the first page of the collection of score executions.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.summary.
    Response item type: application/vnd.sas.score.execution.
    createScoreExecution POST Executes to generate the score.
    Request type: application/vnd.sas.score.execution.request.
    Response type: application/vnd.sas.score.execution.
    Score Executions

    Path: /executions

    This resource contains a collection of the score execution jobs.

    The default page size is 20.

    The scoreExecutions collection representation is application/vnd.sas.collection. The collection types are application/vnd.sas.score.execution resources or application/vnd.sas.summary. (These types apply to the response for the self, collection, prev, next, first, and last links below.)

    Responses include the following links.

    Relation Method Description
    create POST Executes to generate a score and a new score execution is added to the collection.
    Request type: application/vnd.sas.score.execution.request.
    Response type: application/vnd.sas.score.execution.
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection.
    collection GET Returns the first page of the collection, without any sorting or filtering criteria.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    Filtering and sorting can use the following members of the scoreExecution:

    Score Execution Request

    Path: /executions

    Contains the request details about how to generate the score.

    The scoreExecutionRequest representation is application/vnd.sas.score.execution.request.

    Score Execution

    Path: /executions/{executionId}

    Contains details about the generated score.

    The scoreExecution representation is application/vnd.sas.score.execution.

    Responses include the following links.

    Relation Method Description
    up GET Returns the collection to which this score execution belongs.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.score.execution.
    Response item type: application/vnd.sas.summary.
    self GET Returns the score execution by ID.
    Response type: application/vnd.sas.score.execution.
    alternate GET Returns the score execution summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the score execution by ID.
    state GET Returns the state of the score execution.
    Response type: [text/plain].
    analyses GET Returns the collection of score analyses, which ran based on this score execution.
    Response type: application/vnd.sas.collection.
    analysisCode POST Returns the analysis code generated by the score object using the score execution, the score output table, and the hints.
    Request type: application/vnd.sas.score.analysis.code.generation.request.
    Response type: application/vnd.sas.score.analysis.code.
    Score Execution Summary

    Path: /executions/{executionId}

    This resource contains the summary details about the generated score.

    The scoreExecutionSummary representation is application/vnd.sas.summary.

    Responses include the following links.

    Relation Method Description
    up GET Returns the collection to which this score execution belongs.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.summary.
    Response item type: application/vnd.sas.score.execution.
    self GET Returns the score execution by ID.
    Response type: application/vnd.sas.score.execution.
    alternate GET Returns the score execution summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the score execution by ID.
    state GET Returns the state of the score execution.
    Response type: [text/plain].
    analyses GET Returns the collection of score analyses, which ran based on this score execution.
    Response type: application/vnd.sas.collection.
    analysisCode POST Returns the analysis code generated by the score object using the score execution, the score output table, and the hints.
    Request type: application/vnd.sas.score.analysis.code.generation.request.
    Response type: application/vnd.sas.score.analysis.code.
    Analysis Code Generation Request

    Path: /executions/{executionId}/analysisCode

    Contains details about how to generate the analysis code from the score object using the score execution, the score output table, and the hints.

    The analysisCodeGenerationReqiest representation is application/vnd.sas.score.analysis.code.generation.request.

    Analysis Code

    Path: /executions/{executionId}/analysisCode

    Contains details about the generated analysis code by the score object using the score execution, the score output table, and the hints.

    The analysisCode representation is application/vnd.sas.score.analysis.code.

    Score Analyses

    Path: /executions/{executionId}/analyses

    This resource contains the collection of the score analysis.

    Default page size is 20.

    The scoreAnalyses collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.score.analysis resources or application/vnd.sas.summary. (These types apply to the response for the self, collection, prev, next, first, and last links below.)

    Responses include the following links.

    Relation Method Description
    create POST Executes to generate the analysis and a new score analysis is added to the collection.
    Request type: application/vnd.sas.score.analysis.request.
    Response type: application/vnd.sas.score.analysis.
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    Filtering and sorting can use the following members of the scoreAnalysis:

    Score Analysis Request

    Path: /executions/{executionId}/analyses

    Contains request details about how to generate an analysis.

    The scoreAnalysisRequest representation is application/vnd.sas.score.analysis.request.

    Score Analysis

    Path: /executions/{executionId}/analyses/{analysisId}

    Contains details about the generated analysis.

    The scoreAnalysis representation is application/vnd.sas.score.analysis.

    Responses include the following links.

    Relation Method Description
    up GET Returns the collection to which this score analysis belongs.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.score.analysis.
    Response item type: application/vnd.sas.summary.
    self GET Returns the score analysis by ID.
    Response type: application/vnd.sas.score.analysis.
    alternate GET Returns the score analysis summary by iID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the score analysis by ID.
    state GET Returns the state of the score analysis.
    Response type: [text/plain].
    Score Analysis Summary

    Path: /executions/{executionId}/analyses/{analysisId}

    Contains summary details about the generated analysis.

    The scoreAnalysisSummary representation is application/vnd.sas.summary.

    Responses include the following links.

    Relation Method Description
    up GET Returns the collection to which this score analysis belongs.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.summary.
    Response item type: application/vnd.sas.score.analysis.
    self GET Returns the score analysis by ID.
    Response type: application/vnd.sas.score.analysis.
    alternate GET Returns the score analysis summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the score analysis by ID.
    state GET Returns the state of the score analysis.
    Response type: [text/plain].

    Score Definitions

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Score Definitions API is used for creating and maintaining score definitions.

    Usage Notes

    Overview

    Score definitions are used by the Score Execution API to generate mapped code, which is then used to generate the score for the input data.

    A score definition contains the following details:

    1. Input data that needs to be scored.
    2. Details about the score object whose logic is used to produce a score.
    3. Mappings between the input data columns and the variables of the mapped code of the score object.
    Why Use this API?

    Security

    Please see Security in SAS REST APIs for details about authentication and authorization.

    Authorization rules for the score definitions:

    Terminology

    score

    output data set with additional computed columns produced by executing code against a set of data.

    score definition

    contains details about the input data, the score object, and the mapping. application/vnd.sas.score.definition

    score definition summary

    a summary of the score definition that contains information about the score object and the properties. application/vnd.sas.score.definition.summary

    scenario

    a type of score definition that contains an expected value.

    input data

    data that is scored using the logic of a score object. Input data can be either a CAS Table or Inline.

    score object

    object whose generated mapped code is used to score the input data. Some examples of score objects are decisions and models.

    Any object that can generate mapped code by implementing the REST endpoint below can be treated as a score object POST /{score-object-uri}/mappedCode Content-Type: application/vnd.sas.score.code.generation.request Accept: application/vnd.sas.score.mapped.code

    mapping

    assigning an input data column to a variable of the generated mapped code of a score object.

    Mapping can also be static, by giving a constant value to a variable of the score object.

    mapped code

    executable code generated by the score object using the score definition and input data. application/vnd.sas.score.mapped.code

    code generation request

    contains hints to generate the mapped code for a score object using the score definition. application/vnd.sas.score.code.generation.request

    hints

    name value pairs that are passed to score objects to generate mapped code and analysis code. These hints can also be used to assign values for the job definition.

    score execution

    creates a score for the input data using the mapped code and job definition. See the Score Execution API for more details.

    rule set

    sequenced group of related business rules that accomplish a logical business operation. See the Business Rules API for more details.

    decision

    allows users to build and retrieve a decision flow by linking statistical models in combination with deterministic logic from business rules for the purpose of integrating into an operational process. See the Decisions API for more details.

    model

    a formula or algorithm that computes outputs from inputs. An example is a predictive model that derives information about the conditional distribution of the target variables, given the input variables.

    Operations

    Root

    Contains the operations for the root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreDefinitions/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/scoreDefinitions/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/scoreDefinitions/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreDefinitions/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns the links to the top-level resources for the API.

    Example responses

    scoreDefinition root content.

    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "scoreDefinitions",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "createScoreDefinition",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        }
      ]
    }
    
    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "scoreDefinitions",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "createScoreDefinition",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the headers for the API

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/scoreDefinitions/
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/scoreDefinitions/',
    {
      method: 'HEAD'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.head('https://example.com/scoreDefinitions/')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/scoreDefinitions/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /

    Returns the headers for the API. Also used to determine whether the service provided by the API is available.

    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Score Definitions

    Contains operations to create, read, update, and delete score definitions.

    Get a collection of the score definitions

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreDefinitions/definitions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/scoreDefinitions/definitions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/scoreDefinitions/definitions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreDefinitions/definitions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitions

    Returns a list of the score definitions based on the specified pagination, filtering, and sorting options. The items in the list depend on the Accept-Item header.

    Parameters
    Name In Type Required Description
    Accept-Item header string(media-type) false Used for selecting the desired item representation.
    start query integer(int64) false Returns the index of the first score definition.
    limit query integer(int32) false Returns the maximum number of score definitions.
    filter query string(filter-criteria) false The criteria used for filtering the score definitions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria used for sorting the score definitions. See Sorting in REST APIs.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.score.definition+json
    Accept-Item application/vnd.sas.score.definition.summary+json
    Accept-Item application/vnd.sas.summary+json

    Example responses

    scoreDefinition List

    {
      "accept": "application/vnd.sas.score.definition",
      "items": [
        {
          "createdBy": "bob",
          "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
          "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "inputData": {
            "type": "CASTable",
            "serverName": "cas-shared-default",
            "libraryName": "Public",
            "tableName": "HMEQ_EN"
          },
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreDefinitions/definitions",
              "uri": "/scoreDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "type": "application/vnd.sas.score.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "type": "application/vnd.sas.score.definition",
              "responseType": "application/vnd.sas.score.definition"
            },
            {
              "method": "POST",
              "rel": "mappedCode",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
              "type": "application/vnd.sas.score.code.generation.request",
              "responseType": "application/vnd.sas.score.mapped.code"
            }
          ],
          "mappings": [
            {
              "variableName": "fired",
              "mappingType": "datasource",
              "mappingValue": "JOB"
            },
            {
              "variableName": "itemCount",
              "mappingType": "datasource",
              "mappingValue": "LOAN"
            },
            {
              "variableName": "findAllRetCode",
              "mappingType": "datasource",
              "mappingValue": "MORTDUE"
            }
          ],
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
          "name": "Code_file_9130_Test_1",
          "objectDescriptor": {
            "name": "Code_file_9130",
            "type": "codeFile",
            "uri": "http://scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
          },
          "properties": {
            "outputLibraryName": "Public",
            "outputServerName": "cas-shared-default",
            "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
            "test": "true",
            "version": "1.0"
          },
          "version": 2
        }
      ],
      "limit": 1,
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions?start=0&limit=1",
          "uri": "/scoreDefinitions/definitions?start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/scoreDefinitions/definitions?start=1&limit=1",
          "uri": "/scoreDefinitions/definitions?start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.score.definition"
        }
      ],
      "name": "scoreDefinitions",
      "start": 0,
      "version": 2
    }
    
    {
      "accept": "application/vnd.sas.score.definition",
      "items": [
        {
          "createdBy": "bob",
          "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
          "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "inputData": {
            "type": "CASTable",
            "serverName": "cas-shared-default",
            "libraryName": "Public",
            "tableName": "HMEQ_EN"
          },
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/scoreDefinitions/definitions",
              "uri": "/scoreDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "type": "application/vnd.sas.score.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
              "type": "application/vnd.sas.score.definition",
              "responseType": "application/vnd.sas.score.definition"
            },
            {
              "method": "POST",
              "rel": "mappedCode",
              "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
              "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
              "type": "application/vnd.sas.score.code.generation.request",
              "responseType": "application/vnd.sas.score.mapped.code"
            }
          ],
          "mappings": [
            {
              "variableName": "fired",
              "mappingType": "datasource",
              "mappingValue": "JOB"
            },
            {
              "variableName": "itemCount",
              "mappingType": "datasource",
              "mappingValue": "LOAN"
            },
            {
              "variableName": "findAllRetCode",
              "mappingType": "datasource",
              "mappingValue": "MORTDUE"
            }
          ],
          "modifiedBy": "bob",
          "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
          "name": "Code_file_9130_Test_1",
          "objectDescriptor": {
            "name": "Code_file_9130",
            "type": "codeFile",
            "uri": "http://scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
          },
          "properties": {
            "outputLibraryName": "Public",
            "outputServerName": "cas-shared-default",
            "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
            "test": "true",
            "version": "1.0"
          },
          "version": 2
        }
      ],
      "limit": 1,
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions?start=0&limit=1",
          "uri": "/scoreDefinitions/definitions?start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/scoreDefinitions/definitions?start=1&limit=1",
          "uri": "/scoreDefinitions/definitions?start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.score.definition"
        }
      ],
      "name": "scoreDefinitions",
      "start": 0,
      "version": 2
    }
    

    Bad request.

    {
      "details": [
        "path: /scoreDefinitions/definitions",
        "correlator: ed99521a-e493-4bd3-81c9-7856434a4ed2"
      ],
      "errors": [
        {
          "version": 2,
          "httpStatusCode": 400,
          "errorCode": 1021,
          "message": "The request is not valid"
        }
      ],
      "httpStatusCode": 400,
      "message": "The request is not valid.",
      "remediation": "Correct the errors and retry the request.",
      "version": 2
    }
    
    {
      "details": [
        "path: /scoreDefinitions/definitions",
        "correlator: ed99521a-e493-4bd3-81c9-7856434a4ed2"
      ],
      "errors": [
        {
          "version": 2,
          "httpStatusCode": 400,
          "errorCode": 1021,
          "message": "The request is not valid"
        }
      ],
      "httpStatusCode": 400,
      "message": "The request is not valid.",
      "remediation": "Correct the errors and retry the request.",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. scoreDefinitionCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new score definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/scoreDefinitions/definitions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.definition+json' \
      -H 'Accept: application/vnd.sas.score.definition+json'
    
    
    const inputBody = '{
      "name": "string",
      "description": "string",
      "preprocessingCode": "string",
      "objectDescriptor": {
        "name": "string",
        "type": "string",
        "uri": "https://example.com"
      },
      "inputData": {
        "type": "CASTable",
        "serverName": "string",
        "libraryName": "string",
        "tableName": "string",
        "code": "string",
        "outputTableName": "string"
      },
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "properties": {
        "property1": "string",
        "property2": "string"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.definition+json',
      'Accept':'application/vnd.sas.score.definition+json'
    };
    
    fetch('https://example.com/scoreDefinitions/definitions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.definition+json',
      'Accept': 'application/vnd.sas.score.definition+json'
    }
    
    r = requests.post('https://example.com/scoreDefinitions/definitions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.definition+json"},
            "Accept": []string{"application/vnd.sas.score.definition+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/scoreDefinitions/definitions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /definitions

    Creates a new score definition based on the representation in the request body.

    Body parameter

    {
      "name": "string",
      "description": "string",
      "preprocessingCode": "string",
      "objectDescriptor": {
        "name": "string",
        "type": "string",
        "uri": "https://example.com"
      },
      "inputData": {
        "type": "CASTable",
        "serverName": "string",
        "libraryName": "string",
        "tableName": "string",
        "code": "string",
        "outputTableName": "string"
      },
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "properties": {
        "property1": "string",
        "property2": "string"
      }
    }
    
    Parameters
    Name In Type Required Description
    parentFolderUri query string false Adds the score definition as a member of a folder.
    body body scoreDefinitionCollection true Score definition details that need to be created.

    Example responses

    scoreDefinition List

    {
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "inputData": {
        "type": "CASTable",
        "serverName": "cas-shared-default",
        "libraryName": "Public",
        "tableName": "HMEQ_EN"
      },
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "mappings": [
        {
          "variableName": "findAllRetCode",
          "mappingType": "datasource",
          "mappingValue": "MORTDUE"
        },
        {
          "variableName": "itemCount",
          "mappingType": "datasource",
          "mappingValue": "LOAN"
        },
        {
          "variableName": "fired",
          "mappingType": "datasource",
          "mappingValue": "JOB"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "objectDescriptor": {
        "name": "Code_file_9130",
        "type": "codeFile",
        "uri": "http://decisions/codeFiles/5f7a0523-5fd8-4cba-90d1-a6971f12d220/revisions/2c99a55e-e4c9-4518-8f54-918ffc18c9a7"
      },
      "properties": {
        "outputLibraryName": "Public",
        "outputServerName": "cas-shared-default",
        "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
        "test": "true",
        "version": "1.0"
      },
      "version": 2
    }
    
    {
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "inputData": {
        "type": "CASTable",
        "serverName": "cas-shared-default",
        "libraryName": "Public",
        "tableName": "HMEQ_EN"
      },
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "mappings": [
        {
          "variableName": "findAllRetCode",
          "mappingType": "datasource",
          "mappingValue": "MORTDUE"
        },
        {
          "variableName": "itemCount",
          "mappingType": "datasource",
          "mappingValue": "LOAN"
        },
        {
          "variableName": "fired",
          "mappingType": "datasource",
          "mappingValue": "JOB"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "objectDescriptor": {
        "name": "Code_file_9130",
        "type": "codeFile",
        "uri": "http://decisions/codeFiles/5f7a0523-5fd8-4cba-90d1-a6971f12d220/revisions/2c99a55e-e4c9-4518-8f54-918ffc18c9a7"
      },
      "properties": {
        "outputLibraryName": "Public",
        "outputServerName": "cas-shared-default",
        "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
        "test": "true",
        "version": "1.0"
      },
      "version": 2
    }
    

    Bad request.

    {
      "details": [
        "path: /scoreDefinitions/definitions",
        "correlator: ed99521a-e493-4bd3-81c9-7856434a4ed2"
      ],
      "errors": [
        {
          "version": 2,
          "httpStatusCode": 400,
          "errorCode": 1021,
          "message": "The request is not valid"
        }
      ],
      "httpStatusCode": 400,
      "message": "The request is not valid.",
      "remediation": "Correct the errors and retry the request.",
      "version": 2
    }
    
    {
      "details": [
        "path: /scoreDefinitions/definitions",
        "correlator: ed99521a-e493-4bd3-81c9-7856434a4ed2"
      ],
      "errors": [
        {
          "version": 2,
          "httpStatusCode": 400,
          "errorCode": 1021,
          "message": "The request is not valid"
        }
      ],
      "httpStatusCode": 400,
      "message": "The request is not valid.",
      "remediation": "Correct the errors and retry the request.",
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A score definition was created. scoreDefinitionCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Location string uri The URL of the score definition.
    201 ETag string The entity tag for the score definition.
    201 Last-Modified string date-time The timestamp when the score definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Get a score definition

    Code samples

    # You can also use wget
    curl -X GET https://example.com/scoreDefinitions/definitions/{definitionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.score.definition+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.score.definition+json'
    };
    
    fetch('https://example.com/scoreDefinitions/definitions/{definitionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.score.definition+json'
    }
    
    r = requests.get('https://example.com/scoreDefinitions/definitions/{definitionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.score.definition+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/scoreDefinitions/definitions/{definitionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitions/{definitionId}

    Returns the representation of the specified score definition.

    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the score definition.

    Example responses

    scoreDefinition List

    {
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "inputData": {
        "type": "CASTable",
        "serverName": "cas-shared-default",
        "libraryName": "Public",
        "tableName": "HMEQ_EN"
      },
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "mappings": [
        {
          "variableName": "findAllRetCode",
          "mappingType": "datasource",
          "mappingValue": "MORTDUE"
        },
        {
          "variableName": "itemCount",
          "mappingType": "datasource",
          "mappingValue": "LOAN"
        },
        {
          "variableName": "fired",
          "mappingType": "datasource",
          "mappingValue": "JOB"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "objectDescriptor": {
        "name": "Code_file_9130",
        "type": "codeFile",
        "uri": "http://decisions/codeFiles/5f7a0523-5fd8-4cba-90d1-a6971f12d220/revisions/2c99a55e-e4c9-4518-8f54-918ffc18c9a7"
      },
      "properties": {
        "outputLibraryName": "Public",
        "outputServerName": "cas-shared-default",
        "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
        "test": "true",
        "version": "1.0"
      },
      "version": 2
    }
    
    {
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "objectDescriptor": {
        "name": "Code_file_9130",
        "type": "codeFile",
        "uri": "http://decisions/codeFiles/5f7a0523-5fd8-4cba-90d1-a6971f12d220/revisions/2c99a55e-e4c9-4518-8f54-918ffc18c9a7"
      },
      "properties": {
        "outputLibraryName": "Public",
        "outputServerName": "cas-shared-default",
        "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
        "test": "true",
        "version": "1.0"
      },
      "version": 2
    }
    
    {
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "type": "scoreDefinition",
      "version": 2
    }
    
    {
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "inputData": {
        "type": "CASTable",
        "serverName": "cas-shared-default",
        "libraryName": "Public",
        "tableName": "HMEQ_EN"
      },
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "mappings": [
        {
          "variableName": "findAllRetCode",
          "mappingType": "datasource",
          "mappingValue": "MORTDUE"
        },
        {
          "variableName": "itemCount",
          "mappingType": "datasource",
          "mappingValue": "LOAN"
        },
        {
          "variableName": "fired",
          "mappingType": "datasource",
          "mappingValue": "JOB"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "objectDescriptor": {
        "name": "Code_file_9130",
        "type": "codeFile",
        "uri": "http://decisions/codeFiles/5f7a0523-5fd8-4cba-90d1-a6971f12d220/revisions/2c99a55e-e4c9-4518-8f54-918ffc18c9a7"
      },
      "properties": {
        "outputLibraryName": "Public",
        "outputServerName": "cas-shared-default",
        "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
        "test": "true",
        "version": "1.0"
      },
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. scoreDefinitionCollection
    404 Not Found No score definition exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the score definition.
    200 Last-Modified string date-time The timestamp when the score definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Get the headers for a score definition

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/scoreDefinitions/definitions/{definitionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/scoreDefinitions/definitions/{definitionId}',
    {
      method: 'HEAD'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.head('https://example.com/scoreDefinitions/definitions/{definitionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/scoreDefinitions/definitions/{definitionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /definitions/{definitionId}

    Returns the headers for the specified score definition. Also used to determine whether a particular score definition exists.

    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the score definition.
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found No score definition exists at the requested path. None
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the score definition.
    200 Last-Modified string date-time The timestamp when the score definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Update a score definition

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/scoreDefinitions/definitions/{definitionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.definition+json' \
      -H 'Accept: application/vnd.sas.score.definition+json' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "inputData": {
        "type": "CASTable",
        "serverName": "cas-shared-default",
        "libraryName": "Public",
        "tableName": "HMEQ_EN"
      },
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "mappings": [
        {
          "variableName": "findAllRetCode",
          "mappingType": "datasource",
          "mappingValue": "MORTDUE"
        },
        {
          "variableName": "itemCount",
          "mappingType": "datasource",
          "mappingValue": "LOAN"
        },
        {
          "variableName": "fired",
          "mappingType": "datasource",
          "mappingValue": "JOB"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "objectDescriptor": {
        "name": "Code_file_9130",
        "type": "codeFile",
        "uri": "http://decisions/codeFiles/5f7a0523-5fd8-4cba-90d1-a6971f12d220/revisions/2c99a55e-e4c9-4518-8f54-918ffc18c9a7"
      },
      "properties": {
        "outputLibraryName": "Public",
        "outputServerName": "cas-shared-default",
        "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
        "test": "true",
        "version": "1.0"
      },
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.definition+json',
      'Accept':'application/vnd.sas.score.definition+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/scoreDefinitions/definitions/{definitionId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.definition+json',
      'Accept': 'application/vnd.sas.score.definition+json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/scoreDefinitions/definitions/{definitionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.definition+json"},
            "Accept": []string{"application/vnd.sas.score.definition+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/scoreDefinitions/definitions/{definitionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /definitions/{definitionId}

    Updates the specified score definition based on the representation in the request body.

    Body parameter

    scoreDefinition List

    {
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "inputData": {
        "type": "CASTable",
        "serverName": "cas-shared-default",
        "libraryName": "Public",
        "tableName": "HMEQ_EN"
      },
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "mappings": [
        {
          "variableName": "findAllRetCode",
          "mappingType": "datasource",
          "mappingValue": "MORTDUE"
        },
        {
          "variableName": "itemCount",
          "mappingType": "datasource",
          "mappingValue": "LOAN"
        },
        {
          "variableName": "fired",
          "mappingType": "datasource",
          "mappingValue": "JOB"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "objectDescriptor": {
        "name": "Code_file_9130",
        "type": "codeFile",
        "uri": "http://decisions/codeFiles/5f7a0523-5fd8-4cba-90d1-a6971f12d220/revisions/2c99a55e-e4c9-4518-8f54-918ffc18c9a7"
      },
      "properties": {
        "outputLibraryName": "Public",
        "outputServerName": "cas-shared-default",
        "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
        "test": "true",
        "version": "1.0"
      },
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the score definition.
    If-Match header string true The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the score definition.
    body body scoreDefinitionCollection true The representation of a score definition.

    Example responses

    scoreDefinition List

    {
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "inputData": {
        "type": "CASTable",
        "serverName": "cas-shared-default",
        "libraryName": "Public",
        "tableName": "HMEQ_EN"
      },
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "mappings": [
        {
          "variableName": "findAllRetCode",
          "mappingType": "datasource",
          "mappingValue": "MORTDUE"
        },
        {
          "variableName": "itemCount",
          "mappingType": "datasource",
          "mappingValue": "LOAN"
        },
        {
          "variableName": "fired",
          "mappingType": "datasource",
          "mappingValue": "JOB"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "objectDescriptor": {
        "name": "Code_file_9130",
        "type": "codeFile",
        "uri": "http://decisions/codeFiles/5f7a0523-5fd8-4cba-90d1-a6971f12d220/revisions/2c99a55e-e4c9-4518-8f54-918ffc18c9a7"
      },
      "properties": {
        "outputLibraryName": "Public",
        "outputServerName": "cas-shared-default",
        "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
        "test": "true",
        "version": "1.0"
      },
      "version": 2
    }
    
    {
      "createdBy": "bob",
      "creationTimeStamp": "2021-09-18T03:20:14.136294Z",
      "id": "2e585929-9334-4db9-9f52-2dbc01fc6d0f",
      "inputData": {
        "type": "CASTable",
        "serverName": "cas-shared-default",
        "libraryName": "Public",
        "tableName": "HMEQ_EN"
      },
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/scoreDefinitions/definitions",
          "uri": "/scoreDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f",
          "type": "application/vnd.sas.score.definition",
          "responseType": "application/vnd.sas.score.definition"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "uri": "/scoreDefinitions/definitions/2e585929-9334-4db9-9f52-2dbc01fc6d0f/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        }
      ],
      "mappings": [
        {
          "variableName": "findAllRetCode",
          "mappingType": "datasource",
          "mappingValue": "MORTDUE"
        },
        {
          "variableName": "itemCount",
          "mappingType": "datasource",
          "mappingValue": "LOAN"
        },
        {
          "variableName": "fired",
          "mappingType": "datasource",
          "mappingValue": "JOB"
        }
      ],
      "modifiedBy": "bob",
      "modifiedTimeStamp": "2021-09-18T03:20:14.136294Z",
      "name": "Code_file_9130_Test_1",
      "objectDescriptor": {
        "name": "Code_file_9130",
        "type": "codeFile",
        "uri": "http://decisions/codeFiles/5f7a0523-5fd8-4cba-90d1-a6971f12d220/revisions/2c99a55e-e4c9-4518-8f54-918ffc18c9a7"
      },
      "properties": {
        "outputLibraryName": "Public",
        "outputServerName": "cas-shared-default",
        "tableBaseName": "Code_file_9130_Test_1_Code_file_9130",
        "test": "true",
        "version": "1.0"
      },
      "version": 2
    }
    

    Bad request.

    {
      "details": [
        "path: /scoreDefinitions/definitions",
        "correlator: ed99521a-e493-4bd3-81c9-7856434a4ed2"
      ],
      "errors": [
        {
          "version": 2,
          "httpStatusCode": 400,
          "errorCode": 1021,
          "message": "The request is not valid"
        }
      ],
      "httpStatusCode": 400,
      "message": "The request is not valid.",
      "remediation": "Correct the errors and retry the request.",
      "version": 2
    }
    
    {
      "details": [
        "path: /scoreDefinitions/definitions",
        "correlator: ed99521a-e493-4bd3-81c9-7856434a4ed2"
      ],
      "errors": [
        {
          "version": 2,
          "httpStatusCode": 400,
          "errorCode": 1021,
          "message": "The request is not valid"
        }
      ],
      "httpStatusCode": 400,
      "message": "The request is not valid.",
      "remediation": "Correct the errors and retry the request.",
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    
    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. scoreDefinitionCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No score definition exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the score definition.
    200 Last-Modified string date-time The timestamp when the score definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Delete a score definition

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/scoreDefinitions/definitions/{definitionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/scoreDefinitions/definitions/{definitionId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/scoreDefinitions/definitions/{definitionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/scoreDefinitions/definitions/{definitionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /definitions/{definitionId}

    Deletes the specified score definition.

    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the score definition.
    Responses
    Status Meaning Description Schema
    204 No Content The score definition was deleted. None

    Code

    Contains operations for generating code.

    Generate mapped code

    Code samples

    # You can also use wget
    curl -X POST https://example.com/scoreDefinitions/definitions/{definitionId}/mappedCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "scoreDefinitionId": "string",
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/scoreDefinitions/definitions/{definitionId}/mappedCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/scoreDefinitions/definitions/{definitionId}/mappedCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/scoreDefinitions/definitions/{definitionId}/mappedCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /definitions/{definitionId}/mappedCode

    Generates mapped code from the score definition by forwarding the request to the score object.

    Body parameter

    {
      "scoreDefinitionId": "string",
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }
    
    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the score definition.
    body body #/paths/~1definitions~1%7BdefinitionId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request%2Bjson/schema true Representation of the score code generation request containing the score definition ID and hints.

    Example responses

    mappedcode example

    {
      "code": "/* DS2 code of an object, which generates an XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS"
    }
    
    {
      "code": "/* DS2 code of an object, which generates an XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS"
    }
    

    Bad request.

    {
      "details": [
        "path: /scoreDefinitions/definitions",
        "correlator: ed99521a-e493-4bd3-81c9-7856434a4ed2"
      ],
      "errors": [
        {
          "version": 2,
          "httpStatusCode": 400,
          "errorCode": 1021,
          "message": "The request is not valid"
        }
      ],
      "httpStatusCode": 400,
      "message": "The request is not valid.",
      "remediation": "Correct the errors and retry the request.",
      "version": 2
    }
    
    {
      "details": [
        "path: /scoreDefinitions/definitions",
        "correlator: ed99521a-e493-4bd3-81c9-7856434a4ed2"
      ],
      "errors": [
        {
          "version": 2,
          "httpStatusCode": 400,
          "errorCode": 1021,
          "message": "The request is not valid"
        }
      ],
      "httpStatusCode": 400,
      "message": "The request is not valid.",
      "remediation": "Correct the errors and retry the request.",
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No score definition exists at the requested path. Inline
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 2.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.collection%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Location string No description

    Schemas

    scoreDefinitionCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "description": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "preprocessingCode": "string",
          "objectDescriptor": {
            "name": "string",
            "type": "string",
            "uri": "https://example.com"
          },
          "inputData": {
            "type": "CASTable",
            "serverName": "string",
            "libraryName": "string",
            "tableName": "string",
            "code": "string",
            "outputTableName": "string"
          },
          "mappings": [
            {
              "variableName": "string",
              "mappingType": "datasource",
              "mappingValue": 0
            }
          ],
          "properties": {
            "property1": "string",
            "property2": "string"
          },
          "folderType": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    
    

    Score Definition Collection

    Properties
    Name Type Required Restrictions Description
    Score Definition Collection any false none One page of the score definition representations, with optional links to first, prev, next, and last page of the list.

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [object] false none The links that apply to the collection.
    »» Link object false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] false none The actual results of a query
    »» Score Definition object false none A definition containing details about Input Data, Score Object and Mapping. This represents application/vnd.sas.score.definition media type (version 1).
    »»» id string false none The system-assigned unique ID for this object
    »»» name string true none The score definition name
    »»» description string false none The score definition description
    »»» createdBy string false none The user who created the score definition.
    »»» creationTimeStamp string(date-time) false none The date and time that the score definition was created.
    »»» modifiedBy string false none The userId of the authenticated user who last updated the score definition.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the score definition was last modified.
    »»» preprocessingCode string false none Preprocessing code that is executed before executing the Mapped Code.
    »»» objectDescriptor object true none Descriptor of a Score Object whose logic is used to produce a score for Input Data. This doesn't represent any top-level media type.
    »»»» name string false none Name of the Score Object.
    »»»» type string false none Type of the Score Object.
    »»»» uri string(uri) true none Uri to the Score Object.
    »»» inputData object true none Input Data that will be scored. This doesn't represent any top-level media type.
    »»»» type string(enumeration) true none The type of input data.
    »»»» serverName string true none CAS Server name where CAS table is located. Valid only if the type is CASTable.
    »»»» libraryName string true none CAS Library name where CAS table is located. Valid only if the type is CASTable.
    »»»» tableName string true none Name of the CAS table. Valid only if the type is CASTable.
    »»»» code string false none Code containing inline data. Valid only if the type is Inline.
    »»»» outputTableName string false none Name of the output table that will be generated when the inline code is executed. Valid only if the type is Inline.
    »»» mappings [any] false none Array of mappings between Score Object variables and Input Data columns.
    »»»» Mapping object false none Assigning Input Data column to a variable of the generated Mapped Code of Score Object. This doesn't represent any top-level media type.
    »»»»» variableName string true none Name of the Score Object's variable.
    »»»»» mappingType string(enumeration) true none The mapping type.
    »»»»» mappingValue any false none 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.

    anyOf

    Name Type Required Restrictions Description
    »»»»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»» properties object false none The properties for this score definition that support scoring for decisions and business rules.
    • outputServerName: The name of a Cloud Analytic Server.
    • outputLibraryName: The name of a Cloud Analytic Server library.
    • tableBaseName: The name of a table in the output library.
    • test: A flag that indicates whether the score definition is used for test scoring. Valid values are "true" and "false".
    These additional properties support publish validation for decisions and business rules.
    • asssetUri: The URI of the decision or business rule that is being validated.
    • publishDestination: The name of a publish destination.
    • publishType: The type of publish destination.
    • publishName: The name for publishing the asset.
    »»»» additionalProperties string false none none
    »»» folderType string false none Indicates the kind of folder where the score definition is housed.
    »»» links [link] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 2.
    Enumerated Values
    Property Value
    type CASTable
    type Inline
    type Scenario
    mappingType datasource
    mappingType static
    mappingType expected

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    application/vnd.sas.score.definition

    Contains information for the input data, the score object, and the mappings within a score definition.

    The schema is at scoreDefinition.

    application/vnd.sas.score.definition+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-06-02T15:38:30.988Z",
       "modifiedTimeStamp":"2017-06-02T15:38:30.988Z",
       "createdBy":"bob",
       "modifiedBy":"bob",
       "id":"36f6498b-b612-412c-9182-f0bfbd970d51",
       "name":"My Score Definition",
       "folderType": "myFolder",
       "objectDescriptor":{
          "name":"My Rule Set",
          "type":"ruleSet",
          "uri":"/businessRules/ruleSets/0d25d749-24e0-4e5d-a773-ea7a1eb0fdc5"
       },
       "inputData":{
          "type":"CASTable",
          "serverName":"MyCASServer",
          "tableName":"BADCAR_DEMO",
          "libraryName":"HPS"
       },
       "mappings":[
          {
             "variableName":"Make",
             "mappingType":"datasource",
             "mappingValue":"make"
          },
          {
             "variableName":"Model",
             "mappingType":"datasource",
             "mappingValue":"model"
          },
          {
             "variableName":"Odometer",
             "mappingType":"datasource",
             "mappingValue":"vehodo"
          }
          {
             "variableName":"Maximum_Mileage",
             "mappingType":"static",
             "mappingValue":"100000"
          },
       ],
       "links":[
          {
             "method":"GET",
             "rel":"up",
             "href":"/scoreDefinitions/definitions",
             "uri":"/scoreDefinitions/definitions",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.dcm.score.definition"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "type":"application/vnd.sas.dcm.score.definition"
          },
          {
             "method":"GET",
             "rel":"alternate",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "type":"application/vnd.sas.summary"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "type":"application/vnd.sas.dcm.score.definition",
             "responseType":"application/vnd.sas.dcm.score.definition"
          },
          {
             "method":"POST",
             "rel":"mappedCode",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51/mappedCode",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51/mappedCode",
             "type":"application/vnd.sas.dcm.score.code.generation.request",
             "responseType":"application/vnd.sas.dcm.score.mapped.code"
          }
       ],
       "version":1
    }
    
    application/vnd.sas.score.definition.summary

    Contains the details of the score object and properties.

    The schema is at scoreDefinitionDefinitionSummary.

    application/vnd.sas.score.definition.summary+json

    Here is an example of the JSON representation for this media type.

    
     {
       "creationTimeStamp":"2017-06-02T15:38:30.988Z",
       "modifiedTimeStamp":"2017-06-02T15:38:30.988Z",
       "createdBy":"bob",
       "modifiedBy":"bob",
       "id":"36f6498b-b612-412c-9182-f0bfbd970d51",
       "name":"My Score Definition",
       "folderType": "myFolder",
       "objectDescriptor":{
          "name":"My Rule Set",
          "type":"ruleSet",
          "uri":"/businessRules/ruleSets/0d25d749-24e0-4e5d-a773-ea7a1eb0fdc5"
       },
       "links":[
          {
             "method":"GET",
             "rel":"up",
             "href":"/scoreDefinitions/definitions",
             "uri":"/scoreDefinitions/definitions",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.dcm.score.definition"
          },
          {
             "method":"GET",
             "rel":"self",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "type":"application/vnd.sas.dcm.score.definition"
          },
          {
             "method":"GET",
             "rel":"alternate",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "type":"application/vnd.sas.summary"
          },
          {
             "method":"DELETE",
             "rel":"delete",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51"
          },
          {
             "method":"PUT",
             "rel":"update",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51",
             "type":"application/vnd.sas.dcm.score.definition",
             "responseType":"application/vnd.sas.dcm.score.definition"
          },
          {
             "method":"POST",
             "rel":"mappedCode",
             "href":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51/mappedCode",
             "uri":"/scoreDefinitions/definitions/36f6498b-b612-412c-9182-f0bfbd970d51/mappedCode",
             "type":"application/vnd.sas.dcm.score.code.generation.request",
             "responseType":"application/vnd.sas.dcm.score.mapped.code"
          }
       ],
       "version":1
    }
    
    application/vnd.sas.score.code.generation.request

    Contains the score definition details and hints for the generated mapped code.

    The schema is at scoreCodeGenerationRequest.

    application/vnd.sas.score.code.generation.request+json

    Here is an example of the JSON representation for this media type.

    
     {
      "version": 1,
      "scoreDefinitionId": "b5c8a03a-63dd-11e6-8b77-86f30ca893d3",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    application/vnd.sas.score.mapped.code

    Contains the details about the executable code returned by the score object.

    The schema is at mappedCode.

    application/vnd.sas.score.mapped.code+json

    Here is an example of the JSON representation for this media type

    
     {
      "code": "package BRM_51_RuleSet_0 /overwrite=yes; method execute(in_out varchar \"Make\", in_out double \"Maximum_Mileage\", in_out varchar \"Model\", in_out double \"Odometer\", in_out double \"RejectCar\"); \"RejectCar\" = 0 ; if (Odometer > Maximum_MileageMaximum_Mileage) then do; \"RejectCar\" = 1 ; end; end; endpackage;\nthread brm_rules_execution_thread / overwrite = yes; dcl package BRM_51_ruleset_0 ruleset;\ndcl double \"RejectCar\";\nkeep \"Make\" \"Model\" \"Odometer\" \"RejectCar\";\nmethod run(); set \"HPS\".\"BADCAR_DEMO\" ( keep=(\"make\" \"vehyear\" \"model\" \"vehodo\" ) rename=(\"make\"=\"Make\" \"vehyear\"=\"Maximum_Mileage\" \"model\"=\"Model\" \"vehodo\"=\"Odometer\" ));\nruleset.execute(\"Make\", \"Maximum_Mileage\", \"Model\", \"Odometer\", \"RejectCar\"); output; end; endthread;\ndata \"PUBLIC\".\"BADCAR_DEMO_SCORE_OUTPUT\" (overwrite=yes); dcl thread brm_rules_execution_thread _t; method run(); set from _t; output; end; enddata;",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "BADCAR_DEMO_SCORE_OUTPUT",
      "outputLibraryName": "PUBLIC"
    }
    

    For clarity, here is the YAML code format for the previous JSON code example.

    
    
    
    code:
    
          package BRM_51_RuleSet_0 /overwrite=yes;
            method execute(in_out varchar "Make", in_out double "Maximum_Mileage", in_out varchar "Model",
                      in_out double "Odometer", in_out double "RejectCar");
              "RejectCar" = 0 ;
              if (Odometer > Maximum_MileageMaximum_Mileage) then do;
                "RejectCar" = 1 ;
              end;
            end;
          endpackage;
    
          thread brm_rules_execution_thread / overwrite = yes;
            dcl package BRM_51_ruleset_0 ruleset;
    
            dcl double "RejectCar";
    
            keep "Make" "Model" "Odometer" "RejectCar";
    
            method run();
              set "HPS"."BADCAR_DEMO" (
              keep=("make" "vehyear" "model" "vehodo" )
              rename=("make"="Make" "vehyear"="Maximum_Mileage" "model"="Model" "vehodo"="Odometer" ));
    
              ruleset.execute("Make", "Maximum_Mileage", "Model", "Odometer", "RejectCar");
              output;
            end;
          endthread;
    
          data "PUBLIC"."BADCAR_DEMO_SCORE_OUTPUT" (overwrite=yes);
            dcl thread brm_rules_execution_thread _t;
            method run();
              set from _t;
              output;
            end;
          enddata;
    codeType: text/vnd.sas.source.ds2
    outputTableName: BADCAR_DEMO_SCORE_OUTPUT
    outputLibraryName: PUBLIC
    
    
    application/vnd.sas.summary

    Used to provide summary information for the score definition.

    The schema is at resourceSummary.

    Resource Relationships

    Resource relationship diagram

    Root

    Path: /

    The root of the API. This resource contains links to the top-level resources in the API. The response uses the application/vnd.sas.api media type.

    The GET / response includes the following links.

    Relation Method Description
    scoreDefinitions GET Returns the first page of the collection of score definitions.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.summary.
    Response item type: application/vnd.sas.score.definition.
    createScoreDefinition POST Creates a new score definition.
    Request type: application/vnd.sas.score.definition.
    Response type: application/vnd.sas.score.definition.
    Score Definitions

    Path: /definitions

    This API provides a collection of the score definitions.

    Default page size is 20.

    The scoreDefinitions collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.score.definition resources or application/vnd.sas.score.definition.summary or application/vnd.sas.summary. (These types apply to the response for the self, collection, prev, next, first, and last links below.)

    Responses include the following links.

    Relation Method Description
    create POST Creates a new score definition in the collection.
    This link is available only when the requester has authorization to create a new score definition.
    Request type: application/vnd.sas.score.definition
    Response type: application/vnd.sas.score.definition
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    Filtering and sorting can use the following members of the scoreDefinition:

    Note: The type Inline is title case.

    Score Definition

    Path: /definitions/{definitionId}

    This API provides the score definition.

    The scoreDefinition representation is application/vnd.sas.score.definition.

    Responses include the following links.

    Relation Method Description
    up GET Returns a list of score definitions to which this score definition belongs.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.score.definition.
    Response item type: application/vnd.sas.summary.
    self GET Returns the score definition by ID.
    Response type: application/vnd.sas.score.definition.
    alternate GET Returns the score definition summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the score definition by ID.
    update GET Updates a score definition.
    Request type: application/vnd.sas.score.definition.
    Response type: application/vnd.sas.score.definition.
    mappedCode POST Returns the mapped code generated by the score object using hints.
    Request type: application/vnd.sas.score.code.generation.request.
    Response type: application/vnd.sas.score.mapped.code.
    Score Definition Summary

    Path: /definitions/{definitionId}

    This API provides the score definition summary.

    The scoreDefinition representation is application/vnd.sas.score.definition.summary.

    Responses include the following links.

    Relation Method Description
    up GET Returns a list of score definitions to which this score definition belongs.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.score.definition.
    Response item type: application/vnd.sas.score.definition.summary.
    Response item type: application/vnd.sas.summary.
    self GET Returns the score definition by ID.
    Response type: application/vnd.sas.score.definition.
    alternate GET Returns the score definition summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the score definition by ID.
    update GET Updates a score definition.
    Request type: application/vnd.sas.score.definition.
    Response type: application/vnd.sas.score.definition.
    mappedCode POST Returns the mapped code generated by the score object using hints.
    Request type: application/vnd.sas.score.code.generation.request.
    Response type: application/vnd.sas.score.mapped.code.
    Score Definition Summary

    Path: /definitions/{definitionId}

    This API provides the score definition summary.

    The scoreDefinitionSummary representation is application/vnd.sas.summary.

    Responses include the following links.

    Relation Method Description
    up GET Returns a list of score definitions to which this score definition belongs.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.summary.
    Response item type: application/vnd.sas.score.definition.
    self GET Returns the score definition by ID.
    Response type: application/vnd.sas.score.definition.
    alternate GET Returns the score definition summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the score definition by ID.
    update GET Updates a score definition.
    Request type: application/vnd.sas.score.definition.
    Response type: application/vnd.sas.score.definition.
    mappedCode POST Returns the mapped code generated by the score object using hints.
    Request type: application/vnd.sas.score.code.generation.request.
    Response type: application/vnd.sas.score.mapped.code.
    Mapped Code

    Path: /definitions/{definitionId}/mappedCode

    This API provides the mapped code generated by the score object defined in the score definition.

    The mappedCode representation is application/vnd.sas.score.mapped.code.

    Score Code Generation Request

    Path: /definitions/{definitionId}/mappedCode

    This API uses the score code generation request to generate the mapped code.

    The scoreCodeGenerationReqiest representation is application/vnd.sas.score.code.generation.request.

    Business Rules

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Business Rules API supports the creation and management of business rules. These business rules are organized within rule sets.

    Usage Notes

    Overview

    The Business Rules API manages a repository of business rules that are organized within rule sets. These rule sets enable users to perform the following actions:

    In addition, rule sets can be included in decision flows, which can also be consumed by other operational processes.

    An example of a rule set and its contained rules is a loan approval where multiple rules around various aspects of the customer need to be verified within one logical set of rules as shown below:

    Revisions

    This API enables you to not only do basic create, update, delete, and read capabilities with rule sets, but also gives users the ability to create revisions of rule sets. Users also have the capability to delete locked revisions. However, the current unlocked version cannot be deleted.

    Revisions are versions of the rule set that contain rules, which are associated with a major and minor number and they can be locked. After a revision is locked, you cannot unlock it for auditing purposes. The API controls the major and minor numbering of the revisions and locking. Users can request a major or minor revision to be created. A new number is assigned for them based on the current revisions that are available.

    After a new version is created, any existing revision is locked to prevent multiple revisions being edited at once. The ruleSetName and description are not tracked within the revision but all other fields are tracked.

    Why Use this API?

    This API manages business rules and retrieves the code to be able to leverage the rules within an operational process.

    Terminology

    rule set

    sequenced group of related business rules, which accomplish a logical business operation.

    rule

    named set of conditions, which are all logically evaluated to see whether they are true or not when executed. If all conditions are true, then all actions are executed for a rule.

    condition

    logical truth statement that evaluates to true or false, such as x > 10.

    action

    programmatic execution that can assign a value to a term or find reference data from the results of a rule.

    signature

    set of local business terms that are leveraged by a rule set as variables. Each term has an input and output behavior to define the necessary inputs to execute the rule set and define what is produced for the user as output when executed. In order or a rule to be considered valid within a rule set, it must reference terms only within the signature.

    term

    variable typically mapped to data during the execution of a rule and is used in signatures, conditions or action expressions, and rules to form logical values.

    lookup

    referenced domain within the Reference Data API, which is used to perform the business rules. At execution or publish time the domain contents that is used is determined by what is considered the production or active contents for the domain.

    revision

    version of the rule set content.

    DS2

    a SAS proprietary programming language that combines SAS DATA step processing with standard operations of the ANSI SQL:1999 standard. Table Server Programming Language statements can be embedded within Table Server SQL statements. This is the primary target when code is generated by the Business Rules API. Functions leveraged within expressions provided to this API must be documented DS2 functions to properly execute the code. When using any complex type condition or action, DS2 syntax should be used.

    Error Codes

    HTTP Status Code Error Code Description
    400 1006 The resource ID is not valid.
    400 1017 The string is not valid for the member.
    400 13704 This term cannot be modified.
    400 13705 This analysis type is not supported.
    400 13706 This input type is not supported.
    400 13707 This data type is not supported.
    400 13708 The order of the rules is not valid.
    400 13760 This rule expression conversion is not supported.
    400 13761 The source rule expression type and target type are the same.
    400 13762 The provided rule expression could not be parsed during the conversion process.
    400 13711 The expression type is not valid for the rule set.
    409 13703 There is a duplicate rule or term name within the rule set.
    412 1014 The If-Unmodified-Since value for the update is not valid.
    428 1012 The If-Unmodified-Since header for the update is missing.
    500 13709 Invalid rule expressions were found during code generation.
    500 13710 The code could not be generated due to invalid mappings.
    500 13731 There was a mapped code request with an empty data mapping.
    500 13742 There are no rules within the rule set. The code was not generated.
    503 1200 The license has expired.

    Operations

    Root

    Contains the operations for the root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/businessRules/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/businessRules/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns a list of links to the top level resources in this API.

    Example responses

    BusinessRules root content.

    {
      "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"
        }
      ]
    }
    
    {
      "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"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description

    Rule Sets

    Contains the operations for creating, reading, and deleting rule sets.

    Get all rule sets

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'string'
    };
    
    fetch('https://example.com/businessRules/ruleSets',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'string'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets

    Returns a resource collection of all the rule sets.

    Parameters
    Name In Type Required Description
    filter query string(filter-criteria) false An expression for filtering the collection. Valid expressions include eq(member,"string"). Allowed members are id, name, description, modifiedTimeStamp, creationTimeStamp, modifiedBy, and createdBy.
    sortBy query string(sort-criteria) false 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.
    start query integer false The starting index of the first item on a page. The index is 0-based. The default is 0.
    limit query integer false 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.
    Accept-Item header string false An alternative media-type that the service recognizes. If the media-type is not one that the service can provide, a 406 response is returned.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "Loan Score Approval",
          "signature": [
            {
              "name": "customerName",
              "dataType": "string",
              "direction": "input"
            },
            {
              "name": "creditScore",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "approved",
              "dataType": "integer",
              "direction": "output"
            }
          ]
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not acceptable.

    {
      "httpStatusCode": 406,
      "version": 2
    }
    
    {
      "httpStatusCode": 406,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleSetCollection
    400 Bad Request The request was invalid. errorCollection
    406 Not Acceptable 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. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string No description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a rule set

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule.set+json' \
      -H 'Accept: application/vnd.sas.business.rule.set+json'
    
    
    const inputBody = '{
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule.set+json',
      'Accept':'application/vnd.sas.business.rule.set+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule.set+json',
      'Accept': 'application/vnd.sas.business.rule.set+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule.set+json"},
            "Accept": []string{"application/vnd.sas.business.rule.set+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets

    Creates a new rule set.

    Body parameter

    {
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    parentFolderUri query string(/folders/folders/{parentFolderId}) false A folder in which the new rule set is placed.
    fromRevisionUri query string(/businessRules/ruleSets/{rulesetId}/revisions/{revisionId}) false 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}'
    body body ruleSetCollection true The rule set object that should be created.

    Example responses

    201 Response

    {
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A folder was created. ruleSetCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    201 Last-Modified string date-time The last time the rule set was changed.
    201 Location string uri No description

    Get the headers of a rule set

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/businessRules/ruleSets/{ruleSetId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/businessRules/ruleSets/{ruleSetId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/businessRules/ruleSets/{ruleSetId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /ruleSets/{ruleSetId}

    Returns the headers for the specified rule set.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The last time the rule set was changed.

    Get a rule set

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.business.rule.set+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.business.rule.set+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.business.rule.set+json'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.business.rule.set+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}

    Returns the rule set for the provided ID.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.

    Example responses

    200 Response

    {
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleSetCollection
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The last time the rule set was changed.

    Update a rule set

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/businessRules/ruleSets/{ruleSetId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule.set+json' \
      -H 'Accept: application/vnd.sas.business.rule.set+json' \
      -H 'If-Unmodified-Since: Wed, 06 Jan 2021 20:31:19 GMT'
    
    
    const inputBody = '{
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule.set+json',
      'Accept':'application/vnd.sas.business.rule.set+json',
      'If-Unmodified-Since': 'Wed, 06 Jan 2021 20:31:19 GMT'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule.set+json',
      'Accept': 'application/vnd.sas.business.rule.set+json',
      'If-Unmodified-Since': 'Wed, 06 Jan 2021 20:31:19 GMT'
    }
    
    r = requests.put('https://example.com/businessRules/ruleSets/{ruleSetId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule.set+json"},
            "Accept": []string{"application/vnd.sas.business.rule.set+json"},
            "If-Unmodified-Since": []string{"Wed, 06 Jan 2021 20:31:19 GMT"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/businessRules/ruleSets/{ruleSetId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /ruleSets/{ruleSetId}

    Updates the rule set with the provided content.

    Body parameter

    {
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    If-Unmodified-Since header string(date-time) true The last date and time of the contents retrieved for the rule set on which you are basing your update.
    body body ruleSetCollection false The rule set body that is updated with the existing rule set.

    Example responses

    200 Response

    {
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    
    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleSetCollection
    400 Bad Request The request was invalid. errorCollection
    404 Not Found No resource exists at the requested path. errorCollection
    412 Precondition Failed The If-Unmodified-Since request header did not match the resource's last modified timestamp. errorCollection
    428 Precondition Required The request headers did not include a If-Unmodified-Since precondition. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The last time the rule set was changed.

    Delete a rule set

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/businessRules/ruleSets/{ruleSetId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.delete('https://example.com/businessRules/ruleSets/{ruleSetId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/businessRules/ruleSets/{ruleSetId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /ruleSets/{ruleSetId}

    Deletes the specified rule set.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    204 No Content The rule set was deleted. None
    404 Not Found No rule set exists at the requested path. errorCollection

    Get execution order of rules

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/order \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.selection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.selection+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/order',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.selection+json'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/order', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.selection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/order", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/order

    Returns the order of the rules within the rule set.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.

    Example responses

    200 Response

    {
      "version": 0,
      "template": "string",
      "type": "id",
      "resources": [
        "string"
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No rule set exists at the requested path. errorCollection
    Response Schema

    Status Code 200

    Selection

    Name Type Required Restrictions Description
    » version integer true none The schema version number of this media type. This representation is version 1.
    » template string false none 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 false none Specifies whether the resources array contains IDs, URIs, or both.

    "id"
    the array contains resource identifiers only. This is the default if "type" is omitted.

    "uri"
    the array contains resource URIs

    "mixed"
    the array contains a mixture of identifiers and URIs.

    » resources [string] true none An array of resource IDs or URIs
    » links [link] false none An array of links to related resources and actions.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Enumerated Values
    Property Value
    type id
    type uri
    type mixed
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The last date and time the rule set was modified.

    Update rules execution order

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/businessRules/ruleSets/{ruleSetId}/order \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.selection+json' \
      -H 'Accept: application/vnd.sas.selection+json' \
      -H 'If-Unmodified-Since: Wed, 06 Jan 2021 20:31:19 GMT'
    
    
    const inputBody = '{
      "version": 0,
      "template": "string",
      "type": "id",
      "resources": [
        "string"
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.selection+json',
      'Accept':'application/vnd.sas.selection+json',
      'If-Unmodified-Since': 'Wed, 06 Jan 2021 20:31:19 GMT'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/order',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.selection+json',
      'Accept': 'application/vnd.sas.selection+json',
      'If-Unmodified-Since': 'Wed, 06 Jan 2021 20:31:19 GMT'
    }
    
    r = requests.put('https://example.com/businessRules/ruleSets/{ruleSetId}/order', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.selection+json"},
            "Accept": []string{"application/vnd.sas.selection+json"},
            "If-Unmodified-Since": []string{"Wed, 06 Jan 2021 20:31:19 GMT"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/businessRules/ruleSets/{ruleSetId}/order", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /ruleSets/{ruleSetId}/order

    Returns the execution order for rules within the rule set based on the provided body.

    Body parameter

    {
      "version": 0,
      "template": "string",
      "type": "id",
      "resources": [
        "string"
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    If-Unmodified-Since header string(date-time) true The last date and time of the contents retrieved for the rule set on which you are basing your update.
    ruleSetId path string true The rule set ID.
    body body #/paths/~1ruleSets~1%7BruleSetId%7D~1order/get/responses/200/content/application~1vnd.sas.selection%2Bjson/schema true Customized ordering for the rules during execution.

    Example responses

    200 Response

    {
      "version": 0,
      "template": "string",
      "type": "id",
      "resources": [
        "string"
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    
    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorCollection
    404 Not Found No resource exists at the requested path. errorCollection
    412 Precondition Failed The If-Unmodified-Since request header did not match the resource's last modified timestamp. errorCollection
    428 Precondition Required The request headers did not include a If-Unmodified-Since precondition. errorCollection
    Response Schema

    Status Code 200

    Selection

    Name Type Required Restrictions Description
    » version integer true none The schema version number of this media type. This representation is version 1.
    » template string false none 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 false none Specifies whether the resources array contains IDs, URIs, or both.

    "id"
    the array contains resource identifiers only. This is the default if "type" is omitted.

    "uri"
    the array contains resource URIs

    "mixed"
    the array contains a mixture of identifiers and URIs.

    » resources [string] true none An array of resource IDs or URIs
    » links [link] false none An array of links to related resources and actions.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Enumerated Values
    Property Value
    type id
    type uri
    type mixed
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time Date and time the rule set was last changed.

    Get rule set code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/code \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    
    const headers = {
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/code',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/code', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/code", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/code

    Returns the code for integrating within another program so that program is able to run the rule set.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    codeTarget query string false 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.
    lookupMode query string false 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.
    isGeneratingRuleFiredColumn query boolean false Determines whether the rule fired columns are included in the method signatures within the return package code. The default is 'true'.
    Detailed descriptions

    codeTarget: 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.

    Enumerated Values
    Parameter Value
    codeTarget MICROANALYTICSERVICE
    codeTarget CAS
    lookupMode format
    lookupMode inline
    lookupMode package

    Example responses

    200 Response

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The date and time that the rule set was last modified.

    Get the mapped code for a rule set

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/mappedCode

    Returns the code to be able to run the rule set based on the provided data and mapping information in the request.

    Body parameter

    {
      "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    body body scoreCodeGenerationRequest true The information for the scoreDefinitionId and hints.

    Example responses

    200 Response

    {
      "code": "/* DS2 code of an object, which generates an XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorCollection
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 1.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get rule set code without score definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode#unbound \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request.unbound+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode#unbound',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode#unbound', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request.unbound+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode#unbound", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/mappedCode#unbound

    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.

    Body parameter

    {
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    body body #/components/requestBodies/unboundScoreCodeGenerationRequest/content/application~1vnd.sas.score.code.generation.request.unbound%2Bjson/schema false none

    Example responses

    200 Response

    {
      "code": "/* DS2 code of an object, which generates an XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorCollection
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 1.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get rule set code not bound to a score definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode#unboundCodeOnly \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request.unbound+json' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    const inputBody = '{
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode#unboundCodeOnly',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode#unboundCodeOnly', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request.unbound+json"},
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/mappedCode#unboundCodeOnly", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/mappedCode#unboundCodeOnly

    Returns the code directly as text without being wrapped in a JSON model, that a user can use 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.

    Body parameter

    {
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    body body #/components/requestBodies/unboundScoreCodeGenerationRequest/content/application~1vnd.sas.score.code.generation.request.unbound%2Bjson/schema false none

    Example responses

    200 Response

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get rule set analysis code

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/analysisCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.analysis.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.analysis.code+json'
    
    
    const inputBody = '{
      "scoreExecutionId": "6f4bced9-5bbd-476c-8ef8-3378678b0702",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept':'application/vnd.sas.score.analysis.code+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/analysisCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.analysis.code+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/analysisCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.analysis.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.analysis.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/analysisCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/analysisCode

    Returns the analysis code to generate rule fired reports based on the scoring definition.

    Body parameter

    {
      "scoreExecutionId": "6f4bced9-5bbd-476c-8ef8-3378678b0702",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    body body analysisCodeGenerationRequest true Information that describes the specific execution to which the analysis code should be applied (as specified by the scoreExecutionId) and the type of analysis to be performed by the code.

    Example responses

    200 Response

    {
      "code": "/* ds2 code of an object which generates XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS",
      "analysisType": "ruleFiredSummary"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorCollection
    Response Schema

    Status Code 200

    Analysis Code

    Name Type Required Restrictions Description
    » code string true none Executable code generated by a Score Object.
    » codeType string(media-type) true none Type of the code.
    » outputTableName string true none Name of the table that will be generated when the generated code is executed.
    » outputLibraryName string true none Name of the library where the table will be generated when the code is executed.
    » analysisType string true none Type of analysis which the code will perform.
    » version integer false none This media type's schema version number. This representation is version 1.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get rule set analysis code as text

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/analysisCode#codeOnly \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.analysis.code.generation.request+json' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    const inputBody = '{
      "scoreExecutionId": "6f4bced9-5bbd-476c-8ef8-3378678b0702",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/analysisCode#codeOnly',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/analysisCode#codeOnly', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.analysis.code.generation.request+json"},
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/analysisCode#codeOnly", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/analysisCode#codeOnly

    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.

    Body parameter

    {
      "scoreExecutionId": "6f4bced9-5bbd-476c-8ef8-3378678b0702",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    body body analysisCodeGenerationRequest true Information that describes the specific execution to which the analysis code should be applied (as specified by the scoreExecutionId) and the type of analysis to be performed by the code.

    Example responses

    200 Response

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the decision step code for a rule set

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/decisionStepCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/decisionStepCode',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/decisionStepCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/decisionStepCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/decisionStepCode

    Returns the decision step code for the specified rule set.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The identifier of the rule set.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "code": "string",
      "type": "string",
      "signature": [
        {
          "name": "string",
          "dataType": "string",
          "direction": "string",
          "length": 0,
          "dataGridExtension": [
            {
              "name": "string",
              "length": 0,
              "dataType": "string"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No rule set exists at the requested path. errorCollection
    Response Schema

    Status Code 200

    Decision Step Code

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string false none The name of the object used in decision step.
    » description string false none The description of the object used in decision step.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » code string false none The code of the object used in the decision step.
    » type string false none The object type of the object used in the decision step.
    » signature [any] false none Signature variables of the object used in the decision step.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    » links [link] false none Zero or more links to related resources or operations.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string No description

    Convert a rule action to a target type

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/actionConversion \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule.action.conversion+json' \
      -H 'Accept: application/vnd.sas.business.rule.action.conversion+json'
    
    
    const inputBody = '{
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "source": {
        "id": "string",
        "type": "assignment",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "targetType": "assignment",
      "convertedAction": {
        "id": "string",
        "type": "assignment",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "version": 0
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule.action.conversion+json',
      'Accept':'application/vnd.sas.business.rule.action.conversion+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/actionConversion',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule.action.conversion+json',
      'Accept': 'application/vnd.sas.business.rule.action.conversion+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/actionConversion', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule.action.conversion+json"},
            "Accept": []string{"application/vnd.sas.business.rule.action.conversion+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/actionConversion", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/actionConversion

    Convert a rule action to a new target type.

    Body parameter

    {
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "source": {
        "id": "string",
        "type": "assignment",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "targetType": "assignment",
      "convertedAction": {
        "id": "string",
        "type": "assignment",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "version": 0
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    body body ruleActionConversion false The action conversion request.

    Example responses

    200 Response

    {
      "id": "string",
      "type": "assignment",
      "expression": "string",
      "lookup": {
        "id": "string",
        "name": "string"
      },
      "term": {
        "id": "string",
        "name": "string",
        "description": "string",
        "defaultValue": {},
        "length": 0,
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "dataType": "string",
        "direction": "input",
        "dataGridExtension": [
          {
            "id": "string",
            "name": "string",
            "length": 0,
            "autoPopulate": true,
            "dataType": "string"
          }
        ],
        "globalVariableId": "string",
        "generateDataGridColumns": true,
        "legacy": true
      },
      "status": "valid",
      "statusMessage": "string"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The converted rule action. ruleAction
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Convert a rule condition to a target type

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/conditionConversion \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule.condition.conversion+json' \
      -H 'Accept: application/vnd.sas.business.rule.condition.conversion+json'
    
    
    const inputBody = '{
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "source": {
        "id": "string",
        "type": "decisionTable",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "targetType": "decisionTable",
      "convertedCondition": {
        "id": "string",
        "type": "decisionTable",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "version": 0
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule.condition.conversion+json',
      'Accept':'application/vnd.sas.business.rule.condition.conversion+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/conditionConversion',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule.condition.conversion+json',
      'Accept': 'application/vnd.sas.business.rule.condition.conversion+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/conditionConversion', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule.condition.conversion+json"},
            "Accept": []string{"application/vnd.sas.business.rule.condition.conversion+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/conditionConversion", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/conditionConversion

    Convert a rule condition to a new target type.

    Body parameter

    {
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "source": {
        "id": "string",
        "type": "decisionTable",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "targetType": "decisionTable",
      "convertedCondition": {
        "id": "string",
        "type": "decisionTable",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "version": 0
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    body body ruleConditionConversion false The condition conversion request.

    Example responses

    200 Response

    {
      "id": "string",
      "type": "decisionTable",
      "expression": "string",
      "lookup": {
        "id": "string",
        "name": "string"
      },
      "term": {
        "id": "string",
        "name": "string",
        "description": "string",
        "defaultValue": {},
        "length": 0,
        "createdBy": "string",
        "creationTimeStamp": "2019-08-24T14:15:22Z",
        "modifiedBy": "string",
        "modifiedTimeStamp": "2019-08-24T14:15:22Z",
        "dataType": "string",
        "direction": "input",
        "dataGridExtension": [
          {
            "id": "string",
            "name": "string",
            "length": 0,
            "autoPopulate": true,
            "dataType": "string"
          }
        ],
        "globalVariableId": "string",
        "generateDataGridColumns": true,
        "legacy": true
      },
      "status": "valid",
      "statusMessage": "string"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The converted rule condition. ruleCondition
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Retrieve a collection of errors

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/ruleValidations \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule+json' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    const inputBody = '{
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule+json',
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/ruleValidations',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule+json',
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/ruleValidations', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule+json"},
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/ruleValidations", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/ruleValidations

    Tests the validation of the rule content and returns a list of errors.

    Body parameter

    {
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The identifier of the rule set.
    body body ruleCollection true The rules that need to be validated.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "message": "string",
          "id": "string",
          "errorCode": 0,
          "httpStatusCode": 0,
          "details": [
            "string"
          ],
          "remediation": "string",
          "errors": [
            null
          ],
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The validations were created. errorCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get all revisions of a rule set

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'string'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'string'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/revisions

    Returns all the revisions that were created for the rule set.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    filter query string(filter-criteria) false An expression for filtering the collection. Valid expressions include eq(member,"string"). Allowed members are id, name, description, modifiedTimeStamp, creationTimeStamp, modifiedBy, and createdBy.
    sortBy query string(sort-criteria) false 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.
    start query integer false The starting index of the first item on a page. The index is 0-based. The default is 0.
    limit query integer false 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.
    Accept-Item header string false 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.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "Loan Score Approval",
          "signature": [
            {
              "name": "customerName",
              "dataType": "string",
              "direction": "input"
            },
            {
              "name": "creditScore",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "approved",
              "dataType": "integer",
              "direction": "output"
            }
          ]
        }
      ]
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleSetCollection
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule.set+json' \
      -H 'Accept: application/vnd.sas.business.rule.set+json'
    
    
    const inputBody = '{
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule.set+json',
      'Accept':'application/vnd.sas.business.rule.set+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule.set+json',
      'Accept': 'application/vnd.sas.business.rule.set+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule.set+json"},
            "Accept": []string{"application/vnd.sas.business.rule.set+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/revisions

    Creates a new revision for the rule set. With this request, you supply the content that you want to initialize for a new revision.

    Body parameter

    {
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionType query string false 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.
    fromRevisionUri query string(/businessRules/ruleSets/{rulesetId}/revisions/{revisionId}) false 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}'
    body body ruleSetCollection true New content with which to create a rule set revision.
    Enumerated Values
    Parameter Value
    revisionType major
    revisionType minor

    Example responses

    201 Response

    {
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A rule set revision was created. ruleSetCollection
    400 Bad Request The request was invalid. errorCollection
    404 Not Found No resource exists at the requested path. errorCollection
    428 Precondition Required The request headers did not include a If-Unmodified-Since precondition. errorCollection
    Response Headers
    Status Header Type Format Description
    201 Last-Modified string date-time The last date and time the rule set was revised.
    201 Location string uri No description

    Get the headers of a rule set revision

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /ruleSets/{ruleSetId}/revisions/{revisionId}

    Returns the headers for the specific rule set revision that was requested.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The last time the rule set revision was changed.

    Get a rule set revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.business.rule.set+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.business.rule.set+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.business.rule.set+json'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.business.rule.set+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/revisions/{revisionId}

    Returns the content for the specific rule set revision that was requested.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.

    Example responses

    200 Response

    {
      "name": "Loan Score Approval",
      "signature": [
        {
          "name": "customerName",
          "dataType": "string",
          "direction": "input"
        },
        {
          "name": "creditScore",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "approved",
          "dataType": "integer",
          "direction": "output"
        }
      ]
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleSetCollection
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The last time the rule set revision was changed.

    Delete a rule set revision

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /ruleSets/{ruleSetId}/revisions/{revisionId}

    Deletes the specified locked rule set revision. To preserve editable content for users deletion of unlocked versions is not allowed.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.
    Responses
    Status Meaning Description Schema
    204 No Content The rule set revision was deleted. None

    Get the rule set revision as a CSV file

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}#export \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/csv'
    
    
    
    const headers = {
      'Accept':'text/csv'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}#export',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/csv'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}#export', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/csv"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}#export", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/revisions/{revisionId}#export

    Exports all content for the specific rule set revisions to a CSV file, which matches the CSV format of /rules endpoint.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.

    Example responses

    200 Response

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The date and time that the rule set was last modified.

    Get the rule execution order for the revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/order \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.selection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.selection+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/order',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.selection+json'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/order', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.selection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/order", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/revisions/{revisionId}/order

    Gets the order of the rules within the provided rule set revision.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.

    Example responses

    200 Response

    {
      "version": 0,
      "template": "string",
      "type": "id",
      "resources": [
        "string"
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No resource exists at the requested path. errorCollection
    Response Schema

    Status Code 200

    Selection

    Name Type Required Restrictions Description
    » version integer true none The schema version number of this media type. This representation is version 1.
    » template string false none 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 false none Specifies whether the resources array contains IDs, URIs, or both.

    "id"
    the array contains resource identifiers only. This is the default if "type" is omitted.

    "uri"
    the array contains resource URIs

    "mixed"
    the array contains a mixture of identifiers and URIs.

    » resources [string] true none An array of resource IDs or URIs
    » links [link] false none An array of links to related resources and actions.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Enumerated Values
    Property Value
    type id
    type uri
    type mixed
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The last time the rule set revision was changed.

    Get the code of a rule set revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/code \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    
    const headers = {
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/code',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/code', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/code", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/revisions/{revisionId}/code

    Returns the package code for a rule set revision.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.
    codeTarget query string false 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.
    lookupMode query string false 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.
    isGeneratingRuleFiredColumn query boolean false Determines whether the rule fired columns are included in the method signatures within the return package code. The default is 'true'.
    Detailed descriptions

    codeTarget: 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.

    Enumerated Values
    Parameter Value
    codeTarget MICROANALYTICSERVICE
    codeTarget CAS
    lookupMode format
    lookupMode inline
    lookupMode package

    Example responses

    200 Response

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string No description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the mapped code of a rule set revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode

    Returns the code bound to the data that is specified in the score request for execution.

    Body parameter

    {
      "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.
    body body scoreCodeGenerationRequest true The information for the scoreDefinitionId and hints.

    Example responses

    200 Response

    {
      "code": "/* DS2 code of an object, which generates an XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorCollection
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 1.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get rule set revision code without a score definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unbound \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request.unbound+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unbound',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unbound', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request.unbound+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unbound", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unbound

    Returns the code to be able to run the rule set revision based on mapping to a static input and output data set of SASEP.IN and SASEP.OUT rather than binding to a score definition.

    Body parameter

    {
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.
    body body #/components/requestBodies/unboundScoreCodeGenerationRequest/content/application~1vnd.sas.score.code.generation.request.unbound%2Bjson/schema true The information for the mapping and hints.

    Example responses

    200 Response

    {
      "code": "/* DS2 code of an object, which generates an XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorCollection
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 1.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get code for rule set revision not bound to score definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unboundCodeOnly \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request.unbound+json' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    const inputBody = '{
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unboundCodeOnly',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unboundCodeOnly', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request.unbound+json"},
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unboundCodeOnly", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/revisions/{revisionId}/mappedCode#unboundCodeOnly

    Returns the code directly as text without being wrapped in a JSON model, that a user can use to be able to run the rule set revision based on mapping to a static input and output data set of SASEP.IN and SASEP.OUT rather than binding to a score definition.

    Body parameter

    {
      "mappings": [
        {
          "variableName": "string",
          "mappingType": "datasource",
          "mappingValue": 0
        }
      ],
      "hints": {
        "property1": "string",
        "property2": "string"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.
    body body #/components/requestBodies/unboundScoreCodeGenerationRequest/content/application~1vnd.sas.score.code.generation.request.unbound%2Bjson/schema true The information for the mapping and hints to be used during building the execution code.

    Example responses

    200 Response

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the analysis code of a rule set revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.analysis.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.analysis.code+json'
    
    
    const inputBody = '{
      "scoreExecutionId": "6f4bced9-5bbd-476c-8ef8-3378678b0702",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept':'application/vnd.sas.score.analysis.code+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.analysis.code+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.analysis.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.analysis.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode

    Returns the analysis code necessary for collecting the information about the rules that fired.

    Body parameter

    {
      "scoreExecutionId": "6f4bced9-5bbd-476c-8ef8-3378678b0702",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.
    body body analysisCodeGenerationRequest true 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.

    Example responses

    200 Response

    {
      "code": "/* ds2 code of an object which generates XYZ output table */",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "XYZ",
      "outputLibraryName": "HPS",
      "analysisType": "ruleFiredSummary"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorCollection
    Response Schema

    Status Code 200

    Analysis Code

    Name Type Required Restrictions Description
    » code string true none Executable code generated by a Score Object.
    » codeType string(media-type) true none Type of the code.
    » outputTableName string true none Name of the table that will be generated when the generated code is executed.
    » outputLibraryName string true none Name of the library where the table will be generated when the code is executed.
    » analysisType string true none Type of analysis which the code will perform.
    » version integer false none This media type's schema version number. This representation is version 1.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get analysis code as text for rule set revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode#codeOnly \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.analysis.code.generation.request+json' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    const inputBody = '{
      "scoreExecutionId": "6f4bced9-5bbd-476c-8ef8-3378678b0702",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode#codeOnly',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode#codeOnly', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.analysis.code.generation.request+json"},
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode#codeOnly", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/revisions/{revisionId}/analysisCode#codeOnly

    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.

    Body parameter

    {
      "scoreExecutionId": "6f4bced9-5bbd-476c-8ef8-3378678b0702",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.
    body body analysisCodeGenerationRequest true 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.

    Example responses

    200 Response

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the decision step code for a rule set revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/decisionStepCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/decisionStepCode',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/decisionStepCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/decisionStepCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/revisions/{revisionId}/decisionStepCode

    Returns the decision step code for the specified rule set revision.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "code": "string",
      "type": "string",
      "signature": [
        {
          "name": "string",
          "dataType": "string",
          "direction": "string",
          "length": 0,
          "dataGridExtension": [
            {
              "name": "string",
              "length": 0,
              "dataType": "string"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No rule set revision exists at the requested path. errorCollection
    Response Schema

    Status Code 200

    Decision Step Code

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string false none The name of the object used in decision step.
    » description string false none The description of the object used in decision step.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » code string false none The code of the object used in the decision step.
    » type string false none The object type of the object used in the decision step.
    » signature [any] false none Signature variables of the object used in the decision step.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    » links [link] false none Zero or more links to related resources or operations.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description

    Rules

    Contains the operations for importing, exporting, and querying rules directly.

    Get all the rules for a rule set

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/rules \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'string'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/rules',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'string'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/rules', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/rules", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/rules

    Returns the collection of rules for a specified rule set.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The ID of the rule set to match.
    start query integer false The starting index of the first item on a page. The index is 0-based. The default is 0.
    limit query integer false 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.
    filter query string(filter-criteria) false The criteria for filtering the function categories. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the function categories. See Sorting in REST APIs.
    Accept-Item header string false 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.
    Detailed descriptions

    filter: The criteria for filtering the function categories. See Filtering in REST APIs.

    sortBy: The criteria for sorting the function categories. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "Age Requirements",
          "conditional": "if",
          "ruleFiredTrackingEnabled": true
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a rule

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/ruleSets/{ruleSetId}/rules \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule+json' \
      -H 'Accept: application/vnd.sas.business.rule+json'
    
    
    const inputBody = '{
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule+json',
      'Accept':'application/vnd.sas.business.rule+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/rules',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule+json',
      'Accept': 'application/vnd.sas.business.rule+json'
    }
    
    r = requests.post('https://example.com/businessRules/ruleSets/{ruleSetId}/rules', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule+json"},
            "Accept": []string{"application/vnd.sas.business.rule+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/ruleSets/{ruleSetId}/rules", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /ruleSets/{ruleSetId}/rules

    Creates a rule within the rule set.

    Body parameter

    {
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The identifier of the rule set.
    createVariables query boolean false 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.
    body body ruleCollection true Rules to add to a rule set.

    Example responses

    201 Response

    {
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The rule was created. ruleCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    201 Last-Modified string date-time The time at which the rule was last modified.
    201 Location string uri No description

    Get the headers for a rule

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /ruleSets/{ruleSetId}/rules/{rid}

    Returns the headers for the rule object.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    rid path string true The rule's ID.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The time at which the rule was last modified.

    Get rule details

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.business.rule+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.business.rule+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.business.rule+json'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.business.rule+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/rules/{rid}

    Returns the details of a rule.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    rid path string true The rule ID.

    Example responses

    200 Response

    {
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleCollection
    404 Not Found No rule ID exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The time at which the rule was last changed.

    Update a rule

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule+json' \
      -H 'Accept: application/vnd.sas.business.rule+json' \
      -H 'If-Unmodified-Since: Wed, 06 Jan 2021 20:31:19 GMT'
    
    
    const inputBody = '{
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule+json',
      'Accept':'application/vnd.sas.business.rule+json',
      'If-Unmodified-Since': 'Wed, 06 Jan 2021 20:31:19 GMT'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule+json',
      'Accept': 'application/vnd.sas.business.rule+json',
      'If-Unmodified-Since': 'Wed, 06 Jan 2021 20:31:19 GMT'
    }
    
    r = requests.put('https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule+json"},
            "Accept": []string{"application/vnd.sas.business.rule+json"},
            "If-Unmodified-Since": []string{"Wed, 06 Jan 2021 20:31:19 GMT"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /ruleSets/{ruleSetId}/rules/{rid}

    Updates the rule with new rule content.

    Body parameter

    {
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }
    
    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    rid path string true The rule ID.
    createVariables query boolean false 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.
    If-Unmodified-Since header string(date-time) false The last date and time of the contents retrieved for the rule on which you are basing your update.
    body body ruleCollection true The rule body with which to update the existing rule content.

    Example responses

    200 Response

    {
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    
    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleCollection
    400 Bad Request The request was invalid. errorCollection
    404 Not Found No resource exists at the requested path. errorCollection
    412 Precondition Failed The If-Unmodified-Since request header did not match the resource's last modified timestamp. errorCollection
    428 Precondition Required The request headers did not include an If-Unmodified-Since precondition. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The time at which the rule was last modified.

    Delete a rule

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.delete('https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/businessRules/ruleSets/{ruleSetId}/rules/{rid}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /ruleSets/{ruleSetId}/rules/{rid}

    Deletes the rule from the rule set.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    rid path string true The rule ID.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    204 No Content The resource was deleted. None
    404 Not Found No rule ID exists at the requested path. errorCollection

    Get all rules for a revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: string'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'string'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'string'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/revisions/{revisionId}/rules

    Returns the rules associated with that rule set revision.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID that is to be matched.
    revisionId path string true The rule set revision ID.
    filter query string(filter-criteria) false An expression for filtering the collection. Valid expressions include eq(member,"string"). Allowed members are id, name, description, modifiedTimeStamp, creationTimeStamp, modifiedBy, and createdBy.
    sortBy query string(sort-criteria) false 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.
    start query integer false The starting index of the first item on a page. The index is 0-based. The default is 0.
    limit query integer false 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.
    Accept-Item header string false 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.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "Age Requirements",
          "conditional": "if",
          "ruleFiredTrackingEnabled": true
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the headers of a rule for a revision

    Code samples

    # You can also use wget
    curl -X HEAD https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid}',
    {
      method: 'HEAD',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.head('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("HEAD", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    HEAD /ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid}

    Returns a specific rule header for this rule set revision.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.
    rid path string true The rule ID.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. None
    404 Not Found No resource exists at the requested path errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The last time the rule was changed.

    Get rule revision details

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.business.rule+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.business.rule+json'
    };
    
    fetch('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.business.rule+json'
    }
    
    r = requests.get('https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.business.rule+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /ruleSets/{ruleSetId}/revisions/{revisionId}/rules/{rid}

    Returns the rule's state for the revision provided.

    Parameters
    Name In Type Required Description
    ruleSetId path string true The rule set ID.
    revisionId path string true The rule set revision ID.
    rid path string true The rule ID.

    Example responses

    200 Response

    {
      "name": "Age Requirements",
      "conditional": "if",
      "ruleFiredTrackingEnabled": true
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleCollection
    404 Not Found No rule ID exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string date-time The last time the rule was changed.

    Get all rules

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/rules \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/businessRules/rules',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/businessRules/rules', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/rules", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /rules

    Returns all rules based on a query for all rule sets.

    Parameters
    Name In Type Required Description
    start query integer false The starting index of the first item on a page. The index is 0-based. The default is 0.
    limit query integer false The number of items to return on each page.
    filter query string(filter-criteria) false An expression for filtering the collection. Valid expressions include eq(member,"string"). Allowed members are id, name, description, modifiedTimeStamp, creationTimeStamp, modifiedBy, and createdBy.
    sortBy query string(sort-criteria) false 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.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "Age Requirements",
          "conditional": "if",
          "ruleFiredTrackingEnabled": true
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. ruleQueryCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Export rules to a CSV file

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/rules#import \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/csv'
    
    
    
    const headers = {
      'Accept':'text/csv'
    };
    
    fetch('https://example.com/businessRules/rules#import',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/csv'
    }
    
    r = requests.get('https://example.com/businessRules/rules#import', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/csv"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/rules#import", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /rules#import

    Exports all rules for all rule sets to a CSV file.

    Parameters
    Name In Type Required Description
    folderPath query string false 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.
    ruleSetName query string false Name of the rule set to match.

    Example responses

    200 Response

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Import rules from a CSV file

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/rules#import \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: text/csv' \
      -H 'Accept: multipart/mixed'
    
    
    const inputBody = 'string';
    const headers = {
      'Content-Type':'text/csv',
      'Accept':'multipart/mixed'
    };
    
    fetch('https://example.com/businessRules/rules#import',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'text/csv',
      'Accept': 'multipart/mixed'
    }
    
    r = requests.post('https://example.com/businessRules/rules#import', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"text/csv"},
            "Accept": []string{"multipart/mixed"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/rules#import", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /rules#import

    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.

    Body parameter

    Parameters
    Name In Type Required Description
    body body string true Rows of CSV formatted data for importing rules. See the text/csv media type definition within this API's documentation.

    Example responses

    201 Response

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created Success and failure responses from CSV import processing. See multipart/mixed media type definition within this API's documentation. string
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    201 Content-Type string 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"

    Function Categories

    Contains the operations for creating, reading, and deleting function categories.

    Get a collection of function categories

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/functionCategories \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/businessRules/functionCategories',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/businessRules/functionCategories', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/functionCategories", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /functionCategories

    Returns a collection of function categories based on the specified pagination, filtering, and sorting options.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first function category to return.
    limit query integer(int32) false The maximum number of function categories to return.
    filter query string(filter-criteria) false The criteria for filtering the function categories. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the function categories. See Sorting in REST APIs.
    Detailed descriptions

    filter: The criteria for filtering the function categories. See Filtering in REST APIs.

    sortBy: The criteria for sorting the function categories. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "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.",
          "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
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK A collection of function categories. functionCategoryCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description

    Create a function category

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/functionCategories \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule.function.category+json' \
      -H 'Accept: application/vnd.sas.business.rule.function.category+json'
    
    
    const inputBody = '{
      "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.",
      "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
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule.function.category+json',
      'Accept':'application/vnd.sas.business.rule.function.category+json'
    };
    
    fetch('https://example.com/businessRules/functionCategories',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule.function.category+json',
      'Accept': 'application/vnd.sas.business.rule.function.category+json'
    }
    
    r = requests.post('https://example.com/businessRules/functionCategories', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule.function.category+json"},
            "Accept": []string{"application/vnd.sas.business.rule.function.category+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/functionCategories", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /functionCategories

    Creates a new function category.

    Body parameter

    {
      "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.",
      "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
    }
    
    Parameters
    Name In Type Required Description
    body body functionCategoryCollection true Properties of the function category to create.

    Example responses

    201 Response

    {
      "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.",
      "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
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A function category was created. functionCategoryCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    201 Last-Modified string date-time The date and time that the category was last modified.
    201 Location string uri The URI at which the created category can be retrieved.

    Delete a function category

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/businessRules/functionCategories/{categoryId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/businessRules/functionCategories/{categoryId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/businessRules/functionCategories/{categoryId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/businessRules/functionCategories/{categoryId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /functionCategories/{categoryId}

    Deletes the function category with the provided ID.

    Parameters
    Name In Type Required Description
    categoryId path string true The ID of the category to delete.
    Responses
    Status Meaning Description Schema
    204 No Content The content at the requested path was deleted. None

    Get a function category

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/functionCategories/{categoryId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.business.rule.function.category+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.business.rule.function.category+json'
    };
    
    fetch('https://example.com/businessRules/functionCategories/{categoryId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.business.rule.function.category+json'
    }
    
    r = requests.get('https://example.com/businessRules/functionCategories/{categoryId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.business.rule.function.category+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/functionCategories/{categoryId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /functionCategories/{categoryId}

    Returns the function category with the provided ID.

    Parameters
    Name In Type Required Description
    categoryId path string true The identifier of the category.

    Example responses

    200 Response

    {
      "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.",
      "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
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The function category was found. functionCategoryCollection
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the function category.

    Update a function category

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/businessRules/functionCategories/{categoryId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule.function.category+json' \
      -H 'Accept: application/vnd.sas.business.rule.function.category+json' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "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.",
      "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
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule.function.category+json',
      'Accept':'application/vnd.sas.business.rule.function.category+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/businessRules/functionCategories/{categoryId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule.function.category+json',
      'Accept': 'application/vnd.sas.business.rule.function.category+json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/businessRules/functionCategories/{categoryId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule.function.category+json"},
            "Accept": []string{"application/vnd.sas.business.rule.function.category+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/businessRules/functionCategories/{categoryId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /functionCategories/{categoryId}

    Updates the function category with the provided content.

    Body parameter

    {
      "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.",
      "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
    }
    
    Parameters
    Name In Type Required Description
    categoryId path string true The ID of the function category to update.
    If-Match header string true The entity tag from the last time the category was retrieved.
    body body functionCategoryCollection true none

    Example responses

    200 Response

    {
      "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.",
      "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
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    
    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The function category was updated. functionCategoryCollection
    400 Bad Request The request was invalid. errorCollection
    404 Not Found No resource exists at the requested path. errorCollection
    412 Precondition Failed The If-Match header did not match the resource's entity tag. errorCollection
    428 Precondition Required The request headers did not include the If-Match precondition. errorCollection
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the function category.

    Functions

    Contains the operations for creating, reading, and deleting function.

    Get a collection of functions in a category

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/functionCategories/{categoryId}/functions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/businessRules/functionCategories/{categoryId}/functions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/businessRules/functionCategories/{categoryId}/functions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/functionCategories/{categoryId}/functions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /functionCategories/{categoryId}/functions

    Returns a collection of the functions in a specific category based on the specified pagination, filtering, and sorting options.

    Parameters
    Name In Type Required Description
    categoryId path string true The ID of the category for which to retrieve the functions.
    start query integer(int64) false The index of the first function to return.
    limit query integer(int32) false The maximum number of functions to return.
    filter query string(filter-criteria) false The criteria for filtering the functions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the functions. See Sorting in REST APIs.
    Detailed descriptions

    filter: The criteria for filtering the functions. See Filtering in REST APIs.

    sortBy: The criteria for sorting the functions. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "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"
            }
          ],
          "nameQuoted": false
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK A collection of functions. functionCollection
    400 Bad Request The request was invalid. errorCollection
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string No description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a function

    Code samples

    # You can also use wget
    curl -X POST https://example.com/businessRules/functionCategories/{categoryId}/functions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule.function+json' \
      -H 'Accept: application/vnd.sas.business.rule.function+json'
    
    
    const inputBody = '{
      "code": "method custom_add(integer bar, double baz, in_out double foo);\n  foo = bar + baz;\nend;",
      "description": "Sums two numbers."
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule.function+json',
      'Accept':'application/vnd.sas.business.rule.function+json'
    };
    
    fetch('https://example.com/businessRules/functionCategories/{categoryId}/functions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule.function+json',
      'Accept': 'application/vnd.sas.business.rule.function+json'
    }
    
    r = requests.post('https://example.com/businessRules/functionCategories/{categoryId}/functions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule.function+json"},
            "Accept": []string{"application/vnd.sas.business.rule.function+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/businessRules/functionCategories/{categoryId}/functions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /functionCategories/{categoryId}/functions

    Creates a new function in a specific category.

    Body parameter

    {
      "code": "method custom_add(integer bar, double baz, in_out double foo);\n  foo = bar + baz;\nend;",
      "description": "Sums two numbers."
    }
    
    Parameters
    Name In Type Required Description
    categoryId path string true The ID of the category in which to create the new function.
    body body #/paths/~1functionCategories~1%7BcategoryId%7D~1functions/post/requestBody/content/application~1vnd.sas.business.rule.function%2Bjson/schema true The function to create.

    Example responses

    201 Response

    {
      "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"
        }
      ],
      "nameQuoted": false
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A new function category was created. functionCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    201 ETag string The entity tag for the function.
    201 Location string uri The URI at which the new function can be retrieved.

    Get a collection of functions

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/functions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/businessRules/functions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/businessRules/functions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/functions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /functions

    Returns a collection of functions based on the specified pagination, filtering, and sorting options.

    Parameters
    Name In Type Required Description
    start query integer(int64) false The index of the first function to return.
    limit query integer(int32) false The maximum number of functions to return.
    filter query string(filter-criteria) false The criteria for filtering the functions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the functions. See Sorting in REST APIs.
    Detailed descriptions

    filter: The criteria for filtering the functions. See Filtering in REST APIs.

    sortBy: The criteria for sorting the functions. See Sorting in REST APIs.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "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"
            }
          ],
          "nameQuoted": false
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK A collection of functions. functionCollection
    400 Bad Request The request was invalid. errorCollection
    Response Headers
    Status Header Type Format Description
    200 Last-Modified string No description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a function

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/businessRules/functions/{functionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/businessRules/functions/{functionId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/businessRules/functions/{functionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/businessRules/functions/{functionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /functions/{functionId}

    Deletes the function with the provided ID.

    Parameters
    Name In Type Required Description
    functionId path string true The ID of the function to delete.
    Responses
    Status Meaning Description Schema
    204 No Content The function at the requested path was deleted. None

    Get a user-defined function

    Code samples

    # You can also use wget
    curl -X GET https://example.com/businessRules/functions/{functionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.business.rule.function+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.business.rule.function+json'
    };
    
    fetch('https://example.com/businessRules/functions/{functionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.business.rule.function+json'
    }
    
    r = requests.get('https://example.com/businessRules/functions/{functionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.business.rule.function+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/businessRules/functions/{functionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /functions/{functionId}

    Retrieves the user-defined function with the given ID.

    Parameters
    Name In Type Required Description
    functionId path string true The ID of the function to retrieve.

    Example responses

    200 Response

    {
      "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"
        }
      ],
      "nameQuoted": false
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The function was retrieved. functionCollection
    400 Bad Request The request was invalid. errorCollection
    404 Not Found No resource exists at the requested path. errorCollection
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the function.

    Update a function

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/businessRules/functions/{functionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.business.rule.function+json' \
      -H 'Accept: application/vnd.sas.business.rule.function+json' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "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"
        }
      ],
      "nameQuoted": false
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.business.rule.function+json',
      'Accept':'application/vnd.sas.business.rule.function+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/businessRules/functions/{functionId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.business.rule.function+json',
      'Accept': 'application/vnd.sas.business.rule.function+json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/businessRules/functions/{functionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.business.rule.function+json"},
            "Accept": []string{"application/vnd.sas.business.rule.function+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/businessRules/functions/{functionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /functions/{functionId}

    Updates the function with the provided content.

    Body parameter

    {
      "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"
        }
      ],
      "nameQuoted": false
    }
    
    Parameters
    Name In Type Required Description
    functionId path string true The ID of the function to update.
    If-Match header string true The entity tag from the last time the function was retrieved.
    body body functionCollection true none

    Example responses

    200 Response

    {
      "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"
        }
      ],
      "nameQuoted": false
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    
    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The function was updated. functionCollection
    400 Bad Request The request was invalid. errorCollection
    404 Not Found No resource exists at the requested path. errorCollection
    412 Precondition Failed The If-Match header did not match the resource's entity tag. errorCollection
    428 Precondition Required The request headers did not include the If-Match precondition. errorCollection
    Response Headers
    Status Header Type Format Description
    200 ETag string The entity tag for the function.

    Schemas

    scoreCodeGenerationRequest

    {
      "scoreDefinitionId": "9f0c13ae-6a27-11e6-8b77-86f30ca893d3",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    

    Request for Generating Score Code

    Properties
    Name Type Required Restrictions Description
    scoreDefinitionId string true none The score definition ID that is used for generating the mapped code. This should be used only if the scoreDefinition is not used.
    hints object false none 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 string false none none
    version integer false none This media type's schema version number. This representation is version 1.

    analysisCodeGenerationRequest

    {
      "scoreExecutionId": "6f4bced9-5bbd-476c-8ef8-3378678b0702",
      "analysisType": "ruleFiredSummary",
      "hints": {
        "outputLibraryName": "PUBLIC"
      }
    }
    
    

    Request for Generating Analysis Code

    Properties
    Name Type Required Restrictions Description
    scoreExecutionId string true none The score execution ID.
    analysisType string(enumeration) true none The type of analysis that needs to be done.
    hints object false none Hints for generating the analysis code.
    » additionalProperties string false none none
    version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    analysisType ruleFiredDetails
    analysisType ruleFiredSummary

    ruleSetCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "Loan Score Approval",
          "signature": [
            {
              "name": "customerName",
              "dataType": "string",
              "direction": "input"
            },
            {
              "name": "creditScore",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "approved",
              "dataType": "integer",
              "direction": "output"
            }
          ]
        }
      ]
    }
    
    

    Rule Set Collection

    Properties
    Name Type Required Restrictions Description
    Rule Set Collection any false none One page of rule set representations, with optional links to first, prev, next, and last page of the collection.

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [link] false none The links that apply to the collection.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none An array that consists of one page of rule set resources.
    »» Rule Set object false none The definition of a set of rules and the associated signature for them. This represents application/vnd.sas.business.rule.set media type (version 5).
    »»» id string false none The system-assigned unique ID for this object
    »»» name string true none The name of the rule set
    »»» ruleSetType string(enumeration) false none The type of rule set. Assignment rule sets allow for users to specify variable assignment actions within business rules. Filtering rule sets contain business rules that are only conditions that need to be matched for the data to be retained within the resulting output. Assignment is the default if not specified.
    »»» description string false none The rule set description
    »»» createdBy string false none The user who created the rule set.
    »»» creationTimeStamp string(date-time) false none The date and time that the rule set was created.
    »»» modifiedBy string false none The userId of the authenticated user who last updated the rule set.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the rule set was last modified.
    »»» majorRevision integer false none 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 which is generated on PUT/POST.
    »»» locked boolean false none Flag which indicates if the content of the revision being viewed is locked or editable.
    »»» minorRevision integer false none 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 which is generated on PUT/POST.
    »»» signature [any] true none The set of terms local to this rule set with input and output behavior.
    »»»» Signature Term object false none 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.
    »»»»» id string false none The system-assigned unique ID for this object
    »»»»» name string true none Name of the term that can be referenced. Term names must be unique within a rule set.
    »»»»» description string false none Description of the term
    »»»»» defaultValue object false none The initial value of the term.
    »»»»» length integer false none Suggested length for use when generating code.
    »»»»» createdBy string false none The user who created the term.
    »»»»» creationTimeStamp string(date-time) false none The date and time that the term was created.
    »»»»» modifiedBy string false none The userId of the authenticated user who last updated the term.
    »»»»» modifiedTimeStamp string(date-time) false none The date and time that the term was last modified.
    »»»»» dataType string(enumeration) true none 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.
    »»»»» direction string(enumeration) true none 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.
    »»»»» dataGridExtension [any] false none 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'.
    »»»»»» Signature Term Extension object false none Signature Term Extension is used to store the column information of a Data Grid variable.
    »»»»»»» id string false none The system-assigned unique ID for this object
    »»»»»»» name string true none Name of the extension that can be referenced from rule logic. Extension must be unique within a data grid.
    »»»»»»» length integer false none Suggested length for use when generating code.
    »»»»»»» dataType string(enumeration) true none The type of data that the extension is intended to be used with.
    »»»»» globalVariableId string false none The id of the global variable that this term references.
    »»» folderType string false none Indicates the kind of folder where the rule set is housed.
    »»» sourceRevisionUri string false none The URI of the ruleset revision this ruleset is being created from.
    »»» copyTimeStamp string(date-time) false none The time stamp when the ruleset revision was copied.
    »»» links [link] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    ruleSetType assignment
    ruleSetType filtering
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    dataType dataGrid
    dataType boolean
    dataType any
    direction input
    direction output
    direction inOut
    direction none
    dataType string
    dataType decimal
    dataType integer

    ruleCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "Age Requirements",
          "conditional": "if",
          "ruleFiredTrackingEnabled": true
        }
      ]
    }
    
    

    Rule Collection

    Properties
    Name Type Required Restrictions Description
    Rule Collection any false none One page of rule representations with optional links to first, prev, next, and last page of the collection.

    allOf

    Name Type Required Restrictions Description
    anonymous ruleSetCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none An array that consists of one page of rule resources.
    »» Rule object false none The definition of a set of conditions and actions for use within a rule set. This represents application/vnd.sas.business.rule media type (version 3).
    »»» id string false none The system-assigned unique ID for this object
    »»» name string true none The name of the rule. Rule names must be unique within a rule set.
    »»» description string false none The rule description
    »»» createdBy string false none The user who created the rule.
    »»» creationTimeStamp string(date-time) false none The date and time that the rule was created.
    »»» modifiedBy string false none The userId of the authenticated user who last updated the rule.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the rule was last modified.
    »»» conditional string(enumeration) true none 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.
    »»» ruleFiredTrackingEnabled boolean true none 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 string(enumeration) false none 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.
    »»» conditions [ruleCondition] false none The list of conditions which all need to be met to execute the rules actions.
    »»» actions [ruleAction] false none 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.
    »»» links [link] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 3.
    Enumerated Values
    Property Value
    conditional if
    conditional elseif
    conditional or
    status valid
    status error

    errorCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "message": "string",
          "id": "string",
          "errorCode": 0,
          "httpStatusCode": 0,
          "details": [
            "string"
          ],
          "remediation": "string",
          "errors": [
            null
          ],
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    
    

    Error Collection

    Properties
    Name Type Required Restrictions Description
    Error Collection any false none A collection of errors and warnings from the rule validation. No paging is required for this end point.

    allOf

    Name Type Required Restrictions Description
    anonymous ruleSetCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [object] true none 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.
    »» Error object false none The representation of an error.
    »»» message string false none The message for the error.
    »»» id string false none The string ID for the error.
    »»» errorCode integer false none The numeric ID for the error.
    »»» httpStatusCode integer true none The HTTP status code for the error.
    »»» details [string] false none Messages that provide additional details about the cause of the error.
    »»» remediation string false none A message that describes how to resolve the error.
    »»» errors [errorCollection] false none Any additional errors that occurred.
    »»» links [link] false none The links that apply to the error.
    »»» version integer true none The version number of the error representation. This representation is version 2.

    ruleQueryCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "Age Requirements",
          "conditional": "if",
          "ruleFiredTrackingEnabled": true
        }
      ]
    }
    
    

    Error Collection

    Properties
    Name Type Required Restrictions Description
    Error Collection any false none A collection of rules that uses the query response format.

    allOf

    Name Type Required Restrictions Description
    anonymous ruleSetCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none none
    »» Rule Query Result object false none 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).
    »»» id string false none The system-assigned unique ID for this object
    »»» name string true none The name of the rule
    »»» description string false none The rule description
    »»» createdBy string false none The user who created the rule.
    »»» creationTimeStamp string(date-time) false none The date and time that the rule was created.
    »»» modifiedBy string false none The userId of the authenticated user who last updated the rule.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the rule was last modified.
    »»» conditional string(enumeration) true none 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'.
    »»» ruleFiredTrackingEnabled boolean true none 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 string(enumeration) false none 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.
    »»» conditionExpressions [string] false none The list of conditions serialized into report formatted expression strings.
    »»» actionExpressions [string] false none The list of actions serialized into report formatted expression strings.
    »»» ruleSet object false none 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).
    »»»» id string false none The system-assigned unique ID for this object.
    »»»» name string true none The name of the rule set.
    »»»» ruleSetType string(enumeration) false none 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.
    »»»» description string false none The rule set description
    »»»» createdBy string false none The user who created the rule set.
    »»»» creationTimeStamp string(date-time) false none The date and time that the rule set was created.
    »»»» modifiedBy string false none The user ID of the authenticated user who last updated the rule set.
    »»»» modifiedTimeStamp string(date-time) false none The date and time that the rule set was last modified.
    »»»» majorRevision integer false none 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 integer false none 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 boolean false none Flag that indicates that the rule set is a user's working copy of another rule set.
    »»»» locked boolean false none Flag that indicates if the content of the revision being viewed is locked or editable.
    »»»» signature [term] true none The set of terms local to this rule set with input and output behavior.
    »»»» folderType string false none Indicates the type of folder where the rule set is housed.
    »»»» sourceRevisionUri string false none The URI of the rule set revision this rule set is being created from.
    »»»» copyTimeStamp string(date-time) false none The time stamp when the ruleset revision was copied.
    »»»» testCustomContextUri string false none 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 [link] false none Zero or more links to related resources or operations.
    »»»» version integer false none This media type's schema version number. This representation is version 10.
    »»» links [link] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    conditional if
    conditional else
    status valid
    status error
    ruleSetType assignment
    ruleSetType filtering

    ruleActionConversion

    {
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "source": {
        "id": "string",
        "type": "assignment",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "targetType": "assignment",
      "convertedAction": {
        "id": "string",
        "type": "assignment",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "version": 0
    }
    
    

    Rule Action Conversion

    Properties
    Name Type Required Restrictions Description
    links [object] false none Zero or more links to related resources or operations.
    » Link object false none A link to a related operation or resource.
    »» method string false none The HTTP method for the link.
    »» rel string true none The relationship of the link to the resource.
    »» uri string false none The relative URI for the link.
    »» href string false none The URL for the link.
    »» title string false none The title for the link.
    »» type string false none The media type or link type for the link.
    »» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    source object true none Action that is performed if a rule evaluated to true.
    » id string false none The system-assigned unique ID for this object
    » type string(enumeration) true none 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...
    • assignment - assign a term the value of the provided expression
    • return - stop executing the rule and return immediately
    • complex - execute an arbitrary piece of DS2 code
    • 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
    » expression string false none 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 object false none A reference to a lookup within a condition or action of a rule.
    »» id string true none The UUID of the lookup that is being referenced by the rule condition or action.
    »» name string false none Name of the lookup. Populated on the users behalf for convenience.
    » term object false none 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.
    »» id string false none The system-assigned unique ID for this object
    »» name string true none Name of the term that can be referenced. Term names must be unique within a rule set.
    »» description string false none The description of the term.
    »» defaultValue object false none The initial value of the term.
    »» length integer false none The suggested length for use when generating code.
    »» createdBy string false none The user who created the term.
    »» creationTimeStamp string(date-time) false none The date and time that the term was created.
    »» modifiedBy string false none The user ID of the authenticated user who last updated the term.
    »» modifiedTimeStamp string(date-time) false none The date and time that the term was last modified.
    »» dataType string(enumeration) true none 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.
    »» direction string(enumeration) true none 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.
    »» dataGridExtension [any] false none 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'.
    »»» Signature Term Extension object false none The signature term extension is used to store the column information of a data grid variable.
    »»»» id string false none The system-assigned unique ID for this object.
    »»»» name string true none The name of the extension that can be referenced from rule logic. The extension must be unique within a data grid.
    »»»» length integer false none The suggested length for use when generating code.
    »»»» autoPopulate boolean false none 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 string(enumeration) true none The type of data that the extension is intended to be used with.
    »» globalVariableId string false none The id of the global variable that this term references.
    »» generateDataGridColumns boolean false none 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 boolean false none the flag of legacy variable.
    » status string(enumeration) false none 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.
    » statusMessage string false none Validation message for any errors within the action.
    targetType string(enumeration) true none The type to convert the action to.
    convertedAction ruleAction false none Action that is performed if a rule evaluated to true.
    version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    type assignment
    type return
    type complex
    type lookupValue
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    dataType dataGrid
    dataType boolean
    dataType any
    direction input
    direction output
    direction inOut
    direction none
    dataType string
    dataType decimal
    dataType integer
    status valid
    status error
    targetType assignment
    targetType return
    targetType complex
    targetType lookupValue

    ruleConditionConversion

    {
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "source": {
        "id": "string",
        "type": "decisionTable",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "targetType": "decisionTable",
      "convertedCondition": {
        "id": "string",
        "type": "decisionTable",
        "expression": "string",
        "lookup": {
          "id": "string",
          "name": "string"
        },
        "term": {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": {},
          "length": 0,
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "direction": "input",
          "dataGridExtension": [
            {
              "id": "string",
              "name": "string",
              "length": 0,
              "autoPopulate": true,
              "dataType": "string"
            }
          ],
          "globalVariableId": "string",
          "generateDataGridColumns": true,
          "legacy": true
        },
        "status": "valid",
        "statusMessage": "string"
      },
      "version": 0
    }
    
    

    Rule Condition Conversion

    Properties
    Name Type Required Restrictions Description
    links [link] false none Zero or more links to related resources or operations.
    source object true none Conditional that evaluates to true or false.
    » id string false none The system-assigned unique ID for this object
    » type string(enumeration) true none Type of condition that is being used, the fields that are applicable within the object will depend on the type provided.
    • 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)'.
    • lookup - Determine if the term provided exists within the provided Reference Data domain lookup.
    • 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'".
    » expression string false none Conditional expression used for this condition. Valid only for complex or decisionTable.
    » lookup lookupReference false none A reference to a lookup within a condition or action of a rule.
    » term term false none 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.
    » status string(enumeration) false none 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.
    » statusMessage string false none Validation message for any errors within the condition.
    targetType string(enumeration) true none The type to convert the condition to.
    convertedCondition ruleCondition false none Conditional that evaluates to true or false.
    version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    type decisionTable
    type lookup
    type complex
    status valid
    status error
    targetType decisionTable
    targetType lookup
    targetType complex

    functionCategoryCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "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.",
          "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
        }
      ]
    }
    
    

    Function Category Collection

    Properties
    Name Type Required Restrictions Description
    Function Category Collection any false none One page of function category representations with optional links to the first, previous, next, and last pages of the collection.

    allOf

    Name Type Required Restrictions Description
    anonymous ruleSetCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none An array that consists of one page of function category representations.
    »» Function Category object false none A named group to hold a related set of functions.
    »»» id string false none The system-assigned unique ID for this object.
    »»» name string true none A unique name for the category.
    »»» description string false none A description of the category.
    »»» createdBy string false none The user who created the category.
    »»» creationTimeStamp string(date-time) false none The data and time at which the category was created.
    »»» modifiedBy string false none The user who made the last modification to the category.
    »»» modifiedTimeStamp string(date-time) false none The date and time at which the category was last modified.
    »»» links [link] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 1.

    functionCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "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"
            }
          ],
          "nameQuoted": false
        }
      ]
    }
    
    

    Function Collection

    Properties
    Name Type Required Restrictions Description
    Function Collection any false none One page of function representations with optional links to the first, previous, next, and last pages of the collection.

    allOf

    Name Type Required Restrictions Description
    anonymous ruleSetCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none An array that consists of one page of function representations.
    »» Function object false none A reusable DS2 method with additional metadata.
    »»» id string false none The system-assigned unique ID for this object.
    »»» name string false none 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 boolean false none A boolean indicating if the function's name is quoted in its code.
    »»» categoryId string true none 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 string false none A description of the function.
    »»» code string true none The DS2 function implementation, starting with the method my_func(); statement.
    »»» returnType string false none 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 [any] false none An ordered array of the input parameters to the function determined by parsing the function's code.
    »»»» Function Signature Term object false none An input parameter to a user-defined function.
    »»»»» inOut boolean false none A boolean indicating if the parameter was preceded with the in_out keyword.
    »»»»» name string true none The name of the input parameter.
    »»»»» nameQuoted boolean false none A boolean indicating if the parameter name is quoted in the function's code.
    »»»»» type string false none The DS2 type of the parameter.
    »»» createdBy string false none The user who created the function.
    »»» creationTimeStamp string(date-time) false none The data and time at which the function was created.
    »»» modifiedBy string false none The user who made the last modification to the function.
    »»» modifiedTimeStamp string(date-time) false none The date and time at which the function was last modified.
    »»» links [link] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 1.

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    Business Rules Media Types
    application/vnd.sas.business.rule.set

    The business rule set provides information about the rule set.

    The schema is at ruleSet.

    application/vnd.sas.business.rule.set+json

    Here is an example of the JSON representation of this media type.

    
     {
      "creationTimeStamp": "2017-06-14T17:10:28.657Z",
      "modifiedTimeStamp": "2017-06-14T17:12:48.860Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "version": 1,
      "id": "db521e0b-d031-422d-9986-6c8cbb8d05c3",
      "name": "LoanApprovalRules",
      "description": "Rules for approving a loan",
      "majorNumber": 1,
      "minorNumber": 1,
      "locked": false,
      "folderType": "myFolder",
      "links": [
      {
        "method": "GET",
        "rel": "self",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
        "type": "application/vnd.sas.business.rule.set"
      },
      {
        "method": "PUT",
        "rel": "update",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
        "type": "application/vnd.sas.business.rule.set",
        "responseType": "application/vnd.sas.business.rule.set"
      },
      {
        "method": "DELETE",
        "rel": "delete",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3"
      },
      {
        "method": "GET",
        "rel": "rules",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules",
        "type": "application/vnd.sas.collection",
        "itemType": "application/vnd.sas.business.rule"
      },
      {
        "method": "GET",
        "rel": "rulesOrder",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/order",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/order",
        "type": "application/vnd.sas.selection"
      },
      {
        "method": "GET",
        "rel": "revisions",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/revisions",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/revisions",
        "type": "application/vnd.sas.collection",
        "itemType": "application/vnd.sas.business.rule.set"
      },
      {
        "method": "POST",
        "rel": "createMinorRevision",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/revisions?revisionType=minor",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/revisions?revisionType=minor",
        "type": "application/vnd.sas.brm.rule.set",
        "responseType": "application/vnd.sas.business.rule.set"
      },
      {
        "method": "POST",
        "rel": "createMajorRevision",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/revisions?revisionType=major",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/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/db521e0b-d031-422d-9986-6c8cbb8d05c3/code",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/code",
        "type": "text/vnd.sas.source.ds2"
      },
      {
        "method": "POST",
        "rel": "mappedCode",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/mappedCode",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/mappedCode",
        "type": "application/vnd.sas.dcm.score.mapped.code",
        "responseType": "application/vnd.sas.dcm.score.mapped.code"
      },
      {
        "method": "POST",
        "rel": "analysisCode",
        "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/analysisCode",
        "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/analysisCode",
        "type": "application/vnd.sas.dcm.score.analysis.code",
        "responseType": "application/vnd.sas.dcm.score.analysis.code"
      }
      ],
      "signature": [
      {
        "creationTimeStamp": "2017-06-14T17:12:20.117Z",
        "modifiedTimeStamp": "2017-06-14T17:12:48.914Z",
        "createdBy": "bob",
        "modifiedBy": "bob",
        "id": "94591e7b-7b7d-4efa-9c60-b2c3a00d7739",
        "name": "age",
        "dataType": "decimal",
        "description": "Age of customer",
        "direction": "input"
      },
      {
        "creationTimeStamp": "2017-06-14T17:12:20.148Z",
        "modifiedTimeStamp": "2017-06-14T17:12:48.933Z",
        "createdBy": "bob",
        "modifiedBy": "bob",
        "id": "6bd1bd30-f260-42bc-532c-fb834ef2dffa",
        "name": "approved",
        "dataType": "decimal",
        "direction": "output"
      },
      {
        "creationTimeStamp": "2017-06-14T17:12:20.187Z",
        "modifiedTimeStamp": "2017-06-14T17:12:48.960Z",
        "createdBy": "bob",
        "modifiedBy": "bob",
        "id": "3d3bec8a-e496-4597-cbc5-998baec2ae6d",
        "name": "creditScore",
        "dataType": "decimal",
        "direction": "inOut"
      }
      ]
    }
    
    application/vnd.sas.business.rule

    Provides information about the business rule.

    The schema is at businessRule.

    application/vnd.sas.business.rule+json

    Here is an example of the JSON representation of this media type.

    
     {
       "creationTimeStamp":"2017-06-14T17:12:49.220Z",
       "modifiedTimeStamp":"2017-06-14T17:12:49.263Z",
       "createdBy":"bob",
       "modifiedBy":"bob",
       "version":1,
       "id":"b4075f7d-e4f2-4379-bd8a-035914f91700",
       "name":"Default_rule_1",
       "description":"Rule to check age requirements.",
       "ruleFiredTrackingEnabled":true,
       "conditional":"if",
       "conditions":[
          {  
             "term":{
                "creationTimeStamp":"2017-06-14T17:12:20.117Z",
                "modifiedTimeStamp":"2017-06-14T17:12:48.914Z",
                "createdBy":"bob",
                "modifiedBy":"bob",
                "id":"94591e7b-7b7d-4efa-9c60-b2c3a00d7739",
                "name":"age",
                "dataType":"decimal",
                "direction":"input"
             },
             "expression":"< 18",
             "status":"valid",
             "id":"0b9a512e-5134-4bd3-93ab-63fedde9d98a",
             "type":"decisionTable"
          }
       ],
       "actions":[  
          {  
             "term":{
                "creationTimeStamp":"2017-06-14T17:12:20.148Z",
                "modifiedTimeStamp":"2017-06-14T17:12:48.933Z",
                "createdBy":"bob",
                "modifiedBy":"bob",
                "id":"6bd1bd30-f260-42bc-532c-fb834ef2dffa",
                "name":"approved",
                "dataType":"decimal",
                "direction":"output"
             },
             "expression":"0",
             "status":"valid",
             "id":"1c762292-6203-405a-8e1d-45aa899314b2",
             "type":"assignment"
          }
       ],
       "links":[  
          {  
             "method":"GET",
             "rel":"self",
             "href":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules/b4075f7d-e4f2-4379-bd8a-035914f91700",
             "uri":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules/b4075f7d-e4f2-4379-bd8a-035914f91700",
             "type":"application/vnd.sas.business.rule"
          },
          {  
             "method":"PUT",
             "rel":"update",
             "href":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules/b4075f7d-e4f2-4379-bd8a-035914f91700",
             "uri":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules/b4075f7d-e4f2-4379-bd8a-035914f91700",
             "type":"application/vnd.sas.brm.rule",
             "responseType":"application/vnd.sas.business.rule"
          },
          {  
             "method":"DELETE",
             "rel":"delete",
             "href":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules/b4075f7d-e4f2-4379-bd8a-035914f91700",
             "uri":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules/b4075f7d-e4f2-4379-bd8a-035914f91700"
          },
          {  
             "method":"GET",
             "rel":"parent",
             "href":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
             "uri":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
             "type":"application/vnd.sas.business.rule.set"
          },
          {  
             "method":"GET",
             "rel":"up",
             "href":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules",
             "uri":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/rules",
             "type":"application/vnd.sas.collection",
             "itemType":"application/vnd.sas.business.rule"
          }
       ],
       "status":"valid"
    }
    
    application/vnd.sas.business.rule.action.conversion

    Contains information about a rule action to convert.

    application/vnd.sas.business.rule.action.conversion+json

    Here is an example of the JSON representation of this media type.

    
     {
      "links": [
        {
          "method": "POST",
          "rel": "self",
          "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/actionConversion",
          "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/actionConversion",
          "type": "application/vnd.sas.business.rule.action.conversion",
          "responseType": "application/vnd.sas.business.rule.action.conversion"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
          "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
          "type": "application/vnd.sas.business.set"
        }
      ],
      "source": {
        "term": {
          "creationTimeStamp": "2017-06-14T17:12:20.148Z",
          "modifiedTimeStamp": "2017-06-14T17:12:48.933Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "6bd1bd30-f260-42bc-532c-fb834ef2dffa",
          "name": "approved",
          "dataType": "decimal",
          "direction": "output"
        },
        "expression": "0",
        "status": "valid",
        "id": "1c762292-6203-405a-8e1d-45aa899314b2",
        "type": "assignment"
      },
      "targetType": "complex",
      "convertedAction": {
        "term": {
          "creationTimeStamp": "2017-06-14T17:12:20.148Z",
          "modifiedTimeStamp": "2017-06-14T17:12:48.933Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "6bd1bd30-f260-42bc-532c-fb834ef2dffa",
          "name": "approved",
          "dataType": "decimal",
          "direction": "output"
        },
        "expression": "approved = 0",
        "status": "valid",
        "id": "1c762292-6203-405a-8e1d-45aa899314b2",
        "type": "complex"
      },
      "version": 1
    }
    
    application/vnd.sas.business.rule.condition.conversion

    Contains information about a rule condition to convert.

    application/vnd.sas.business.rule.condition.conversion+json

    Here is an example of the JSON representation of this media type.

    
     {
      "links": [
        {
          "method": "POST",
          "rel": "self",
          "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/actionConversion",
          "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/actionConversion",
          "type": "application/vnd.sas.business.rule.action.conversion",
          "responseType": "application/vnd.sas.business.rule.action.conversion"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
          "uri": "/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
          "type": "application/vnd.sas.business.set"
        }
      ],
      "source": {  
        "term": {
          "creationTimeStamp": "2017-06-14T17:12:20.117Z",
          "modifiedTimeStamp": "2017-06-14T17:12:48.914Z",
          "createdBy": "bob", 
          "modifiedBy": "bob",
          "id": "94591e7b-7b7d-4efa-9c60-b2c3a00d7739", 
          "name": "age", 
          "dataType": "decimal",
          "direction": "input"
        },
        "expression": "< 18",
        "status": "valid",
        "id": "0b9a512e-5134-4bd3-93ab-63fedde9d98a",
        "type": "decisionTable"
      },
      "targetType": "complex",
      "convertedCondition": {
        "term": {
          "creationTimeStamp": "2017-06-14T17:12:20.117Z",
          "modifiedTimeStamp": "2017-06-14T17:12:48.914Z",
          "createdBy": "bob", 
          "modifiedBy": "bob",
          "id": "94591e7b-7b7d-4efa-9c60-b2c3a00d7739", 
          "name": "age", 
          "dataType": "decimal",
          "direction": "input"
        },
        "expression": "age < 18",
        "status": "valid",
        "id": "0b9a512e-5134-4bd3-93ab-63fedde9d98a",
        "type": "complex"
      },
      "version": 1
    }
    
    application/vnd.sas.business.rule.query.result

    Provides information about the business rule query result.

    The schema is at businessRuleQuery.

    application/vnd.sas.business.rule.query.result+json

    Here is an example of the JSON representation of this media type.

    
     {
       "creationTimeStamp":"2017-06-14T17:12:49.220Z",
       "modifiedTimeStamp":"2017-06-14T17:12:49.263Z",
       "createdBy":"bob",
       "modifiedBy":"bob",
       "id":"b4075f7d-e4f2-4379-bd8a-035914f91700",
       "name":"Default_rule_1",
       "conditional":"if",
       "ruleFiredTrackingEnabled":true,
       "status":"valid",
       "description":"",
       "conditionExpressions":[  
          "age < 18"
       ],
       "actionExpressions":[  
          "approved = 0"
       ],
       "ruleSet":{  
          "creationTimeStamp":"2017-06-14T17:10:28.657Z",
          "modifiedTimeStamp":"2017-06-14T17:13:20.959Z",
          "createdBy":"bob",
          "modifiedBy":"bob",
          "version":1,
          "id":"db521e0b-d031-422d-9986-6c8cbb8d05c3",
          "name":"LoanApprovalRules",
          "description":"Rules for approving a loan",
          "majorNumber":1,
          "minorNumber":1,
          "locked":false,
          "links":[  
             {  
                "method":"GET",
                "rel":"self",
                "href":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
                "uri":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3",
                "type":"application/vnd.sas.brm.rule.set"
             }
          ]
       },
       "links":[  
          {  
             "method":"GET",
             "rel":"self",
             "href":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/revisions/43ed7a9c-602e-44da-9af0-257daaa373c3/rules/b4075f7d-e4f2-4379-bd8a-035914f91700",
             "uri":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/revisions/43ed7a9c-602e-44da-9af0-257daaa373c3/rules/b4075f7d-e4f2-4379-bd8a-035914f91700",
             "type":"application/vnd.sas.business.rule"
          },
          {  
             "method":"GET",
             "rel":"parent",
             "href":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/revisions/43ed7a9c-602e-44da-9af0-257daaa373c3",
             "uri":"/businessRules/ruleSets/db521e0b-d031-422d-9986-6c8cbb8d05c3/revisions/43ed7a9c-602e-44da-9af0-257daaa373c3",
             "type":"application/vnd.sas.business.rule.set"
          }
       ],
       "version":1
    }
    
    text/csv

    Format of the business rule CSV file. The following columns are expected when using text/csv within this API.

    Column Name Description
    ruleset_id The ID member within the ruleSet.
    ruleset_nm The name member within the ruleSet.
    folder_path The path within the Folders service to the containing rule set.
    ruleset_desc The description member within the ruleSet.
    rule_id The ID member within the businessRule.
    rule_nm The name member within the businessRule.
    rule_desc The description member within a businessRule.
    rule_seq_no The order in which the rule within a rule set is executed. You can specify the order with the Rule Set Ordering resource (1-based).
    conditional The conditional member within a businessRule.
    record_rule_fired_flag The ruleFiredTrackingEnabled member within a businessRule.
    dataType The signatureTerm dataType member part of the ruleAction or ruleCondition.
    lhs_term The signatureTerm name member part of the ruleAction or ruleCondition.
    expression The expression member of the ruleAction or the ruleCondition.
    expression_type ACTION or CONDITION, which determines the type of expression.
    expression_order The ordering within the actions or conditions array within the businessRule, which is based on the expression_type (1-based).

    A header row declares the columns that are required for successful usage.

    text/csv

    Here is an example of the text of this media type.

    
    
    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
    c9d3ad9f-42be-4838-ad63-50d9f9bfe43f,CsvExampleRuleSet,/Users/bob/My Folder,,56f367e6-ba72-4661-b087-556c9b284079,Default_rule_1,,1,IF,Y,string,test,"='abc'",CONDITION,1
    c9d3ad9f-42be-4838-ad63-50d9f9bfe43f,ChrisExportTest,/Users/bob/My Folder,,56f367e6-ba72-4661-b087-556c9b284079,Default_rule_1,,1,IF,Y,decimal,test2,1,ACTION,1
    
    multipart/mixed

    The business rule multipart response format for importing the rule content. There are three parts to this response message:

    The delimiter for the multipart message is provided within the responses Content-Type header as shown below.

    
    
    Content-Type: multipart/mixed; boundary=_001_002_003_004_005_006_007_008_009_010_011_012_
    

    Below is an example of the text of this media type.

    The string --001_002_003_004_005_006_007_008_009_010_011_012 is the delimiter for the multipart message.

    
    
    --_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
    ,cars_code_gen1,/Public/importedCSV2,,,problemrule,,0,if,Y,Decimal,engine_size,9.9,ACTION,1,failed,2 rules exist named problemrule but with different sequence numbers.
    ,cars_code_gen1,/Public/importedCSV2,,,problemrule,,0,if,Y,Integer,make_flag,1,ACTION,0,failed,2 rules exist named problemrule but with different sequence numbers.
    ,cars_code_gen1,/Public/importedCSV2,,,problemrule,,0,if,Y,Decimal,EngineSize,>3.1,CONDITION,1,failed,2 rules exist named problemrule but with different sequence numbers.
    ,cars_code_gen1,/Public/importedCSV2,,,problemrule,,0,if,Y,String,Make,'Toyota',CONDITION,0,failed,2 rules exist named problemrule but with different sequence numbers.
    ,cars_code_gen1,/Public/importedCSV2,,,problemrule,,1,if,Y,Integer,make_flag,1,ACTION,0,failed,2 rules exist named problemrule but with different sequence numbers.
    --_001_002_003_004_005_006_007_008_009_010_011_012_
    Content-Type:text/csv; charset="utf-8"
    Content-ID:Accepted-csv
    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,status,statusmessage
    ,cars_code_gen1,/Public/importedCSV2,,,cars_code_gen2,,1,if,Y,String,Make,'Toyota',CONDITION,0,valid,
    ,cars_code_gen1,/Public/importedCSV2,,,cars_code_gen2,,1,if,Y,Decimal,EngineSize,>3.1,CONDITION,1,valid,
    ,cars_code_gen1,/Public/importedCSV2,,,cars_code_gen2,,1,if,Y,Decimal,engine_size,9.9,ACTION,0,valid,
    --_001_002_003_004_005_006_007_008_009_010_011_012_--
    
    Externally Defined Media Types
    application/vnd.sas.collection

    A paginated, filterable, and sortable collection of resource representations. In this API, this is a collection of the application/vnd.sas.business.rule.set, the application/vnd.sas.business.rule, or the application/vnd.sas.business.rule.query.result representations.

    See application/vnd.sas.collection.

    application/vnd.sas.error

    See application/vnd.sas.error.

    application/vnd.sas.selection

    Media type used to allow for the reordering of rules within the rule sets.

    See application/vnd.sas.selection.

    application/vnd.sas.score.code.generation.request

    Request format for generating the code that is mapped to specific data based on the specified scoring definition within the request.

    Supported hints within the scoreCodeGenerationRequest for generating code with this service are:

    See application/vnd.sas.score.code.generation.request.

    vnd.sas.score.code.generation.request.unbound

    Request format for generating the code that is mapped to a generic input and output data set based and is not bound to a scoring definition.

    The schema is at unboundScoreCodeGenerationRequest.

    Supported hints are the same as scoreCodeGenerationRequest for generating code with 3 exceptions debugColumnHint, tableBaseName, and outputLibraryName, are not supported with this type. Also, the following hints are available for this request type.

    See application/vnd.sas.score.code.generation.request.unbound.

    application/vnd.sas.score.mapped.code

    This type is used as a response to request for execution code made with application/vnd.sas.score.code.generation.request to generate code that is mapped to specific data based on the request.

    The returned codeType that is returned within the mappedCode is always text/vnd.sas.source.ds2 for this version of the service.

    See application/vnd.sas.score.mapped.code.

    application/vnd.sas.score.analysis.code.generation.request

    Request format for generating mapped analysis code to analyze specific data based on the specified score execution (scoreExecutionId) within the request.

    The analysisType supported within the analysisCodeGenerationRequest are:

    Hints that are supported when submitting a request are:

    See application/vnd.sas.score.analysis.code.generation.request.

    application/vnd.sas.score.analysis.code

    This type is used as a response to the request for analysis code made with the application/vnd.sas.score.analysis.code.generation.request to generate analysis code that is mapped to specific data based on the request.

    The returned codeType that is returned within the analysisCode is always text/vnd.sas.source.ds2 for this version.

    See application/vnd.sas.score.analysis.code.

    Resource Relationships

    Resourcediagramruleset

    Root

    Path: /

    The root of the API. This resource contains links to the top-level resources in the API.

    The response includes the following links.

    Relation Method Description
    getRuleSets GET Returns the first page of the collection of rule sets.
    Response type: application/vnd.sas.collection
    createRuleSet POST Creates a new rule set domain.
    Request type: application/vnd.sas.business.rule.set
    Response type: application/vnd.sas.business.rule.set
    exportRules GET Exports all the rules in the latest revision of each rule set in CSV format.
    Response type: [text/csv]
    importRules POST Imports rules into the latest revision of one or more rule sets. Creates rules and rule sets that do not exist.
    Request type: [text/csv]
    Response type: [multipart/mixed]
    getRules GET Returns the list of rules contained within rule sets based on filtering parameters.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.business.rule.query.result
    Rule Sets

    Path: /ruleSets

    Provides a collection of rule sets.

    The default page size is 10.

    The ruleSets collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.business.rule.set resources. These types apply to the response for the self, collection, prev, next, first, and last links shown below.

    The response includes the following links.

    Relation Method Description
    createRuleSet POST Creates a new rule set.
    Request type: application/vnd.sas.business.rule.set
    Response type: application/vnd.sas.business.rule.set
    self GET Returns the current page of the collection.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Returns the parent resource, which is the root of this API.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the ruleSets collection is by ascending creationTimeStamp.

    Filtering and sorting might use the following members of a ruleSet:

    Filter by name - ?filter=eq(name, 'LoanApproval')

    Filter by multiple names - ?filter=in(name, 'LoanApproval', 'CreditApproval')

    Filter by time value - ?filter=gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combining filters - ?filter=and(gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    Rule Set

    Path: /ruleSet/{ruleSetId}

    This resource represents a rule set.

    The response includes the following links.

    Relation Method Description
    self GET Returns the full representation of the rule set.
    update PUT Updates the rule set content.
    Request type: application/vnd.sas.business.rule.set
    Response type: application/vnd.sas.business.rule.set
    code GET Returns the DS2 Package code based on the rule set logic.
    Response type: [text/vnd.sas.source.ds2]
    mappedCode POST Generates code that is mapped to a score definition.
    Request type: application/vnd.sas.score.code.generation.request
    Response type: application/vnd.sas.score.mapped.code
    analysisCode POST Generates analysis code that is mapped to a score definition.
    Request type: application/vnd.sas.score.analysis.code.generation.request
    Response type: application/vnd.sas.score.analysis.code
    delete DELETE Deletes this rule set.
    rules GET Returns the first page of the rules contained in this rule set.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.business.rule
    up GET Returns the parent resource.
    rulesOrder GET Returns the order in which the rules execute.
    Response type: application/vnd.sas.selection
    revisions GET Returns the list of revisions for this rule set.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.business.rule.set
    createMajorRevision POST Creates a new major revision of the rule set.
    Request type: application/vnd.sas.business.rule.set
    Response type: application/vnd.sas.business.rule.set
    createMinorRevision POST Creates a new minor revision of the rule set.
    Request type: application/vnd.sas.business.rule.set
    Response type: application/vnd.sas.business.rule.set
    Rule Set Rules

    Path: /ruleSets/{ruleSetId}/rules

    This resource contains collection of Rules.

    The default page size is 10.

    The rules collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.business.rule resources. These types apply to the response for the self, collection, prev, next, first, and last links below.

    The response includes the following links.

    Relation Method Description
    addRule POST Adds a rule to the rule set.
    Request type: application/vnd.sas.business.rule
    Response type: application/vnd.sas.business.rule
    self GET Returns the current page of the collection.
    collection GET Return the first page of the collection, without sorting or filtering criteria.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Return the parent resource, which is the root of this API.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the rules collection is by the ordering returned by the `/ruleSets/{ruleSetsId}/order.

    Filtering and sorting can use the following members of a businessRule:

    Filter by name - ?filter=eq(name, 'LoanApproval')

    Filter by multiple names - ?filter=in(name, 'LoanApproval', 'CreditApproval')

    Filter by time value - ?filter=gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combining filters - ?filter=and(gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    Rule Validations

    Path: /ruleSet/{ruleSetId}/ruleValidations

    This resource contains collection of errors generated based on the validation results. If the rule submitted is valid, the collection is empty.

    The validation performed here is for the rule action and condition syntax along with the lookup reference validation. See model documentation on syntax descriptions for ruleAction and ruleCondition .

    The ruleValidations collection representation is collection. The collection items are application/vnd.sas.error resources. No paging is supported for this end point as the validations are non-persistent.

    Links provided on this resource.

    Relation Method Description
    self GET Returns the full representation of the rule set.
    up GET Returns the parent resource.
    Rule Action Conversion

    Path: /ruleSet/ruleSetId}/actionConversion

    This resource allows for converting a ruleAction to a different target type. The resulting action is not persisted.

    Links provided on this resource.

    Relation Method Description
    self POST Returns the converted version of the provided rule action.
    up GET Returns the parent resource.
    Rule Condition Conversion

    Path: /ruleSet/{ruleSetId}/conditionConversion

    This resource allows for converting a ruleCondition to a different target type. The resulting condition is not persisted.

    Links provided on this resource.

    Relation Method Description
    self POST Returns the converted version of the provided rule condition
    up GET Returns the parent resource.

    Path: /ruleSet/{ruleSetId}/order

    Contains the full ordering of the rules within the rule set by ID.

    The order representation is application/vnd.sas.selection.

    Links provided on this resource.

    Relation Method Description
    self GET Returns the full representation of the rule set.
    up GET Returns the parent resource.
    Package Code

    Path: /ruleSet/{ruleSetId}/code

    Returns a representation of the rule set as a DS2 package that can be integrated into calling a DS2 program.

    The code representation is [text/vnd.sas.source.ds2].

    Mapped Code

    Path: /ruleSet/{ruleSetId}/mappedCode

    Responds with a full executable program based on one of two different types of requests:

    This resource can be retrieved as two different representations:

    Analysis Code

    Path: /ruleSet/{ruleSetId}/analysisCode

    Responds with a full executable program for analysis of the mappedCode results based on application/vnd.sas.score.analysis.request, which is provided within the request.

    This resource can be retrieved as two different representations:

    Rule Set Revisions

    Path: /ruleSets/{ruleSetId}/revisions

    Contains a collection of rule set objects, which are specific revisions of the rule set over time. Default page size is 10.

    The revisions collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.business.rule.set resources. These types apply to the response for the self, collection, prev, next, first, and last links below.

    The response includes the following links.

    Relation Method Description
    self GET Returns the current page from the collection.
    collection GET Returns the first page of the collection, without sorting or filtering criteria.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Returns the parent resource, which is the root of this API.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the ruleSets collection is by ascending creationTimeStamp.

    Filtering and sorting can use the following members of a ruleSet:

    Filter by name - ?filter=eq(name, 'LoanApproval')

    Filter by multiple names - ?filter=in(name, 'LoanApproval', 'CreditApproval')

    Filter by time value - ?filter=gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combining filters - ?filter=and(gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    Rule Set Revision

    Path: /ruleSet/{ruleSetId}/revisions/{revisionId}

    Represents a rule set revision.

    This resource can be retrieved as two different representations:

    The response includes the following links.

    Relation Method Description
    self GET Returns the full representation of the rule set.
    delete DELETE Deletes the rule set revision. This link appears only for a locked revision.
    code GET Returns the DS2 Package code based on the rule set logic.
    Response type: [text/vnd.sas.source.ds2]
    mappedCode POST Generates code that is mapped to a score definition.
    Request type: application/vnd.sas.score.code.generation.request
    Response type: application/vnd.sas.score.mapped.code
    analysisCode POST Generates analysis code that is mapped to a score definition.
    Request type: application/vnd.sas.score.analysis.code.generation.request
    Response type: application/vnd.sas.score.analysis.code
    rules GET Returns the first page of the rules contained with this rule set.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.business.rule
    up GET Returns the parent resource.
    rulesOrder GET Returns the order in which the rules execute.
    Response type: application/vnd.sas.selection
    Revision Rules

    Path: /ruleSets/{ruleSetId}/revision/{revisionId}/rules

    Contains the collection of rules for the rule set revision.

    The default page size is 10.

    The rules collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.business.rule resources. These types apply to the response for the self, collection, prev, next, first, and last links below.

    The response includes the following links.

    Relation Method Description
    self GET Returns the current page from the collection.
    collection GET Returns the first page of the collection, without sorting or filtering criteria.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Returns the parent resource, which is the root of this API.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the rules collection is by the ordering returned by the `/ruleSets/{ruleSetsId}/revisions/{revisionId}/order.

    Filtering and sorting can use the following members of a businessRule:

    Filter by name - ?filter=eq(name, 'LoanApproval')

    Filter by multiple names - ?filter=in(name, 'LoanApproval', 'CreditApproval')

    Filter by time value - ?filter=gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combining filters - ?filter=and(gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    Revision Rule Ordering

    Path: /ruleSet/{ruleSetId}/revisions/{revisionId}/order

    Contains the full ordering of the rules within the rule set revision by ID.

    The order representation is application/vnd.sas.selection.

    Links provided on this resource.

    Relation Method Description
    self GET Returns the full representation of the rule set.
    up GET Returns the parent resource.
    Revision Package Code

    Path: /ruleSet/{ruleSetId}/revision/{revisionId}/code

    Returns a representation of the rule set revision as a DS2 package that can be integrated into calling a DS2 program.

    The code representation is [text/vnd.sas.source.ds2].

    Revision Mapped Code

    Path: /ruleSet/{ruleSetId}/revision/{revisionId}/mappedCode

    Responds with a full executable program for the revision based on one of two different types of requests:

    This resource can be retrieved as two different representations:

    Revision Analysis Code

    Path: /ruleSet/{ruleSetId}/revision/{revisionId}/analysisCode

    Responds with a full executable program for analysis of the mappedCode results generated for the revision based on application/vnd.sas.score.analysis.request, which is provided within the request.

    This resource can be retrieved as two different representations:

    Rules

    Path: /rules

    This resource can be retrieved as two different representations:

    Links and paging are not supported when retrieved using text/csv.

    The default page size is 10.

    The rules collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.business.rule.query.result resources. These types apply to the response for the self, collection, prev, next, first, and last links below.

    The response includes the following links.

    Relation Method Description
    self GET Returns the current page from the collection.
    collection GET Returns the first page of the collection, without sorting or filtering criteria.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Returns the parent resource, which is the root of this API.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the rules collection is by ascending creationTimeStamp.

    Filtering and sorting can use the following members of a businessRuleQuery:

    Filter by name - ?filter=eq(name, 'Verify Age')

    Filter by multiple names - ?filter=in(name, 'Verify Age', 'Check Credit')

    Filter by time value - ?filter=gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combining filters - ?filter=and(gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    Find only rules from the current, unlocked versions of all rule sets - ?filter=eq(ruleSetLocked, false)

    Reference Data

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Reference Data API supports the life cycle of reference data.

    Usage Notes

    Overview

    Reference data defines key business values that are leveraged across many processes within an organization. This is done by creating a central point for an organization to manage and reference the data. Reference data values are often used to group other data.

    Here are some examples of reference data:

    Note: These examples show the use of reference data as providing standards, types and codes, taxonomy, and relationships. Reference data can change at different intervals but changes are generally controlled and in most cases do not happen frequently.

    Reference data can be used in multiple ways. Reference data that provides criteria for a customer loyalty program can be used in expressions in business rules that when executed, renders a conclusion about something. Reference data that provides specifications of financial products can be used across layers of a financial enterprise to ensure the integrity of inter-operation with third parties.

    One type of reference data is lookup tables. A lookup table provides a link from one value to another value. For example, a lookup table of product codes allows a product to be identified using a code.

    Reference data can be defined by standard bodies or by an organization for standardizing its own information. For the latter case, there is a need for properly managing reference data as the data are often used in a wide range of applications within the organization.

    The Reference Data API supports the life cycle of reference data from creation to CRUD operations to production publishing. This API provides an important aspect of reference data management by providing the history of data values.

    Version 1.0 of the Reference Data API supports reference data in lookup table form. Version 3.0 of the Reference Data API adds support for global variables.

    Why Use this API?

    Terminology

    reference data

    defines data that are referred to by other applications or systems. When referenced, the reference data defines the set of permissible values. An example is a lookup table is a type of reference data. An application that refers to this lookup table in a data field restricts the permissible value to the keys of the table.

    domain

    related collection of reference data. Each member in the collection is a domain content. See also: application/vnd.sas.data.reference.domain

    domain type

    describes how the reference data in a domain are organized. A lookup table domain collects items that stand for other items. An example is a table of U.S. state abbreviations allows the full name of a state to be looked up by its abbreviation.

    domain content

    entries that make up the domain. The domain content is versioned. See also: application/vnd.sas.data.reference.domain.content

    domain current content

    entries that should be used when an application, that uses the reference data domain, executes. The domain content has been assigned the production status and has not been superseded by another production domain content.

    domain content history

    presents the history of the domain's current contents. The domain content history also lists the beginning and ending time stamps for the status. See also: application/vnd.sas.data.reference.domain.content.history

    domain entry

    a name/value pair. For the lookup table type, each value is a character string. See also: application/vnd.sas.data.reference.domain.entry

    standing

    comparing one content to another content in the same domain.

    Operations

    Root

    Contains the operations for the root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/referenceData/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/referenceData/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns a list of links to the top-level resources in this API.

    Example responses

    200 Response

    {
      "version": 1,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No service exists at the requested path. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Reference Data

    Contains operations to create, read, update, and delete reference data.

    Get all reference data domains

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/domains#search \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.search.indexable.data+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.search.indexable.data+json'
    };
    
    fetch('https://example.com/referenceData/domains#search',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.search.indexable.data+json'
    }
    
    r = requests.get('https://example.com/referenceData/domains#search', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.search.indexable.data+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/domains#search", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /domains#search

    Returns a collection of information about each domain.

    Parameters
    Name In Type Required Description
    start query integer false The starting index of the first item on a page. The index is 0-based. The default index is 0.
    limit query integer false 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.
    sortBy query string(sort-criteria) false The sorting criteria for the returned reference data domains. The default sort order is creationTimeStamp:ascending.
    filter query string(filter-criteria) false The filter criteria for the returned domains.
    Accept-Item header string false Selects the desired item representation.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.search.indexable.data+json

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "codeName": "string",
          "formatName": "string",
          "packageName": "string",
          "domainType": "string",
          "description": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "createdBy": "string",
          "modifiedBy": "string",
          "folderType": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. domainCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No collections were found for this domain. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new reference data domain

    Code samples

    # You can also use wget
    curl -X POST https://example.com/referenceData/domains \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.data.reference.domain+json' \
      -H 'Accept: application/vnd.sas.data.reference.domain+json'
    
    
    const inputBody = '{
      "name": "string",
      "codeName": "string",
      "formatName": "string",
      "packageName": "string",
      "domainType": "string",
      "description": "string",
      "folderType": "string"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.data.reference.domain+json',
      'Accept':'application/vnd.sas.data.reference.domain+json'
    };
    
    fetch('https://example.com/referenceData/domains',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.data.reference.domain+json',
      'Accept': 'application/vnd.sas.data.reference.domain+json'
    }
    
    r = requests.post('https://example.com/referenceData/domains', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.data.reference.domain+json"},
            "Accept": []string{"application/vnd.sas.data.reference.domain+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/referenceData/domains", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /domains

    The domain exists after a successful post. The child contents collection is empty. All domain names must be unique. Domains in the same folder must have unique names. Domains not in any folder also must have unique names.

    Body parameter

    {
      "name": "string",
      "codeName": "string",
      "formatName": "string",
      "packageName": "string",
      "domainType": "string",
      "description": "string",
      "folderType": "string"
    }
    
    Parameters
    Name In Type Required Description
    parentFolderUri query string false Adds the domain as a member of a folder.
    body body domain true The domain representation. Use only the name, description, and domainType.

    Example responses

    201 Response

    {
      "id": "string",
      "name": "string",
      "codeName": "string",
      "formatName": "string",
      "packageName": "string",
      "domainType": "string",
      "description": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "modifiedBy": "string",
      "folderType": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A new domain was created. domain
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string The URI of the new domain.
    201 ETag string A tag that identifies this domain.

    Get a reference data domain

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/domains/{domainId}#search \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.search.indexable.data+json' \
      -H 'Accept: application/vnd.sas.search.indexable.data+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.search.indexable.data+json',
      'Accept':'application/vnd.sas.search.indexable.data+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}#search',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.search.indexable.data+json',
      'Accept': 'application/vnd.sas.search.indexable.data+json'
    }
    
    r = requests.get('https://example.com/referenceData/domains/{domainId}#search', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.search.indexable.data+json"},
            "Accept": []string{"application/vnd.sas.search.indexable.data+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/domains/{domainId}#search", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /domains/{domainId}#search

    Returns information about the domain. The creation user ID and time stamp of the domain cannot be changed. The user ID and modification time stamp changes when information about the domain changes or when a child resource of the domain changes.

    Parameters
    Name In Type Required Description
    domainId path string true The identifier of a domain.
    Accept header string true Selects the desired item representation.
    Enumerated Values
    Parameter Value
    Accept application/vnd.sas.search.indexable.data+json

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "codeName": "string",
      "formatName": "string",
      "packageName": "string",
      "domainType": "string",
      "description": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "modifiedBy": "string",
      "folderType": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. domain
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No domain exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this domain.

    Update a reference data domain

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/referenceData/domains/{domainId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.data.reference.domain+json' \
      -H 'Accept: application/vnd.sas.data.reference.domain+json' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "name": "string",
      "codeName": "string",
      "formatName": "string",
      "packageName": "string",
      "domainType": "string",
      "description": "string",
      "folderType": "string"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.data.reference.domain+json',
      'Accept':'application/vnd.sas.data.reference.domain+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.data.reference.domain+json',
      'Accept': 'application/vnd.sas.data.reference.domain+json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/referenceData/domains/{domainId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.data.reference.domain+json"},
            "Accept": []string{"application/vnd.sas.data.reference.domain+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/referenceData/domains/{domainId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /domains/{domainId}

    Updates the information of a domain. Only the description can be changed.

    Body parameter

    {
      "name": "string",
      "codeName": "string",
      "formatName": "string",
      "packageName": "string",
      "domainType": "string",
      "description": "string",
      "folderType": "string"
    }
    
    Parameters
    Name In Type Required Description
    domainId path string true The identifier for a domain.
    If-Match header string false The ETag value that was returned from a GET, POST, or PATCH of the domain entry collection. If the ETag value does not match the etag value of the resource, the update fails.
    body body domain true The domain representation. Use only the description member.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "codeName": "string",
      "formatName": "string",
      "packageName": "string",
      "domainType": "string",
      "description": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "modifiedBy": "string",
      "folderType": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. domain
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. The resource has changed. Inline
    428 Precondition Required The If-Match request header did not match the resource's entity tag. The 'If-Match' header was not sent. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this domain.

    Delete a domain

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/referenceData/domains/{domainId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.delete('https://example.com/referenceData/domains/{domainId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/referenceData/domains/{domainId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /domains/{domainId}

    Deletes a domain.

    Parameters
    Name In Type Required Description
    domainId path string true The identifier for a domain.
    deleteProductionContent query string false If the value is true, a domain with content in production status can be deleted. If the value is false, a domain with content in production status cannot be deleted.

    Example responses

    400 Response

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    204 No Content The domain was deleted. None
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get all contents of a reference data domain

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/domains/{domainId}/contents \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/contents',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/referenceData/domains/{domainId}/contents', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/domains/{domainId}/contents", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /domains/{domainId}/contents

    Returns a collection of information about each content. For each domain content in the collection, when the activationStatus of the content is running, the endpoint takes an additional step to query the results of the asynchronous publishes of the content. The activationStatus field of the content continues to show running if the asynchronous publishes have not all completed.

    If all have completed, and if one publish has failed, the status field shows activating, the activationStatus field shows failed and the activationError field shows the cause of the failure. If all publishes have succeeded, the status field shows production, the activationStatus field shows active, and the activationError field is cleared of any text that might have been there before.

    Parameters
    Name In Type Required Description
    domainId path string true The identifier for a specific domain.
    start query integer false The starting index of the first item on a page. The index is 0-based. The default index is 0.
    limit query integer false 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.
    sortBy query string(sort-criteria) false Sorting criteria for the returned contents. The default sort order is creationTimeStamp:ascending.
    filter query string(filter-criteria) false The filter criteria for the returned contents.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "label": "string",
          "majorNumber": "string",
          "minorNumber": "string",
          "status": "string",
          "standing": "string",
          "activationStatus": "string",
          "activationError": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "createdBy": "string",
          "modifiedBy": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. domainContentCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No domain content collection exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this domain content collection.

    Create new reference data domain content

    Code samples

    # You can also use wget
    curl -X POST https://example.com/referenceData/domains/{domainId}/contents \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.data.reference.domain.content+json' \
      -H 'Accept: application/vnd.sas.data.reference.domain.content+json'
    
    
    const inputBody = '{
      "label": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "string",
      "standing": "string",
      "activationStatus": "string",
      "activationError": "string"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.data.reference.domain.content+json',
      'Accept':'application/vnd.sas.data.reference.domain.content+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/contents',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.data.reference.domain.content+json',
      'Accept': 'application/vnd.sas.data.reference.domain.content+json'
    }
    
    r = requests.post('https://example.com/referenceData/domains/{domainId}/contents', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.data.reference.domain.content+json"},
            "Accept": []string{"application/vnd.sas.data.reference.domain.content+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/referenceData/domains/{domainId}/contents", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /domains/{domainId}/contents

    The status is used to determine the standing of this content among the collection of contents. If the status is "production", the standing is current. The version that was the current production has its standing changed to "legacy". For other status values, the standing of the version is future. The version that has the future standing has its standing changed to "inactive". In a collection there is at most, one current and one future version at any time.

    The major and minor numbers are optional. Here is how the major and minor numbers are used:

    Body parameter

    {
      "label": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "string",
      "standing": "string",
      "activationStatus": "string",
      "activationError": "string"
    }
    
    Parameters
    Name In Type Required Description
    domainId path string true The identifier for a specific domain.
    fromRevisionUri query string false This value specifies the URI of the domain content this new domain content is being created from. This property allows for the lineage of a domain to be traced. The valid format for this parameter is '/referenceData/domains/${domainId}/contents/${contentId}'
    body body domainContent true Version of the domain content. Use only label, status, majorNumber, and minorNumber.

    Example responses

    201 Response

    {
      "id": "string",
      "label": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "string",
      "standing": "string",
      "activationStatus": "string",
      "activationError": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "modifiedBy": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A new domain content was created. domainContent
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No domain content exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string The URI of this domain content.
    201 ETag string A tag that identifies this domain content.

    Get domain content

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/domains/{domainId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.data.reference.domain.content+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.data.reference.domain.content+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/contents/{contentId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.data.reference.domain.content+json'
    }
    
    r = requests.get('https://example.com/referenceData/domains/{domainId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.data.reference.domain.content+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/domains/{domainId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /domains/{domainId}/contents/{contentId}

    Only information describing the content is returned. The associated reference data entries are not returned. The creation user ID and timestamp of the domain content cannot be changed. The user ID and modification timestamp changes when information about the content changes or when a child resource of the version changes.

    When the activationStatus of the content is "running", the endpoint takes an additional step to query the results of the asynchronous publishes. The activationStatus continues to show "running" if the asynchronous publishes have not all completed. If all have completed, and if one publish has failed, the status field shows "activating", the activationStatus field shows "failed" and the activationError field shows the cause of the failure. If all publishes have succeeded, the status field show "production", the activationStatus field shows "active" and the activationError field is cleared of any text that might be there before.

    Parameters
    Name In Type Required Description
    domainId path string true The identifier for a reference data domain.
    contentId path string true The identifier for a reference data domain content.

    Example responses

    200 Response

    {
      "id": "string",
      "label": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "string",
      "standing": "string",
      "activationStatus": "string",
      "activationError": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "modifiedBy": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. domainContent
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No domain content exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this domain content.

    Delete reference data domain content

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/referenceData/domains/{domainId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/contents/{contentId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.delete('https://example.com/referenceData/domains/{domainId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/referenceData/domains/{domainId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /domains/{domainId}/contents/{contentId}

    Deletes the content of a reference data domain.

    Parameters
    Name In Type Required Description
    domainId path string true The identifier for a reference data domain.
    contentId path string true The identifier for a reference data domain content.
    deleteProductionContent query string false If the value is true, a domain with content in "production" status can be deleted. If the value is false or if this parameter is not used, a domain with content in "production" status cannot be deleted.

    Example responses

    400 Response

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    204 No Content The domain was deleted. None
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No domain exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Update reference data domain content

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/referenceData/domains/{domainId}/contents/{contentId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.data.reference.domain.content+json' \
      -H 'Accept: application/vnd.sas.data.reference.domain.content+json' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "label": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "string",
      "standing": "string",
      "activationStatus": "string",
      "activationError": "string"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.data.reference.domain.content+json',
      'Accept':'application/vnd.sas.data.reference.domain.content+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/contents/{contentId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.data.reference.domain.content+json',
      'Accept': 'application/vnd.sas.data.reference.domain.content+json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/referenceData/domains/{domainId}/contents/{contentId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.data.reference.domain.content+json"},
            "Accept": []string{"application/vnd.sas.data.reference.domain.content+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/referenceData/domains/{domainId}/contents/{contentId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /domains/{domainId}/contents/{contentId}

    Update the content of a domain. The label can always be changed. The status of a production version cannot be changed back to "candidate" or "developing". The majorNumber and minorNumber cannot be changed. If the status is to be changed to "production", the domain content must have one or more entries. Otherwise, you get an error.

    When the status of the content is changed to production, the entries in the version are published to two location types. The first type is all the Micro Analytic Score service publish destinations defined in the deployment. The second type is all the Cloud Analytic Services servers available to the deployment. To each Micro Analytic Score destination, a public module containing a DS2 package is published. The package is named using the packageName field of the domain. In the package, the domain content is shown as a hash table. The find method of the package can be used to search the hash table to look up a value in the domain content using a key. On each Cloud Analytic Services server, a format is created in a global formats library to realize the domain content. The name for the format is the formatName field of the domain. If publishing the entries to either location fails, the status of the domain version is not changed to "production".

    The asynchronous parameter changes only the behavior of the endpoint when the status of a domain content is to be changed to production. In that scenario, the content status change becomes a two-stage process. The first stage is to change the status to activating while the publish to the various destinations are initiated. After the publish initiation, the endpoint changes the activationStatus of the content to running and then returns. The second stage of changing the status of the domain content to production is achieved when the statuses of the publishes are obtained and resolved to total success. When you issue a GET operation on the domain content or the contents collection of the domain, if all the publishes have finished, the status for the content shows "production", if all publishes have finished successfully. The content status remains in "activating" and the activationStatus showing "failed" if at least one publish failed. If a publish is still running, the activationStatus continues to show "running".

    The currentContents endpoint does not show the content as production until the result of the asynchronous publish is known and all publishes are successful.

    Note that publish to Micro Analytic Score service destinations can be disabled via SAS Environment Manager. This can be accomplished by enabling property "lookupDisableMasPublish" under category "sas.referencedata.publish". If "lookupDisableMasPublish" is enabled, then "lookupStaticBinding" under category "sas.businessrules" should also be enabled.

    Body parameter

    {
      "label": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "string",
      "standing": "string",
      "activationStatus": "string",
      "activationError": "string"
    }
    
    Parameters
    Name In Type Required Description
    domainId path string true The identifier of a reference data domain.
    contentId path string true The identifier of a reference data domain content.
    asynchronous query boolean false Indicate whether the production publish is asynchronous or synchronous. If true, the production publish is asynchronous. The default is false.
    If-Match header string false The ETag value that was returned from a GET, POST, or PATCH of the domain entry collection. If the ETag value does not match the etag value of the resource, the update fails.
    body body domainContent true The content representation. Use only the label and status member.

    Example responses

    200 Response

    {
      "id": "string",
      "label": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "string",
      "standing": "string",
      "activationStatus": "string",
      "activationError": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "modifiedBy": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. domainContent
    202 Accepted The request is accepted. domainContent
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No domain content exists at the requested path. Resource is not found. Inline
    412 Precondition Failed The ETag value used in the If-Match header did not match the resource's last modified timestamp. The resource has changed. Inline
    428 Precondition Required The If-Match request header did not match the resource's entity tag. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this domain content.
    202 ETag string A tag that identifies this domain content.

    Get the entries for the content of a reference data domain

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /domains/{domainId}/contents/{contentId}/entries

    There are two media types that can be used with the Accept header of the request. The first one is application/vnd.sas.collection. This causes a page of entries in the domain content to be returned. The second one is text/csv. The text/csv follows the RFC 4180 format. This causes all the entries in the domain content to be returned because the response content paging is not supported. Use the paging support parameters start and limit when accepting text/csv.

    Parameters
    Name In Type Required Description
    domainId path string true The identifier of a reference data domain.
    contentId path string true The identifier of a reference data domain content.
    start query integer false The starting index of the first item on a page. The index is 0-based. The default index is 0.
    limit query integer false 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.
    sortBy query string(sort-criteria) false The sort criteria for the returned entries. The default sort order is key:ascending.
    filter query string(filter-criteria) false The filter criteria for the returned entries.
    Accept header string false Choose the representation of the returned entries.
    Enumerated Values
    Parameter Value
    Accept application/vnd.sas.collection+json
    Accept text/csv

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "key": "string",
          "value": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this domain entry collection.

    Create or replace reference for data domain entries

    Code samples

    # You can also use wget
    curl -X POST https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.collection+json' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'If-Match: string' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    const inputBody = '[
      {
        "key": "string",
        "value": "string"
      }
    ]';
    const headers = {
      'Content-Type':'application/vnd.sas.collection+json',
      'Accept':'application/vnd.sas.collection+json',
      'If-Match':'string',
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.collection+json',
      'Accept': 'application/vnd.sas.collection+json',
      'If-Match': 'string',
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.post('https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.collection+json"},
            "Accept": []string{"application/vnd.sas.collection+json"},
            "If-Match": []string{"string"},
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /domains/{domainId}/contents/{contentId}/entries

    If the containing domain content has the status of "production", the creation or replacement of entries is not allowed. There are two media types that can be used with the Content-Type header of the request. The first one is application/vnd.sas.collection. The second one is text/csv. text/csv follows the RFC 4180 format.

    The same media types can also be used with the Accept header of the request. However, the Content-Type and Accept combination of application/vnd.sas.collection and text/csv is not valid. When the Accept media type is application/vnd.sas.collection, the first page of the sorted entries, by ascending keys, is returned. When the Accept media type is text/csv, all the entries sorted in ascending keys are returned.

    Body parameter

    [
      {
        "key": "string",
        "value": "string"
      }
    ]
    
    Parameters
    Name In Type Required Description
    domainId path string true The identifier of a reference data domain.
    contentId path string true The identifier of a reference data domain content.
    If-Match header string false The ETag value that was returned from a GET, POST, or PATCH of the domain entry collection. This is not required when creating domain entries but required when replacing domain entries. If the etag is required but the value does not match the ETag value of the resource, the replacement of domain entries fails.
    Accept header string false Choose the representation of the returned entries.
    body body domainEntry true The collection holding the entries.
    Enumerated Values
    Parameter Value
    Accept application/vnd.sas.collection+json
    Accept text/csv

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "key": "string",
          "value": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The entries were replaced. string
    201 Created The entries were created. string
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Resource is not found. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Location string The URI of the domain entry collection.
    200 ETag string A tag that identifies this domain entry collection.
    201 Location string The URI of the new domain entry collection.
    201 ETag string A tag that identifies this domain entry collection.

    Update the reference data entries

    Code samples

    # You can also use wget
    curl -X PATCH https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/json-patch+json' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'If-Match: string'
    
    
    const inputBody = '[
      {
        "op": "string",
        "path": "string",
        "value": "string"
      }
    ]';
    const headers = {
      'Content-Type':'application/json-patch+json',
      'Accept':'application/vnd.sas.collection+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries',
    {
      method: 'PATCH',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/json-patch+json',
      'Accept': 'application/vnd.sas.collection+json',
      'If-Match': 'string'
    }
    
    r = requests.patch('https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/json-patch+json"},
            "Accept": []string{"application/vnd.sas.collection+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PATCH", "https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PATCH /domains/{domainId}/contents/{contentId}/entries

    Updates the domain entries by using an array of add, replace, or delete JSON Patch operations. See https://tools.ietf.org/html/rfc6902 for more information about the JSON Patch.

    First, a JSON document of a certain format is used to represent the entries. These operations are then applied to that document. The resulting document represents what future entries should look like. The specification of the operations is relative to this document format.

    Each JSON Patch operation contains an op, a path, and an optional value member. The operation member names op, path, and value are to be in lowercase only. The op values that can be used are "add", "replace", and "remove". They are in lowercase.

    The path has the form /entry-key or /entry-key/field-name-of-the-entry-representation-object. Each tilde that appears in the entry-key must be escaped as ~0. Each forward slash character that appears in the entry-key must be escaped as ~1.

    The value member is required for add and replace. To add an entry, the path member provides the value of the key and the value member provides values for the other fields of the representation object of the entry. The replace operation provides a new value for any non-key field of the representation object. The remove operation deletes an entry based on the key.

    One or more fields can be changed. The key of the entry cannot be changed. If the containing domain content has the status of "production", the entries cannot be changed. The first page of the sorted entries, by ascending key, is returned.

    Body parameter

    [
      {
        "op": "string",
        "path": "string",
        "value": "string"
      }
    ]
    
    Parameters
    Name In Type Required Description
    domainId path string true The identifier of a reference data domain.
    contentId path string true The identifier of a reference data domain content.
    If-Match header string false The ETag value that was returned from a GET, POST, or PATCH of the domain entry collection. If the ETag value does not match the etag value of the resource, the update fails.
    body body entriesPatch false A JSON document of the JSON Patch operations.

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "key": "string",
          "value": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The entries are successfully patched. domainEntryCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    412 Precondition Failed The ETag value used in the If-Match header did not match the resource's last modified timestamp. The resource has changed. Inline
    422 Unprocessable Entity A request in the patch document asks for an invalid operation. Inline
    428 Precondition Required The If-Match request header did not match the resource's entity tag. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 422

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this domain entry collection.

    Delete entries in reference data domain content

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.delete('https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/referenceData/domains/{domainId}/contents/{contentId}/entries", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /domains/{domainId}/contents/{contentId}/entries

    Deletes the entries in a domain content. If the domain content has the status of "production", the entries cannot be deleted.

    Parameters
    Name In Type Required Description
    domainId path string true The identifier of a reference data domain.
    contentId path string true The identifier of a reference data domain content.

    Example responses

    400 Response

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    204 No Content The content was deleted. None
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. An entry for the reference data domain was not found. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get list of domain contents with "production" status

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/domains/{domainId}/currentContents \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/currentContents',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/referenceData/domains/{domainId}/currentContents', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/domains/{domainId}/currentContents", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /domains/{domainId}/currentContents

    Returns a list of the domain contents that have had the "production" status. For each domain content, show the begin time and end time when the "production" status was ongoing, unless no domain version ever had the "production" status. There is always one domain version whose "production" status end time is not set. This means that the production status is still current.

    Parameters
    Name In Type Required Description
    domainId path string true The identifier of a reference data domain.
    scope query string false Choose current to see which domain content is the current content. Choose all to see the timeline of which domain content was the current content. The default is current.'
    asOf query string(date-time) false Restricts the results to the current contents. This parameter can be used only when the scope parameter equals all.
    start query integer false The starting index of the first item on a page. The index is 0-based. The default index is 0.
    limit query integer false 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.
    sortBy query string(sort-criteria) false The sorting criteria for the returned content history. The default sort order is commencedTimeStamp:ascending when the scope parameter equals all. When the scope parameter equals current, there is no need to use the sortBy parameter in conjunction since at most, one item is returned.
    filter query string(filter-criteria) false The filter criteria for the returned content history. When the scope parameter equals current, a filter expression is added. Since there is at most only one item returned, any additional filter expressions alters the desired result.
    Enumerated Values
    Parameter Value
    scope current
    scope all

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "domainId": "string",
          "versionId": "string",
          "status": "string",
          "commencedTimeStamp": "2019-08-24T14:15:22Z",
          "expiredTimeStamp": "2019-08-24T14:15:22Z",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. domainCurrentContentsCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. A collection for the reference data domain was not found. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this collection.

    Copy domain current content to execution environment

    Code samples

    # You can also use wget
    curl -X PATCH https://example.com/referenceData/domains/{domainId}/currentContents \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/json-patch+json' \
      -H 'Accept: application/vnd.sas.data.reference.domain.content.history+json' \
      -H 'If-Match: string'
    
    
    const inputBody = '[
      {
        "op": "string",
        "from": "string",
        "path": "string"
      }
    ]';
    const headers = {
      'Content-Type':'application/json-patch+json',
      'Accept':'application/vnd.sas.data.reference.domain.content.history+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/referenceData/domains/{domainId}/currentContents',
    {
      method: 'PATCH',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/json-patch+json',
      'Accept': 'application/vnd.sas.data.reference.domain.content.history+json',
      'If-Match': 'string'
    }
    
    r = requests.patch('https://example.com/referenceData/domains/{domainId}/currentContents', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/json-patch+json"},
            "Accept": []string{"application/vnd.sas.data.reference.domain.content.history+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PATCH", "https://example.com/referenceData/domains/{domainId}/currentContents", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PATCH /domains/{domainId}/currentContents

    The copy is done using the JSON Patch operation. See https://tools.ietf.org/html/rfc6902 for more information about the JSON Patch.

    The "copy" JSON Patch operation consists of the op, from, and path members. The member names are to be in lowercase only. The op value is "copy". The from value is /@current. The path value is /@current/environments/cas or /@current/environments/mas. If the domain has a non-expired current content, its representation is returned.

    Body parameter

    [
      {
        "op": "string",
        "from": "string",
        "path": "string"
      }
    ]
    
    Parameters
    Name In Type Required Description
    domainId path string true The identifier of a reference data domain.
    If-Match header string false The ETag value that was returned from a GET of the current contents. If the ETag value does not match the resource ETag value, the patch fails.
    body body currentContentsPatch false A JSON document of the JSON Patch operations.

    Example responses

    200 Response

    {
      "id": "string",
      "domainId": "string",
      "versionId": "string",
      "status": "string",
      "commencedTimeStamp": "2019-08-24T14:15:22Z",
      "expiredTimeStamp": "2019-08-24T14:15:22Z",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. domainContentHistory
    400 Bad Request The request was invalid. The domain does not have current content. Inline
    404 Not Found No resource exists at the requested path. Current content for the domain was not found. Inline
    412 Precondition Failed The ETag value used in the If-Match header did not match the resource's ETag value. The resource has changed. Inline
    422 Unprocessable Entity A request in the patch document asks for invalid operation. Inline
    428 Precondition Required The request headers did not include an If-Match precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 422

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this collection.

    Get entries in latest domain content for all reference data domains

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/domainEntries \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/csv' \
      -H 'Accept: text/csv, application/json'
    
    
    
    const headers = {
      'Accept':'text/csv',
      'Accept':'text/csv, application/json'
    };
    
    fetch('https://example.com/referenceData/domainEntries',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/csv',
      'Accept': 'text/csv, application/json'
    }
    
    r = requests.get('https://example.com/referenceData/domainEntries', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/csv"},
            "Accept": []string{"text/csv, application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/domainEntries", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /domainEntries

    Returns all the entries as CSV. A header is not returned by default. It can be requested by adding the header=present option to the text/csv media type. The order of the columns is domain name, domain description, path of the folder that contains the domain, key, and value. A query parameter can be used to select domains that are members of a folder hierarchy.

    Parameters
    Name In Type Required Description
    folderPath query string false A complete path or the prefix of a folder path. This value is used to select those reference data domains where the parameter value is either a prefix of the parent folder or matches the parent folder paths of those domains.
    Accept header string false In addition to text/csv, also include application/json in the Accept header to prevent the true operation error from being masked by the HTTP status 406 error. The two media types are separated by a comma.
    Enumerated Values
    Parameter Value
    Accept text/csv, application/json

    Example responses

    200 Response

    400 Response

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The export was successful. string
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    406 Not Acceptable 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. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 406

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Content-Disposition string No description

    Bulk import domain entries

    Code samples

    # You can also use wget
    curl -X POST https://example.com/referenceData/domainEntries \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: text/csv' \
      -H 'Accept: multipart/mixed' \
      -H 'Accept: multipart/mixed, application/json' \
      -H 'If-Unmodified-Since: string'
    
    
    const inputBody = 'string';
    const headers = {
      'Content-Type':'text/csv',
      'Accept':'multipart/mixed',
      'Accept':'multipart/mixed, application/json',
      'If-Unmodified-Since':'string'
    };
    
    fetch('https://example.com/referenceData/domainEntries',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'text/csv',
      'Accept': 'multipart/mixed',
      'Accept': 'multipart/mixed, application/json',
      'If-Unmodified-Since': 'string'
    }
    
    r = requests.post('https://example.com/referenceData/domainEntries', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"text/csv"},
            "Accept": []string{"multipart/mixed"},
            "Accept": []string{"multipart/mixed, application/json"},
            "If-Unmodified-Since": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/referenceData/domainEntries", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /domainEntries

    The input is CSV with a header row that specifies the order of these columns:

    On each row in the lookup_nm column, the name of a reference data domain is specified. The description column is the description of the domain. In the folder_path column, the containing folder of the domain is specified. A valid folder value:

    The name column holds a key of the domain entry. The value column holds a value of the domain entry. Only the description column can be blank.

    The bulk import creates the domain in the supplied folder if an identically named domain does not already exist. If the domain already exists, then the entries in the latest domain content are deleted and the entries from the input CSV are added. If the latest domain content has the "production" status, the "delete" and "add" operations cannot be done. Each domain in a folder has a unique name. However, the same domain name can be used in another folder.

    The input CSV is processed in the order it is received. All contiguous rows with the same domain name and folder path are considered one section. Those rows are processed according to the description above. It is possible to have the same domain name and folder path appearing in non-consecutive sections. In that case, the subsequent section is considered a replacement of the domain entries from the previous section. The service tries to process as many rows as possible.

    The output is a multipart/mixed response body. The boundary string of each part is identified in the Content-Type response header. There are three parts in this response.

    1. The first part is for the accepted CSV (header Content-ID: Accepted-CSV). Each row that was successfully imported is included here. As soon as a domain is processed, the successful rows are streamed back.
    2. The second part is for the rejected CSV (header Content-ID:Rejected-CSV). Each CSV row that failed processing is identified here. It is in CSV format with the following column order: record number in the entire CSV input, lookup_nm, description, folder_path, name, value, and error message.
    3. The third part is for global issues (header Content-ID: Global-Issue). It is in CSV format with the following column order: lookup_nm and error message. The message conveys the error at the domain level that prevents any CSV importing. An example would be the lack of permissions to create the containing folder. If this error applies to the entire input, the lookup_nm column has an asterisk. If this error applies to only a domain, then the domain is identified in the lookup_nm column.

    Body parameter

    Parameters
    Name In Type Required Description
    Accept header string true In addition to multipart/mixed, also include application/json in the Accept header to prevent the true operation error from being masked by the HTTP status 406 error. The media types are separated by a comma.
    If-Unmodified-Since header string false Checks to see whether the existing domains identified in the CSV have not been modified since the time specified in the value. If this is not true, the update is not performed.
    body body string true The CSV that contains a header row.
    Enumerated Values
    Parameter Value
    Accept multipart/mixed, application/json

    Example responses

    200 Response

    400 Response

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. One or more entries were created or updated. Check the response for any error. string
    400 Bad Request The request was invalid. No entry was imported. Inline
    404 Not Found No resource exists at the requested path. The URI was not found. Inline
    406 Not Acceptable The media type is incompatible. Occurs when there is an error but the error response media type is not compatible with the multipart/mixed media type. The REST client or browser returns this status error instead. Inline
    412 Precondition Failed The If-Unmodified-Since request header did not match the resource's last modified timestamp. The resources have changed. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 406

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Location string The URI for retrieving the domains that were created or modified.

    Global Variable

    Contains operations to create, read, update, and delete global variables.

    Get the list of global variables

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/globalVariables \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.data.reference.global.variable+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.data.reference.global.variable+json'
    };
    
    fetch('https://example.com/referenceData/globalVariables',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.data.reference.global.variable+json'
    }
    
    r = requests.get('https://example.com/referenceData/globalVariables', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.data.reference.global.variable+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/globalVariables", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /globalVariables

    Returns a list of global variables. The expected number of global variables is small therefore this endpoint does not support paging, filtering, or sorting of parameters.

    Parameters
    Name In Type Required Description
    Accept header string false Select the desired representation.
    Accept-Item header string false Select the desired item representation.
    activeRevisions query string false If set to true, return "active" revision rather than (default) "current" revision.
    Enumerated Values
    Parameter Value
    Accept application/vnd.sas.collection+json
    Accept application/json
    Accept-Item application/vnd.sas.data.reference.global.variable+json

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "majorNumber": "string",
          "minorNumber": "string",
          "status": "developing",
          "locked": true,
          "activeVersionId": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. globalVariableCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new global variable

    Code samples

    # You can also use wget
    curl -X POST https://example.com/referenceData/globalVariables \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.data.reference.global.variable+json' \
      -H 'Accept: application/vnd.sas.data.reference.global.variable+json'
    
    
    const inputBody = '{
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.data.reference.global.variable+json',
      'Accept':'application/vnd.sas.data.reference.global.variable+json'
    };
    
    fetch('https://example.com/referenceData/globalVariables',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.data.reference.global.variable+json',
      'Accept': 'application/vnd.sas.data.reference.global.variable+json'
    }
    
    r = requests.post('https://example.com/referenceData/globalVariables', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.data.reference.global.variable+json"},
            "Accept": []string{"application/vnd.sas.data.reference.global.variable+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/referenceData/globalVariables", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /globalVariables

    Creates a new global variable. All global variable names must be unique.

    Body parameter

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    body body globalVariable true The global variable representation. Only the name, type and value are required.

    Example responses

    201 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A new global variable was created. globalVariable
    400 Bad Request The request was invalid. errorResponse
    409 Conflict A global variable with that name already exists. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 409

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string The URI of the new domain.
    201 ETag string A tag that identifies this domain.

    Get a global variable

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/globalVariables/{globalVariableId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.data.reference.global.variable+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.data.reference.global.variable+json'
    };
    
    fetch('https://example.com/referenceData/globalVariables/{globalVariableId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.data.reference.global.variable+json'
    }
    
    r = requests.get('https://example.com/referenceData/globalVariables/{globalVariableId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.data.reference.global.variable+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/globalVariables/{globalVariableId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /globalVariables/{globalVariableId}

    Get a global variable with provided globalVariableId.

    Parameters
    Name In Type Required Description
    globalVariableId path string true The identifier of a global variable.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. globalVariable
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this global variable.

    Update a global variable

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/referenceData/globalVariables/{globalVariableId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.data.reference.global.variable+json' \
      -H 'Accept: application/vnd.sas.data.reference.global.variable+json' \
      -H 'If-Match: string'
    
    
    const inputBody = '{
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.data.reference.global.variable+json',
      'Accept':'application/vnd.sas.data.reference.global.variable+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/referenceData/globalVariables/{globalVariableId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.data.reference.global.variable+json',
      'Accept': 'application/vnd.sas.data.reference.global.variable+json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/referenceData/globalVariables/{globalVariableId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.data.reference.global.variable+json"},
            "Accept": []string{"application/vnd.sas.data.reference.global.variable+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/referenceData/globalVariables/{globalVariableId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /globalVariables/{globalVariableId}

    Updates the specified global variable

    Body parameter

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    globalVariableId path string true The identifier of a global variable.
    If-Match header string true The ETag value that was returned from a GET, or POST.
    body body globalVariable true The global variable representation. Only the name, type and value are required.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The global variable was replaced. globalVariable
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Resource is not found. Inline
    412 Precondition Failed The ETag value used in the If-Match header did not match the resource's ETag value. Inline
    428 Precondition Required The request headers did not include a If-Match precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this global variable.

    Delete a global variable

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/referenceData/globalVariables/{globalVariableId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/referenceData/globalVariables/{globalVariableId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.delete('https://example.com/referenceData/globalVariables/{globalVariableId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/referenceData/globalVariables/{globalVariableId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /globalVariables/{globalVariableId}

    Deletes the specified global variable.

    Parameters
    Name In Type Required Description
    globalVariableId path string true The identifier of a global variable.

    Example responses

    404 Response

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    204 No Content The global variable was deleted. None
    404 Not Found No global variable exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Get the list of revisions for a global variable

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/globalVariables/{globalVariableId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.data.reference.global.variable+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.data.reference.global.variable+json'
    };
    
    fetch('https://example.com/referenceData/globalVariables/{globalVariableId}/revisions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.data.reference.global.variable+json'
    }
    
    r = requests.get('https://example.com/referenceData/globalVariables/{globalVariableId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.data.reference.global.variable+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/globalVariables/{globalVariableId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /globalVariables/{globalVariableId}/revisions

    Returns a list of global variables.

    Parameters
    Name In Type Required Description
    globalVariableId path string true The identifier of a global variable.
    start query integer false The starting index of the first item on a page. The index is 0-based. The default index is 0.
    limit query integer false 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.
    sortBy query string(sort-criteria) false Criteria used for sorting the global variable revisions. The default sort order is creationTimeStamp:ascending.
    filter query string(filter-criteria) false The filter criteria for the returned global variable revisions.
    Accept header string false Select the desired representation.
    Accept-Item header string false Select the desired item representation.
    Enumerated Values
    Parameter Value
    Accept application/vnd.sas.collection+json
    Accept application/json
    Accept-Item application/vnd.sas.data.reference.global.variable+json

    Example responses

    200 Response

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "majorNumber": "string",
          "minorNumber": "string",
          "status": "developing",
          "locked": true,
          "activeVersionId": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. globalVariableCollection
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new global variable revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/referenceData/globalVariables/{globalVariableId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.data.reference.global.variable+json' \
      -H 'Accept: application/vnd.sas.data.reference.global.variable+json'
    
    
    const inputBody = '{
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.data.reference.global.variable+json',
      'Accept':'application/vnd.sas.data.reference.global.variable+json'
    };
    
    fetch('https://example.com/referenceData/globalVariables/{globalVariableId}/revisions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.data.reference.global.variable+json',
      'Accept': 'application/vnd.sas.data.reference.global.variable+json'
    }
    
    r = requests.post('https://example.com/referenceData/globalVariables/{globalVariableId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.data.reference.global.variable+json"},
            "Accept": []string{"application/vnd.sas.data.reference.global.variable+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/referenceData/globalVariables/{globalVariableId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /globalVariables/{globalVariableId}/revisions

    Creates a new global variable revision. All global variable names must be unique.

    Body parameter

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    globalVariableId path string true The identifier of a global variable.
    revisionType query string false 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 global variable 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.
    body body globalVariable true The global variable representation. Only the name, type and value are required.
    Enumerated Values
    Parameter Value
    revisionType major
    revisionType minor

    Example responses

    201 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A new global variable revision was created. globalVariable
    400 Bad Request The request was invalid. errorResponse
    409 Conflict A global variable with that name already exists. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 409

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string The URI of the new domain.
    201 ETag string A tag that identifies this global variable.

    Activate revision of a global variable

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/referenceData/globalVariables/{globalVariableId}/active \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: text/plain' \
      -H 'Accept: application/vnd.sas.data.reference.global.variable+json' \
      -H 'If-Match: string'
    
    
    const inputBody = 'string';
    const headers = {
      'Content-Type':'text/plain',
      'Accept':'application/vnd.sas.data.reference.global.variable+json',
      'If-Match':'string'
    };
    
    fetch('https://example.com/referenceData/globalVariables/{globalVariableId}/active',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'text/plain',
      'Accept': 'application/vnd.sas.data.reference.global.variable+json',
      'If-Match': 'string'
    }
    
    r = requests.put('https://example.com/referenceData/globalVariables/{globalVariableId}/active', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"text/plain"},
            "Accept": []string{"application/vnd.sas.data.reference.global.variable+json"},
            "If-Match": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/referenceData/globalVariables/{globalVariableId}/active", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /globalVariables/{globalVariableId}/active

    Activate a revision of the specified global variable by providing its ID.

    Body parameter

    string
    
    
    Parameters
    Name In Type Required Description
    globalVariableId path string true The identifier of a global variable.
    If-Match header string true The ETag value that was returned from a GET, or POST.
    body body string true The global variable revision to activate

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. globalVariable
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No global variable revision exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match precondition. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this global variable.

    Get a global variable revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/referenceData/globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.data.reference.global.variable+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.data.reference.global.variable+json'
    };
    
    fetch('https://example.com/referenceData/globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.data.reference.global.variable+json'
    }
    
    r = requests.get('https://example.com/referenceData/globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.data.reference.global.variable+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/referenceData/globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId}

    Get a global variable revision of the specified global variable by providing its globalVariableId and globalVariableRevisionId.

    Parameters
    Name In Type Required Description
    globalVariableId path string true The identifier of a global variable.
    globalVariableRevisionId path string true The identifier of a global variable revision.

    Example responses

    200 Response

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. globalVariable
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this global variable.

    Delete a global variable revision

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/referenceData/globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/referenceData/globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.delete('https://example.com/referenceData/globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/referenceData/globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /globalVariables/{globalVariableId}/revisions/{globalVariableRevisionId}

    Deletes the specified global variable revision.

    Parameters
    Name In Type Required Description
    globalVariableId path string true The identifier of a global variable.
    globalVariableRevisionId path string true The identifier of a global variable revision. Note that only the non-current revisions can be deleted.

    Example responses

    404 Response

    {
      "message": "string",
      "id": "string",
      "errorCode": 0,
      "httpStatusCode": 0,
      "details": [
        "string"
      ],
      "remediation": "string",
      "errors": [
        null
      ],
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0
    }
    
    Responses
    Status Meaning Description Schema
    204 No Content The global variable revision was deleted. None
    404 Not Found No global variable revision exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1/get/responses/404/content/application~1vnd.sas.api%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Schemas

    currentContentsPatch

    {
      "op": "string",
      "from": "string",
      "path": "string"
    }
    
    

    Current Contents Patch

    Properties
    Name Type Required Restrictions Description
    op string false none The operation to carry out.
    from string false none The source of the copy.
    path string false none The target of the copy.

    domainCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "codeName": "string",
          "formatName": "string",
          "packageName": "string",
          "domainType": "string",
          "description": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "createdBy": "string",
          "modifiedBy": "string",
          "folderType": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    

    Domain Collection

    Properties
    Name Type Required Restrictions Description
    Domain Collection any false none A collection of the domain representation.

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [link] false none The links that apply to the collection.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [domain] false none The actual results of a query.

    domain

    {
      "id": "string",
      "name": "string",
      "codeName": "string",
      "formatName": "string",
      "packageName": "string",
      "domainType": "string",
      "description": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "modifiedBy": "string",
      "folderType": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Domain

    Properties
    Name Type Required Restrictions Description
    id string false none The system-assigned unique ID for this object.
    name string false none The name of the domain.
    codeName string false none The system-assigned encoded version of the name that uses only certain characters from the English alphabet and the Arabic numerals.
    formatName string false none This is the name of a Cloud Analytic Service format when this domain is published to the Cloud Analytic Service.
    packageName string false none This is the name of a DS2 package when this domain is published to the Micro Analytic Score service.
    domainType string false none The type of the domain.
    description string false none The description about the domain.
    creationTimeStamp string(date-time) false none Timestamp when this domain is created. This field is a derived field and not required for PUT and POST.
    modifiedTimeStamp string(date-time) false none Timestamp when this domain is last modified. This field is a derived field and not required for PUT and POST.
    createdBy string false none ID of the user who created this domain. This field is a derived field and not required for PUT and POST.
    modifiedBy string false none ID of the user who last modified this domain. This field is a derived field and not required for PUT and POST.
    folderType string false none Indicates the type of folder where the domain is housed.
    links [object] false none Zero or more link objects.
    » Link object false none A link to a related operation or resource.
    »» method string false none The HTTP method for the link.
    »» rel string true none The relationship of the link to the resource.
    »» uri string false none The relative URI for the link.
    »» href string false none The URL for the link.
    »» title string false none The title for the link.
    »» type string false none The media type or link type for the link.
    »» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.

    domainContentCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "label": "string",
          "majorNumber": "string",
          "minorNumber": "string",
          "status": "string",
          "standing": "string",
          "activationStatus": "string",
          "activationError": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "createdBy": "string",
          "modifiedBy": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    

    Domain Current Collection

    Properties
    Name Type Required Restrictions Description
    Domain Current Collection any false none A collection of domain content representation.

    allOf

    Name Type Required Restrictions Description
    anonymous domainCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [domainContent] false none The actual results of a query.

    domainContent

    {
      "id": "string",
      "label": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "string",
      "standing": "string",
      "activationStatus": "string",
      "activationError": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "modifiedBy": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Domain Content

    Properties
    Name Type Required Restrictions Description
    id string false none The system-assigned unique ID for this object.
    label string false none A text string appropriate for this instance of the domain.
    majorNumber string false none The major version number.
    minorNumber string false none The minor version number.
    status string false none The status of this instance of the domain. The choices are "developing", "candidate", "activating" and "production". However, "activating" is only a system assignable value.
    standing string false none The system assigned value for this instance of the domain. The system assigned values are "inactive", "legacy", "current", or "future". This value compares one instance to another.
    activationStatus string false none Indicates whether the domain content is being activated, is activated, or has failed to be activated.
    activationError string false none When this field is present, the content has failed to be activated to one or more destination. This field carries error message for each of the failed destination.
    creationTimeStamp string(date-time) false none Timestamp when this domain is created. This field is a derived field and not required for PUT and POST.
    modifiedTimeStamp string(date-time) false none Timestamp when this domain is last modified. This field is a derived field and not required for PUT and POST.
    createdBy string false none ID of the user who created this domain. This field is a derived field and not required for PUT and POST.
    modifiedBy string false none ID of the user who last modified this domain. This field is a derived field and not required for PUT and POST.
    links [link] false none Zero or more link objects.

    domainCurrentContentsCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "domainId": "string",
          "versionId": "string",
          "status": "string",
          "commencedTimeStamp": "2019-08-24T14:15:22Z",
          "expiredTimeStamp": "2019-08-24T14:15:22Z",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    

    Domain Current Content Collection

    Properties
    Name Type Required Restrictions Description
    Domain Current Content Collection any false none A collection of the domain content history representation.

    allOf

    Name Type Required Restrictions Description
    anonymous domainCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [domainContentHistory] false none The actual results of a query.

    domainContentHistory

    {
      "id": "string",
      "domainId": "string",
      "versionId": "string",
      "status": "string",
      "commencedTimeStamp": "2019-08-24T14:15:22Z",
      "expiredTimeStamp": "2019-08-24T14:15:22Z",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Domain Content History

    Properties
    Name Type Required Restrictions Description
    id string false none The system-assigned unique ID for this object.
    domainId string false none The ID of the domain.
    versionId string false none The ID of the domain version.
    status string false none The status of this instance of the domain. The value is always production.
    commencedTimeStamp string(date-time) false none Timestamp when this domain's content status was current. This member is always specified. Format is in yyyy-MM-dd'T'HH:mm:ss.SSSZ. This field is a derived field.
    expiredTimeStamp string(date-time) false none Timestamp when this domain's content status was no longer current. This member is specified when the status expires. Format is in yyyy-MM-dd'T'HH:mm:ss.SSSZ. This field is a derived field.
    links [link] false none Zero or more link objects.

    domainEntryCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "key": "string",
          "value": "string"
        }
      ]
    }
    
    

    Domain Entry Collection

    Properties
    Name Type Required Restrictions Description
    Domain Entry Collection any false none A collection of the domain entry representation.

    allOf

    Name Type Required Restrictions Description
    anonymous domainCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [domainEntry] false none The actual results of a query.

    domainEntry

    {
      "key": "string",
      "value": "string"
    }
    
    

    Domain Entry

    Properties
    Name Type Required Restrictions Description
    key string false none key
    value string false none value

    entriesPatch

    {
      "op": "string",
      "path": "string",
      "value": "string"
    }
    
    

    JSON Patch Operation

    Properties
    Name Type Required Restrictions Description
    op string false none The operation that was performed.
    path string false none The path identifying the object or a member of an object.
    value string false none A string value or a JSON string representation of an object or array.

    globalVariableCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "description": "string",
          "defaultValue": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "dataType": "string",
          "majorNumber": "string",
          "minorNumber": "string",
          "status": "developing",
          "locked": true,
          "activeVersionId": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    

    Global Variable Collection

    Properties
    Name Type Required Restrictions Description
    Global Variable Collection any false none A collection of the global variables.

    allOf

    Name Type Required Restrictions Description
    anonymous domainCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [globalVariable] false none The actual results of a query.

    globalVariable

    {
      "id": "string",
      "name": "string",
      "description": "string",
      "defaultValue": "string",
      "createdBy": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "dataType": "string",
      "majorNumber": "string",
      "minorNumber": "string",
      "status": "developing",
      "locked": true,
      "activeVersionId": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Global Variable

    Properties
    Name Type Required Restrictions Description
    id string false none The system-assigned unique ID for this object.
    name string true none Name of the global variable.
    description string false none Description of the global variable
    defaultValue string true none The value of the global variable. Applicable to all decisions and rule sets where it is referenced. It can also be overridden in a decision or rule set.
    createdBy string false none The user who created the global variable. This attribute is only assignable by the system.
    creationTimeStamp string(date-time) false none The date and time that the global variable was created. This attribute is only assignable by the system.
    modifiedBy string false none The user ID of the authenticated user who last updated the global variable. This attribute is only assignable by the system.
    modifiedTimeStamp string(date-time) false none The date and time that the global variable was last modified. This attribute is only assignable by the system.
    dataType string(enumeration) true none The type of data that the global variable is intended to be used with.
    majorNumber string false none The major version number. This attribute is only assignable by the system.
    minorNumber string false none The minor version number. This attribute is only assignable by the system.
    status string false none The status of global variable. This attribute is only assignable by the system.
    locked boolean false none Flag that indicates whether the content of the revision being viewed is locked or editable. This attribute is only assignable by the system.
    activeVersionId string false none The system-assigned unique ID for the active version.
    links [link] false none Links to related resources or operations.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    dataType boolean
    status developing
    status production

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    Reference Data Media Types
    application/vnd.sas.data.reference.domain

    Provides reference data domain information.

    The schema is at domain.

    application/vnd.sas.data.reference.domain+json

    Here is an example of the JSON representation of this media type.

    
    {
      "version": 2,
      "id": "d773daf4-5b56-11e6-85bb-000743085641",
      "name": "serviceLevel",
      "codeName": "5ijfn4iqtbdlxd6c5uisstz6fi",
      "formatName": "$L5IJFN4IQTBDLXD6C5UISSTZ6FI_K",
      "packageName": "l5ijfn4iqtbdlxd6c5uisstz6fi",
      "type": "lookup",
      "description": "The service level designation.",
      "creationTimeStamp": "2016-02-24T22:21:52.881Z",
      "createdBy": "bob",
      "modifiedTimeStamp": "2016-02-24T22:21:52.881Z",
      "modifiedBy": "bob",
      "folderType": "myFolder",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641",
          "type": "application/vnd.sas.data.reference.domain"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641",
          "type": "application/vnd.sas.data.reference.doamin",
          "response": "application/vnd.sas.data.reference.domain"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641"
        },
        {
          "method": "GET",
          "rel": "getVersions",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.data.reference.domain.content"
        },
        {
          "method": "POST",
          "rel": "newContent",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents",
          "type": "application/vnd.sas.data.reference.domain.content"
        },
        {
          "method": "GET",
          "rel": "currentContents",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/currentContents",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/currentContents",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.data.reference.domain.content.history"
        },
        {
          "method": "GET",
          "rel": "currentContentsCompleteHistory",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/currentContents?scope=all",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/currentContents?scope=all",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.data.reference.domain.content.history"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/referenceData/domains",
          "uri": "/referenceData/domains",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.data.reference.domain"
        }
      ]
    }
    
    application/vnd.sas.data.reference.domain.content

    Provides reference data domain content information.

    The schema is at domainContent.

    application/vnd.sas.data.reference.domain.content+json

    Here is an example of the JSON representation of this media type.

    
    {
      "version": 2,
      "id": "cae18e16-5b7f-11e6-9e34-000743085641",
      "domainId": "d773daf4-5b56-11e6-85bb-000743085641",
      "label": "field-tested",
      "majorVersion": 1,
      "minorVersion": 5,
      "status": "production",
      "activationStatus": "active",
      "standing": "current",
      "creationTimeStamp": "2016-03-21T18:01:01.106Z",
      "createdBy": "bob",
      "modifiedTimeStamp": "2016-05-11T02:41:05.881Z",
      "modifiedBy": "bob",
      "sourceDomainRevisionUri": "/referenceData/domains/d773daf4-5b56-11e6-85b1-000743085641/contents/cae18e16-5b7f-11v6-9e34-000743085641",
      "copyTimeStamp": "2016-05-11T02:41:05.881Z",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641",
          "type": "application/vnd.sas.data.reference.domain.content"
        },
        {
          "method": "GET",
          "rel": "delete",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641"
        },
        {
          "method": "GET",
          "rel": "getEntries",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641/entries",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641/entries",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.data.reference.domain.entry"
        },
        {
          "method": "POST",
          "rel": "createEntries",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641/entries",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641/entries",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.data.reference.domain.entry"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.data.reference.domain.content"
        }
      ]
    }
    
    application/vnd.sas.data.reference.domain.content.history

    Provides reference data domain current content history information.

    The schema is at domainContentHistory.

    application/vnd.sas.data.reference.domain.content.history+json

    Here is an example of the JSON representation of this media type.

    
    {
      "version": 1,
      "domainId": "d773daf4-5b56-11e6-85bb-000743085641",
      "contentId": "cae18e16-5b7f-11e6-9e34-000743085641",
      "status": "production",
      "commencedTimeStamp": "2016-05-11T02:41:05.881Z",
      "expiredTimeStamp": "2016-09-01T15:21:49.688Z",
      "links": [
        {
          "method": "GET",
          "rel": "getContent",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641",
          "type": "application/vnd.sas.data.reference.domain.content"
        },
        {
          "method": "GET",
          "rel": "getEntries",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641/entries",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/contents/cae18e16-5b7f-11e6-9e34-000743085641/entries",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.data.reference.domain.entry"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/currentContents",
          "uri": "/referenceData/domains/d773daf4-5b56-11e6-85bb-000743085641/currentContents",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.data.reference.domain.content.history"
        }
      ]
    }
    
    application/vnd.sas.data.reference.domain.entry

    A domain entry value.

    The schema is at domainEntry.

    application/vnd.sas.data.reference.domain.entry+json

    Here is an example of the JSON representation of this media type.

    
    {
      "version": 1,
      "key": "severe",
      "value": "1 hour"
    }
    
    Externally Defined Media Types
    application/vnd.sas.collection

    A paginated, filterable, sortable collection of resource representations. For this API, this is a collection of application/vnd.sas.data.reference.domain, application/vnd.sas.data.reference.domain.content, application/vnd.sas.data.reference.domain.content.history or application/vnd.sas.data.reference.domain.entry representations.

    See application/vnd.sas.collection.

    application/vnd.sas.summary

    Used to represent a summary of a resource.

    See application/vnd.sas.summary.

    application/vnd.sas.error

    Used to represent an error response.

    See application/vnd.sas.error.

    Resource Relationships

    Resource relationship diagram

    Root

    Path: /

    The root of the API. This resource contains links to the top-level resources in the API.

    The GET / response include the following links.

    Relation Method Description
    domains GET Returns the first page of the collection of the reference data domains.
    Response type: application/vnd.sas.collection
    createDomain POST Creates a new reference data domain.
    Request type: application/vnd.sas.data.reference.domain
    Response type: application/vnd.sas.data.reference.domain
    bulkExport GET Returns all of the entries in the latest content of all the reference data domains.
    Response type: [text/csv]
    bulkImport POST Imports entries into the latest content of one or more of the reference data domains. Creates the domains if needed.
    Request type: [text/csv]
    Response type: [multipart/mixed]
    Domains

    Path: /domains

    Provides a collection of reference data domains.

    Default page size is 10.

    The domains collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.data.reference.domain resources. (These types apply to the response for the self, collection, prev, next, first and last links below.)

    The GET /domains response includes the following links.

    Relation Method Description
    createDomain POST Creates a new reference data domain.
    This link is available only when the requester has authorization to create a new reference data domain.
    Request type: application/vnd.sas.data.reference.domain
    Response type: application/vnd.sas.data.reference.domain
    self GET Returns the current page of the collection.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Return the parent resource, which is the root of this API.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the domains collection is by ascending creationTimeStamp.

    Filtering and sorting can use the following members of a domain:

    Filter by name - ?filter=eq(name, 'district-name')

    Filter by multiple names - ?filter=in(name, 'district-southeast', 'district-northeast')

    Filter by time value - ?filter=gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combine filters - ?filter=and(gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    Domain

    Path: /domains/{domainId}

    Provides the reference data domain.

    The GET /domains/{domainId} response includes the following links.

    Relation Method Description
    self GET Returns the full representation of the domain.
    alternate GET Returns the summary representation of the domain.
    Response type: application/vnd.sas.summary
    delete DELETE Deletes this domain.
    createContent POST Creates new domain content.
    Request type: application/vnd.sas.data.reference.domain.content
    Response type: application/vnd.sas.data.reference.domain.content
    getContents GET Returns the collection of contents in this domain.
    currentContents GET Returns the current content collection using a predefined filter.
    currentContentsCompleteHistory GET Returns the first page of the current content collection.
    up GET Returns the parent resource, which is a domain.
    Domain Contents

    Path: /domains/{domainId}/contents

    Provides a collection of reference data domain content.

    Default page size is 10.

    The domain contents collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.data.reference.domain.content resources. (These types apply to the response for the self, collection, prev, next, first and last links below.)

    The GET /domains/{domainId}/contents response includes the following links.

    Relation Method Description
    createContent POST Creates a new reference data content.
    This link is available only when the requester has authorization to create new reference data content.
    Request type: application/vnd.sas.data.reference.domain.content
    Response type: application/vnd.sas.data.reference.domain.content
    self GET Returns the current page of the collection.
    collection GET Returns the first page of the collection without the sorting or filtering criteria.
    prev GET Return the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Return the parent resource, which is the domain.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the domain contents collection is by ascending creationTimeStamp.

    Filtering and sorting can use the following members of a domainContent:

    Filter by name - ?filter=eq(name, 'district-name')

    Filter by multiple names - ?filter=in(name, 'district-southeast', 'district-northeast')

    Filter by time value - ?filter=gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combine filters - ?filter=and(gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    Domain Content

    Path: /domains/{domainId}/contents/{contentId}

    Provides reference data domain content.

    The GET /domains/{domainId}/contents/{contentId} response includes the following links.

    Relation Method Description
    self GET Returns the full representation of the content.
    Response type: application/vnd.sas.data.reference.domain.content
    delete DELETE Deletes the content.
    createEntries POST Creates new entries in the content.
    Request type: application/vnd.sas.data.reference.domain.entry
    Response type: application/vnd.sas.data.reference.domain.entry
    deleteEntries DELETE Deletes all the entries in the content.
    getEntries GET Returns the collection of entries in this content.
    up GET Returns the parent resource, which is the collection of contents of the domain.
    Current Content History

    Path: /domains/{domainId}/currentContents

    Provides a collection of the reference data domain content history.

    Default page size is 10.

    Members of the /domains/{domainId}/currentContents collection are not individually accessible via identifiers.

    The currentContents collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.data.reference.domain.content.history resources. (These types apply to the response for the self, collection, prev, next, first and last links below.)

    The GET /domains/{domainId}/currentContents response includes the following links.

    Relation Method Description
    self GET Returns the current page of the collection.
    collection GET Returns the first page of the collection without the sorting or filtering criteria.
    copyCurrentContent PATCH A link to copy the current content to an execution environment.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Returns the parent resource, which is the domain.
    Sorting and Filtering

    These collections can be sorted using the ?sortBy= query parameter. The default sort order for the currentContents collection is by ascending commencedTimeStamp.

    Sorting can use the following subset of members of a domainContentHistory:

    These collections can be filtered using the scope query parameter. Each scope value is a shorthand for a frequently used filter that is implemented using the ?filter= query parameter. The default value for scope is "current".

    Filtering can use the following subset of members of a domainContentHistory:

    Filter by scope - ?scope=current (equivalent filter expression: filter=and(eq(domainId, 'domainId'),isNull(expiredTimeStamp)))

    Filter by scope - ?scope=all (equivalent filter expression:filter=eq(domainId, 'domainId'))`

    Filter by scope and commencedTimeStamp range - ?scope=all&filter=and(gt(commencedTimeStamp, '2017-01-27T03%3A03%3A00Z' ), lt(commencedTimeStamp, '2017-09-27T23%3A59%3A59Z'))

    Filter by asOf - ?asOf='2017-01-27T03%3A03%3A00Z'

    Current Content

    This resource is a member of the reference data domain current content history collection. This resource is not individually accessible via an identifier. The resource provides the following links.

    Relation Method Description
    getContent GET Returns the domain content representation.
    getEntries GET Returns the entries of the domain content.
    up GET Returns the parent resource, which is the current contents history collection.
    Domain Entries

    Path: /domains/{domainId}/contents/{contentId}/entries

    Provides a collection of reference data domain entries.

    Default page size is 10.

    Members of the /domains/{domainId}/contents/{contentId}/entries collection are not individually accessible via identifiers.

    The entries collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.data.reference.domain.entry resources. (These types apply to the response for the self, collection, prev, next, first and last links below.)

    The GET /domains/{domainId}/contents/{contentId}/entries response includes the following links.

    Relation Method Description
    replaceEntries POST Replaces all the entries in a domain content.
    deleteEntries DELETE Deletes all the entries in a domain content.
    patchEntries PATCH Adds entries to, delete entries from, or replaces entry values of a domain content.
    self GET Returns the current page from the collection.
    collection GET Returns the first page of the collection without the sorting or filtering criteria.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Returns the parent resource, which is the domain content.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the domain entries collection is by ascending key.

    Filtering and sorting can use the following members of the domainEntry:

    Filter by key - ?filter=contains(key, 'level')

    Filter by multiple keys - ?filter=in(name, 'preferredlevel', 'viplevel')

    Combine filters - ?filter=and(contains(key, 'level'), contains(value, 'drawing')

    Domain Entry

    This resource is a member of the reference data domain entries collection. This resource is not individually accessible via an identifier and does not provide links to other resources.

    Decisions

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers License: SAS Institute

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Decisions API supports the life cycle of decision data.

    Usage Notes

    Overview

    The Decisions API enables users to build and retrieve a decision flow by linking statistical models in combination with deterministic logic from business rules for the purpose of integrating them into an operational process.

    This API provides the following features:

    The models, rules sets, treatment groups, branches, and conditions are linked together via a common term list. After a decision flow is constructed, the Model Publish API can be used to publish the decision flows code to the SAS Micro Analytic Service for transactional web service execution, or to CAS destinations for batch processes.

    Example processes that can be authored with the Decisions API would be loan approval, promotion offering, inventory purchasing, sales attribution, and many more.

    Here is an example of a Credit Approval Decision for a small regional bank:

    Why Use this API?

    This API enables users to build and retrieve decision-making processes that can be published to transactional or batch targets.

    Terminology

    decision flow

    a sequential collection of Rule Set steps, Model steps, Custom steps, Record Contacts steps, Branch steps, and Condition steps that encapsulate an automated decision making process. A decision has a signature (term list) that is associated with it and that all step objects must map to.

    decision revision

    a set of user created revisions that represent stabilized decision logic at various important milestones. All revisions are immutable except for the latest revision.

    step

    represents decision logic that is included within the decision flow. In a decision flow a step can either be a Rule Set step, a Model step, a Custom step, a Branch step, or a Condition step.

    rule set

    an ordered set of rule logic with actions that are managed within the Business Rules API. Rule sets are used to make deterministic decisions to indicate statuses such as 'approved' or 'declined'.

    model

    a statistical or analytical model managed within the Model Repository API. A model is a formula or algorithm that computes outputs from inputs. In most cases a model produces probabilities as output (for example, .45234399 , .9238485).

    custom object

    an object that can provide the code and signature of the code that can be added as a step within a decision. The types of custom steps that can be used by default with the decision are treatment groups and code files.

    rule set step

    a type of step that encapsulates a rule set.

    model step

    a type of step that encapsulates a model.

    custom step

    a type of step that encapsulates a custom object.

    condition step

    a type of step that contains a simple expression, which consists of a term, an operator, and either a constant or another term (for example, term = 1000 or term > term2). Condition steps evaluate to true or false, and execute a single flow associated with either path. If the user wants to perform more complex conditioning, they should use a rule set to do the complex conditioning, and then produce a simple term that can be easily conditioned.

    mappings

    a mapping between inputs or outputs of a rule set, or a model and terms of the decision signature (term list). Inputs and outputs for the rule set or model are called step terms, and the term in the decision flow signature to which step term is mapped is called the target decision term.

    signature

    a decision flow signature contains a valid set of unique terms that can be mapped to real data columns.

    term

    a business user-defined name of a column of data, or a field generated within the decision steps. For example, terms might be defined for name, address, income, date, time, transaction amount, and account number.

    code file

    a wrapper for a file resource that contains the signature of the code.

    code file revision

    a set of revisions created by a user that represent stabilized code at various important milestones. All revisions are immutable except for the latest revision.

    external artifact

    an object used by a decision that is not a condition, a branch, a rule set, a model, or a code file. An example is an analytic store file.

    record contacts step

    a step that can be added to a decision that records subject contact history information and generates response tracking codes.

    treatment

    an offer that is returned by a decision and can be sent to a subject.

    channel

    a value that contains a business defined code that represents where logically the request is coming from. The value is determined by the run-time value of the specified term within the record contact node.

    data grid

    a decision term type, which represents a multi-row table with named columns.

    branch step

    a decision step that allows for "case statements" to directly flow within a decision. A branch step contains a list of branch cases and a default case. During the execution of a branch step, each case is evaluated in order. The decision flow follows the first branch case whose condition evaluates as true. If no branchCase conditions evaluate as true, the branch step's default case path is followed.

    link step

    a decision step that results in the creation of a link between the proceeding step and another arbitrary step in another branch case or completely outside the current branch step.

    decision node type

    a node type that enables users to extend the decision flow by specifying crucial information needed by both the client and the middle-tier for handling the new node type.

    decision node type content

    a node type content that specifies information about the code that is executed when the decision node type is included within a decision flow.

    Operations

    Root

    Contains the operations for the root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/decisions/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/decisions/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns a list of top-level resource links for this API.

    Example responses

    Decisions root content.

    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "decisions",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision"
        },
        {
          "method": "POST",
          "rel": "createDecision",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "codeFiles",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.code.file"
        },
        {
          "method": "POST",
          "rel": "createCodeFile",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "decisionNodeTypes",
          "href": "/decisions/decisionNodeTypes",
          "uri": "/decisions/decisionNodeTypes",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.node.type"
        },
        {
          "method": "POST",
          "rel": "createDecisionNodeType",
          "href": "/decisions/decisionNodeTypes",
          "uri": "/decisions/decisionNodeTypes",
          "type": "application/vnd.sas.decision.node.type",
          "responseType": "application/vnd.sas.decision.node.type"
        }
      ]
    }
    
    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "decisions",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision"
        },
        {
          "method": "POST",
          "rel": "createDecision",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "codeFiles",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.code.file"
        },
        {
          "method": "POST",
          "rel": "createCodeFile",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "decisionNodeTypes",
          "href": "/decisions/decisionNodeTypes",
          "uri": "/decisions/decisionNodeTypes",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.node.type"
        },
        {
          "method": "POST",
          "rel": "createDecisionNodeType",
          "href": "/decisions/decisionNodeTypes",
          "uri": "/decisions/decisionNodeTypes",
          "type": "application/vnd.sas.decision.node.type",
          "responseType": "application/vnd.sas.decision.node.type"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. A collection of link objects was returned. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] true none The API's top-level links.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Decisions

    Contains the operations to create, read, update and delete decisions.

    Get a list of all decisions

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.decision+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.decision+json'
    };
    
    fetch('https://example.com/decisions/flows',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.decision+json'
    }
    
    r = requests.get('https://example.com/decisions/flows', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.decision+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows

    Returns a resource collection of all decisions.

    Parameters
    Name In Type Required Description
    filter query string(filter-criteria) false The criteria for filtering the decision flows. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the decision flows. See Sorting in REST APIs.
    start query integer false The starting index of the first item in a page. The index is 0-based.
    limit query integer false The maximum number of items to return in this page of results. The actual number of returned items might be less if the collection has been exhausted.
    Accept-Item header string(media-type) false Used for selecting desired item representation.
    stepObjectUri query string false If provided, only decisions that contain a step object matching this
    Detailed descriptions

    stepObjectUri: If provided, only decisions that contain a step object matching this URI are returned. The supported step types to search for are model steps, rule set steps, or custom object steps. For models and rule sets, the URI should include only the object's ID (no revision). For custom objects, any decisions with a custom object step referencing an object whose URI starts with the provided value is returned.

    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.decision+json
    Accept-Item application/vnd.sas.summary+json

    Example responses

    Decision flows with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows?sortBy=name&start=2&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/flows?sortBy=name&start=0&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/flows?sortBy=name&start=1&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/flows?sortBy=name&start=3&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "createDecision",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "name": "decisions",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T16:06:56.319Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "decision",
          "name": "add_dec",
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.summary"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Decision flows with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/flows?sortBy=name&start=0&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/flows?sortBy=name&start=1&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/flows?sortBy=name&start=3&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows?sortBy=name&start=2&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "createDecision",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "name": "decisions",
      "accept": "application/vnd.sas.decision",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T16:06:56.319Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "name": "add_dec",
          "majorRevision": 1,
          "minorRevision": 5,
          "signature": [
            {
              "creationTimeStamp": "2021-05-07T16:04:52.928Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
              "direction": "input",
              "name": "a",
              "dataType": "decimal"
            },
            {
              "creationTimeStamp": "2021-05-07T16:04:52.929Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
              "direction": "input",
              "name": "b",
              "dataType": "decimal"
            },
            {
              "creationTimeStamp": "2021-05-07T16:04:52.929Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
              "direction": "output",
              "name": "c",
              "dataType": "decimal"
            }
          ],
          "flow": {
            "creationTimeStamp": "2021-05-07T16:06:56.326Z",
            "modifiedTimeStamp": "2021-05-07T16:06:56.326Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "0b77ae9e-dcc7-4c7f-91c4-e725cd30092e",
            "steps": [
              {
                "type": "application/vnd.sas.decision.step.custom.object",
                "creationTimeStamp": "2021-05-07T16:06:56.328Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.328Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "5da31100-8063-4dae-8b6d-dbc5965328d9",
                "publishedModule": {},
                "customObject": {
                  "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                  "name": "add_cf",
                  "type": "decisionDS2CodeFile"
                },
                "mappings": [
                  {
                    "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "6bdfc780-9183-4fce-bddf-74fa0be6edae",
                    "targetDecisionTermName": "a",
                    "direction": "input",
                    "stepTermName": "a"
                  },
                  {
                    "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "8fa3a412-ed91-4560-8b9a-8311a9daab32",
                    "targetDecisionTermName": "b",
                    "direction": "input",
                    "stepTermName": "b"
                  },
                  {
                    "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "c965a73c-97d6-4d5f-a2c4-dbf54c690144",
                    "targetDecisionTermName": "c",
                    "direction": "output",
                    "stepTermName": "c"
                  }
                ],
                "links": [
                  {
                    "method": "GET",
                    "rel": "customObjectCode",
                    "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                    "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                    "responseType": "application/vnd.sas.decision.step.code"
                  }
                ]
              }
            ]
          },
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision"
            },
            {
              "method": "GET",
              "rel": "currentRevision",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "GET",
              "rel": "code",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
              "type": "text/vnd.sas.source.ds2"
            },
            {
              "method": "POST",
              "rel": "mappedCode",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
              "type": "application/vnd.sas.score.code.generation.request",
              "responseType": "application/vnd.sas.score.mapped.code"
            },
            {
              "method": "GET",
              "rel": "externalArtifacts",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.external.artifact"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision",
              "responseType": "application/vnd.sas.decision"
            }
          ],
          "nodeCount": 1,
          "folderType": "userFolder",
          "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
          "copyTimeStamp": "2021-05-07T16:06:56.319Z",
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Decision flows with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows?sortBy=name&start=2&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/flows?sortBy=name&start=0&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/flows?sortBy=name&start=1&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/flows?sortBy=name&start=3&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "createDecision",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "name": "decisions",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T16:06:56.319Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "decision",
          "name": "add_dec",
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.summary"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Decision flows with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/flows?sortBy=name&start=0&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/flows?sortBy=name&start=1&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/flows?sortBy=name&start=3&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows?sortBy=name&start=2&limit=1",
          "uri": "/decisions/flows?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "createDecision",
          "href": "/decisions/flows",
          "uri": "/decisions/flows",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "name": "decisions",
      "accept": "application/vnd.sas.decision",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T16:06:56.319Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "name": "add_dec",
          "majorRevision": 1,
          "minorRevision": 5,
          "signature": [
            {
              "creationTimeStamp": "2021-05-07T16:04:52.928Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
              "direction": "input",
              "name": "a",
              "dataType": "decimal"
            },
            {
              "creationTimeStamp": "2021-05-07T16:04:52.929Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
              "direction": "input",
              "name": "b",
              "dataType": "decimal"
            },
            {
              "creationTimeStamp": "2021-05-07T16:04:52.929Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
              "direction": "output",
              "name": "c",
              "dataType": "decimal"
            }
          ],
          "flow": {
            "creationTimeStamp": "2021-05-07T16:06:56.326Z",
            "modifiedTimeStamp": "2021-05-07T16:06:56.326Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "0b77ae9e-dcc7-4c7f-91c4-e725cd30092e",
            "steps": [
              {
                "type": "application/vnd.sas.decision.step.custom.object",
                "creationTimeStamp": "2021-05-07T16:06:56.328Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.328Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "5da31100-8063-4dae-8b6d-dbc5965328d9",
                "publishedModule": {},
                "customObject": {
                  "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                  "name": "add_cf",
                  "type": "decisionDS2CodeFile"
                },
                "mappings": [
                  {
                    "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "6bdfc780-9183-4fce-bddf-74fa0be6edae",
                    "targetDecisionTermName": "a",
                    "direction": "input",
                    "stepTermName": "a"
                  },
                  {
                    "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "8fa3a412-ed91-4560-8b9a-8311a9daab32",
                    "targetDecisionTermName": "b",
                    "direction": "input",
                    "stepTermName": "b"
                  },
                  {
                    "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "c965a73c-97d6-4d5f-a2c4-dbf54c690144",
                    "targetDecisionTermName": "c",
                    "direction": "output",
                    "stepTermName": "c"
                  }
                ],
                "links": [
                  {
                    "method": "GET",
                    "rel": "customObjectCode",
                    "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                    "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                    "responseType": "application/vnd.sas.decision.step.code"
                  }
                ]
              }
            ]
          },
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision"
            },
            {
              "method": "GET",
              "rel": "currentRevision",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "GET",
              "rel": "code",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
              "type": "text/vnd.sas.source.ds2"
            },
            {
              "method": "POST",
              "rel": "mappedCode",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
              "type": "application/vnd.sas.score.code.generation.request",
              "responseType": "application/vnd.sas.score.mapped.code"
            },
            {
              "method": "GET",
              "rel": "externalArtifacts",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.external.artifact"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision",
              "responseType": "application/vnd.sas.decision"
            }
          ],
          "nodeCount": 1,
          "folderType": "userFolder",
          "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
          "copyTimeStamp": "2021-05-07T16:06:56.319Z",
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not acceptable.

    {
      "httpStatusCode": 406,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    406 Not Acceptable The request was not acceptable. An invalid media type was specified for the Accept-Item header value. Inline
    Response Schema
    Enumerated Values
    Property Value
    type application/vnd.sas.decision.step.ruleset
    direction input
    direction output
    direction inOut
    type application/vnd.sas.decision.step.model
    type application/vnd.sas.decision.step.custom.object
    type application/vnd.sas.decision.step.record.contact
    type application/vnd.sas.decision.step.node.link
    type application/vnd.sas.decision.step.condition
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    dataType dataGrid
    direction input
    direction output
    direction inOut
    direction none
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    type application/vnd.sas.decision.step.branch
    booleanOperator AND
    booleanOperator OR

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 406

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    406 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a decision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision+json' \
      -H 'Accept: application/vnd.sas.decision+json'
    
    
    const inputBody = '{
      "name": "My Decision With Code File",
      "signature": [
        {
          "direction": "input",
          "name": "my_input",
          "dataType": "decimal"
        },
        {
          "direction": "output",
          "name": "my_output",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "customObject": {
              "uri": "/decisions/codeFiles/34e54af1-c371-40b7-a186-7a3fcef7d033/revisions/b8fbb2d2-4046-423b-95e1-f9711b3ad26a",
              "name": "My DS2 Code File",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "targetDecisionTermName": "my_input",
                "direction": "input",
                "stepTermName": "my_input"
              },
              {
                "targetDecisionTermName": "my_output",
                "direction": "output",
                "stepTermName": "my_output"
              }
            ]
          }
        ]
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision+json',
      'Accept':'application/vnd.sas.decision+json'
    };
    
    fetch('https://example.com/decisions/flows',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision+json',
      'Accept': 'application/vnd.sas.decision+json'
    }
    
    r = requests.post('https://example.com/decisions/flows', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision+json"},
            "Accept": []string{"application/vnd.sas.decision+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows

    Creates a new decision based on the provided content.

    Body parameter

    Decision flow.

    {
      "name": "My Decision With Code File",
      "signature": [
        {
          "direction": "input",
          "name": "my_input",
          "dataType": "decimal"
        },
        {
          "direction": "output",
          "name": "my_output",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "customObject": {
              "uri": "/decisions/codeFiles/34e54af1-c371-40b7-a186-7a3fcef7d033/revisions/b8fbb2d2-4046-423b-95e1-f9711b3ad26a",
              "name": "My DS2 Code File",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "targetDecisionTermName": "my_input",
                "direction": "input",
                "stepTermName": "my_input"
              },
              {
                "targetDecisionTermName": "my_output",
                "direction": "output",
                "stepTermName": "my_output"
              }
            ]
          }
        ]
      }
    }
    
    Parameters
    Name In Type Required Description
    parentFolderUri query string(/folders/folders/{parentFolderId}) false Folder in which the new decision is placed.
    fromRevisionUri query string(/decisions/flows/{decisionId}/revisions/{revisionId}) false This value specifies the URI of the decision revision from which the new decision is being created. This property enables you to trace the lineage of a decision.
    body body decision true Decision summary to create a decision.

    Example responses

    Decision flow with full details.

    {
      "creationTimeStamp": "2021-05-07T16:06:56.319Z",
      "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 5,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:56.326Z",
        "modifiedTimeStamp": "2021-05-07T16:06:56.326Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "0b77ae9e-dcc7-4c7f-91c4-e725cd30092e",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:56.328Z",
            "modifiedTimeStamp": "2021-05-07T16:06:56.328Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "5da31100-8063-4dae-8b6d-dbc5965328d9",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6bdfc780-9183-4fce-bddf-74fa0be6edae",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "8fa3a412-ed91-4560-8b9a-8311a9daab32",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "c965a73c-97d6-4d5f-a2c4-dbf54c690144",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "currentRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:56.319Z",
      "version": 2
    }
    
    {
      "creationTimeStamp": "2021-05-07T16:06:56.319Z",
      "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 5,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:56.326Z",
        "modifiedTimeStamp": "2021-05-07T16:06:56.326Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "0b77ae9e-dcc7-4c7f-91c4-e725cd30092e",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:56.328Z",
            "modifiedTimeStamp": "2021-05-07T16:06:56.328Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "5da31100-8063-4dae-8b6d-dbc5965328d9",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6bdfc780-9183-4fce-bddf-74fa0be6edae",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "8fa3a412-ed91-4560-8b9a-8311a9daab32",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "c965a73c-97d6-4d5f-a2c4-dbf54c690144",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "currentRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:56.319Z",
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The decision was created. decision
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Last-Modified string No description
    201 Location string No description
    201 ETag string The entity tag for the decision flow.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get decision content

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows/{decisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision+json'
    }
    
    r = requests.get('https://example.com/decisions/flows/{decisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows/{decisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows/{decisionId}

    Retrieves the contents of a decision.

    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.

    Example responses

    Decision flow with full details.

    {
      "creationTimeStamp": "2021-05-07T16:06:56.319Z",
      "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 5,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:56.326Z",
        "modifiedTimeStamp": "2021-05-07T16:06:56.326Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "0b77ae9e-dcc7-4c7f-91c4-e725cd30092e",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:56.328Z",
            "modifiedTimeStamp": "2021-05-07T16:06:56.328Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "5da31100-8063-4dae-8b6d-dbc5965328d9",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6bdfc780-9183-4fce-bddf-74fa0be6edae",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "8fa3a412-ed91-4560-8b9a-8311a9daab32",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "c965a73c-97d6-4d5f-a2c4-dbf54c690144",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "currentRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:56.319Z",
      "version": 2
    }
    

    Decisin flow with resource summary details.

    {
      "creationTimeStamp": "2021-05-07T16:06:56.319Z",
      "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "type": "decision",
      "name": "add_dec",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.summary"
        }
      ],
      "version": 2
    }
    

    Decision flow with full details.

    {
      "creationTimeStamp": "2021-05-07T16:06:56.319Z",
      "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 5,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:56.326Z",
        "modifiedTimeStamp": "2021-05-07T16:06:56.326Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "0b77ae9e-dcc7-4c7f-91c4-e725cd30092e",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:56.328Z",
            "modifiedTimeStamp": "2021-05-07T16:06:56.328Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "5da31100-8063-4dae-8b6d-dbc5965328d9",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6bdfc780-9183-4fce-bddf-74fa0be6edae",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "8fa3a412-ed91-4560-8b9a-8311a9daab32",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "c965a73c-97d6-4d5f-a2c4-dbf54c690144",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "currentRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:56.319Z",
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. decision
    404 Not Found No decision exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description
    200 ETag string The entity tag for the decision flow.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Update a decision

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/decisions/flows/{decisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision+json' \
      -H 'Accept: application/vnd.sas.decision+json' \
      -H 'If-Match: "kknyjgku"'
    
    
    const inputBody = '{
      "name": "My Decision With Code File",
      "signature": [
        {
          "direction": "input",
          "name": "my_input",
          "dataType": "decimal"
        },
        {
          "direction": "output",
          "name": "my_output",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "customObject": {
              "uri": "/decisions/codeFiles/34e54af1-c371-40b7-a186-7a3fcef7d033/revisions/b8fbb2d2-4046-423b-95e1-f9711b3ad26a",
              "name": "My DS2 Code File",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "targetDecisionTermName": "my_input",
                "direction": "input",
                "stepTermName": "my_input"
              },
              {
                "targetDecisionTermName": "my_output",
                "direction": "output",
                "stepTermName": "my_output"
              }
            ]
          }
        ]
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision+json',
      'Accept':'application/vnd.sas.decision+json',
      'If-Match':'"kknyjgku"'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision+json',
      'Accept': 'application/vnd.sas.decision+json',
      'If-Match': '"kknyjgku"'
    }
    
    r = requests.put('https://example.com/decisions/flows/{decisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision+json"},
            "Accept": []string{"application/vnd.sas.decision+json"},
            "If-Match": []string{""kknyjgku""},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/decisions/flows/{decisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /flows/{decisionId}

    Updates the decision.

    Body parameter

    Decision flow.

    {
      "name": "My Decision With Code File",
      "signature": [
        {
          "direction": "input",
          "name": "my_input",
          "dataType": "decimal"
        },
        {
          "direction": "output",
          "name": "my_output",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "customObject": {
              "uri": "/decisions/codeFiles/34e54af1-c371-40b7-a186-7a3fcef7d033/revisions/b8fbb2d2-4046-423b-95e1-f9711b3ad26a",
              "name": "My DS2 Code File",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "targetDecisionTermName": "my_input",
                "direction": "input",
                "stepTermName": "my_input"
              },
              {
                "targetDecisionTermName": "my_output",
                "direction": "output",
                "stepTermName": "my_output"
              }
            ]
          }
        ]
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    If-Match header string true Etag value from when the originating object was retrieved.
    body body decision true Decision content to use in update

    Example responses

    Decision flow with full details.

    {
      "creationTimeStamp": "2021-05-07T16:06:56.319Z",
      "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 5,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:56.326Z",
        "modifiedTimeStamp": "2021-05-07T16:06:56.326Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "0b77ae9e-dcc7-4c7f-91c4-e725cd30092e",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:56.328Z",
            "modifiedTimeStamp": "2021-05-07T16:06:56.328Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "5da31100-8063-4dae-8b6d-dbc5965328d9",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6bdfc780-9183-4fce-bddf-74fa0be6edae",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "8fa3a412-ed91-4560-8b9a-8311a9daab32",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "c965a73c-97d6-4d5f-a2c4-dbf54c690144",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "currentRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:56.319Z",
      "version": 2
    }
    
    {
      "creationTimeStamp": "2021-05-07T16:06:56.319Z",
      "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 5,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:56.326Z",
        "modifiedTimeStamp": "2021-05-07T16:06:56.326Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "0b77ae9e-dcc7-4c7f-91c4-e725cd30092e",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:56.328Z",
            "modifiedTimeStamp": "2021-05-07T16:06:56.328Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "5da31100-8063-4dae-8b6d-dbc5965328d9",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6bdfc780-9183-4fce-bddf-74fa0be6edae",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "8fa3a412-ed91-4560-8b9a-8311a9daab32",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:56.329Z",
                "modifiedTimeStamp": "2021-05-07T16:06:56.329Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "c965a73c-97d6-4d5f-a2c4-dbf54c690144",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "currentRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:56.319Z",
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. decision
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No decision exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description
    200 ETag string The entity tag for the decision flow.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    412 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    428 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a decision

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/decisions/flows/{decisionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/decisions/flows/{decisionId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/decisions/flows/{decisionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/decisions/flows/{decisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /flows/{decisionId}

    Deletes the specified decision.

    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    Responses
    Status Meaning Description Schema
    204 No Content The decision was deleted. None
    Response Headers
    Status Header Type Format Description
    204 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get decision code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows/{decisionId}/code \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    
    const headers = {
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/code',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.get('https://example.com/decisions/flows/{decisionId}/code', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows/{decisionId}/code", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows/{decisionId}/code

    Retrieves the DS2 package code, which can then be used to execute the decision.

    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    codeTarget query string false The type of platform or scenario that the generated code is used in. If the generated DS2 is going to be run in the SAS Micro Analytic Service, "microAnalyticService" should be chosen. If the code is included as part of another decision, and therefore should not be wrapped in a driver, "subDecision" should be chosen. In all other cases, "others" should be chosen.
    Detailed descriptions

    codeTarget: The type of platform or scenario that the generated code is used in. If the generated DS2 is going to be run in the SAS Micro Analytic Service, "microAnalyticService" should be chosen. If the code is included as part of another decision, and therefore should not be wrapped in a driver, "subDecision" should be chosen. In all other cases, "others" should be chosen.

    Enumerated Values
    Parameter Value
    codeTarget microAnalyticService
    codeTarget others
    codeTarget subDecision

    Example responses

    Code generated from decision flow.

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    404 Not Found No decision code exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the mapped code for a decision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows/{decisionId}/mappedCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "scoreDefinitionId": "2d7d079d-963f-4c5e-a920-262accd4eb9e",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/mappedCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/decisions/flows/{decisionId}/mappedCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows/{decisionId}/mappedCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows/{decisionId}/mappedCode

    Returns the code that is used to run the decision based on the provided data and mapping information in the request.

    Body parameter

    Score code generation request.

    {
      "scoreDefinitionId": "2d7d079d-963f-4c5e-a920-262accd4eb9e",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    body body #/paths/~1flows~1%7BdecisionId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request%2Bjson/schema false none

    Example responses

    Generated mapped code for decision flow.

    {
      "code": "\nds2_options scond=none;\n/* Custom Object add_cf retrieved on Fri May 07 16:53:12 UTC 2021 */\n/*{\"signatureExtension\":[]}*/\npackage \"add_dec_add_cf\" ;\n   method execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n    ds2_options scond=none;\n\n/* Decision add_dec version 1.5 generated on Fri May 07 16:53:12 UTC 2021 */\n  package Decision_ba7b8073_83f7_41ae_827 ;\n    dcl package logger logr_perf('App.tk.SID.Perf');\n    dcl double timer_start;\n    dcl double elapsed_time;\n    dcl double total_timer_start;\n    dcl double total_elapsed_time;\n\n    dcl package \"add_dec_add_cf\" \"add_dec_add_cf_hdl\"();\n\n    method initRuleFiredRecording();\n           dcl integer ruleFiredStartPosition;\n\n            /* query and set offsets - always traverse in same order as execute() method */\n            ruleFiredStartPosition = 1;\n    end;\n\n     method init();\n        initRuleFiredRecording();\n     end;\n\n    method execute (\n       double \"a\"\n      ,double \"b\"\n      ,in_out double \"c\"\n      ,in_out varchar \"PathID\"\n      ,in_out char \"ruleFiredFlags\"\n      ,in_out integer \"rulesFiredForRecordCount\"\n      ,in_out integer \"_filter_\"\n\n    );\n        dcl integer dg_filter_;\n\n        total_timer_start = datetime();\n\n        timer_start = datetime();\n        \"add_dec_add_cf_hdl\".execute(\"a\", \"b\", \"c\");\n        elapsed_time = datetime() - timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, Node Name: add_cf, Node ID: 5da31100-8063-4dae-8b6d-dbc5965328d9, NODE DURATION: ' .. elapsed_time);\n        if (\"_filter_\" = 0) then return;\n\n        \"PathID\" = \"PathID\" || '/' || '5da31100-8063-4dae-8b6d-dbc5965328d9';\n\n        \"end\":/*label for decision node link to flow end*/\n\n        total_elapsed_time = datetime() - total_timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, TOTAL DURATION: ' .. total_elapsed_time);\n\n     end;\n    endpackage;\n    ds2_options scond=none;\n  thread decisionFlowThread ;\n     dcl package Decision_ba7b8073_83f7_41ae_827 decisionPackage();\n     dcl varchar(38) \"PathID\";\n     dcl char(1) \"ruleFiredFlags\";\n     dcl integer       \"rulesFiredForRecordCount\" having label 'Rules Fired Count';\n     dcl char(36)      \"_recordCorrelationKey\";\n\n     dcl integer \"_filter_\";\n     /* declare input terms not read in from SET statement */\n\n     /* declare output terms not read in from SET statement */\n     dcl double \"c\";\n\n     /*declare static terms */\ndcl double \"b\";\ndcl double \"a\";\n\n  keep\n\n  \"PathID\" \"ruleFiredFlags\" \"rulesFiredForRecordCount\" \"_recordCorrelationKey\"\n  \"c\"\n    ;\n\n    method resetruleFiredCounts( in_out char \"ruleFiredFlags\", in_out integer \"rulesfiredforrecordcount\");\n        \"rulesfiredforrecordcount\"=0;\n    end;\n\n    method init();\n      decisionPackage.initRuleFiredRecording();\n    end;\n\n     method run();\n        dcl integer localRC;\n\n       set \"Public\".\"DUAL\"(\n          );\n\n        \"b\" = 3;\n        \"a\" = 2;\n\n    \"PathID\" = '';\n\n    resetruleFiredCounts(\"ruleFiredFlags\", \"rulesfiredforrecordcount\");\n\n    \"_filter_\" = 1;\n\n    decisionPackage.execute(\n         \"a\"\n        ,\"b\"\n        ,\"c\"\n        ,\"PathID\"\n        ,\"ruleFiredFlags\", \"rulesFiredForRecordCount\"\n\n        ,\"_filter_\"\n);\n    \"_recordCorrelationKey\" = uuidgen();\n\n    output;\n  end;\nendthread;\n\n  ds2_options scond=none;\n\n  data \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\"(\n      overwrite=yes);\n\n    dcl thread decisionFlowThread t;\n\n    method run();\n       set from t threads=4;\n       output \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\";\n    end;\n  enddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Code generated from decision flow.

    Generated mapped code for decision flow.

    {
      "code": "\nds2_options scond=none;\n/* Custom Object add_cf retrieved on Fri May 07 16:53:12 UTC 2021 */\n/*{\"signatureExtension\":[]}*/\npackage \"add_dec_add_cf\" ;\n   method execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n    ds2_options scond=none;\n\n/* Decision add_dec version 1.5 generated on Fri May 07 16:53:12 UTC 2021 */\n  package Decision_ba7b8073_83f7_41ae_827 ;\n    dcl package logger logr_perf('App.tk.SID.Perf');\n    dcl double timer_start;\n    dcl double elapsed_time;\n    dcl double total_timer_start;\n    dcl double total_elapsed_time;\n\n    dcl package \"add_dec_add_cf\" \"add_dec_add_cf_hdl\"();\n\n    method initRuleFiredRecording();\n           dcl integer ruleFiredStartPosition;\n\n            /* query and set offsets - always traverse in same order as execute() method */\n            ruleFiredStartPosition = 1;\n    end;\n\n     method init();\n        initRuleFiredRecording();\n     end;\n\n    method execute (\n       double \"a\"\n      ,double \"b\"\n      ,in_out double \"c\"\n      ,in_out varchar \"PathID\"\n      ,in_out char \"ruleFiredFlags\"\n      ,in_out integer \"rulesFiredForRecordCount\"\n      ,in_out integer \"_filter_\"\n\n    );\n        dcl integer dg_filter_;\n\n        total_timer_start = datetime();\n\n        timer_start = datetime();\n        \"add_dec_add_cf_hdl\".execute(\"a\", \"b\", \"c\");\n        elapsed_time = datetime() - timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, Node Name: add_cf, Node ID: 5da31100-8063-4dae-8b6d-dbc5965328d9, NODE DURATION: ' .. elapsed_time);\n        if (\"_filter_\" = 0) then return;\n\n        \"PathID\" = \"PathID\" || '/' || '5da31100-8063-4dae-8b6d-dbc5965328d9';\n\n        \"end\":/*label for decision node link to flow end*/\n\n        total_elapsed_time = datetime() - total_timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, TOTAL DURATION: ' .. total_elapsed_time);\n\n     end;\n    endpackage;\n    ds2_options scond=none;\n  thread decisionFlowThread ;\n     dcl package Decision_ba7b8073_83f7_41ae_827 decisionPackage();\n     dcl varchar(38) \"PathID\";\n     dcl char(1) \"ruleFiredFlags\";\n     dcl integer       \"rulesFiredForRecordCount\" having label 'Rules Fired Count';\n     dcl char(36)      \"_recordCorrelationKey\";\n\n     dcl integer \"_filter_\";\n     /* declare input terms not read in from SET statement */\n\n     /* declare output terms not read in from SET statement */\n     dcl double \"c\";\n\n     /*declare static terms */\ndcl double \"b\";\ndcl double \"a\";\n\n  keep\n\n  \"PathID\" \"ruleFiredFlags\" \"rulesFiredForRecordCount\" \"_recordCorrelationKey\"\n  \"c\"\n    ;\n\n    method resetruleFiredCounts( in_out char \"ruleFiredFlags\", in_out integer \"rulesfiredforrecordcount\");\n        \"rulesfiredforrecordcount\"=0;\n    end;\n\n    method init();\n      decisionPackage.initRuleFiredRecording();\n    end;\n\n     method run();\n        dcl integer localRC;\n\n       set \"Public\".\"DUAL\"(\n          );\n\n        \"b\" = 3;\n        \"a\" = 2;\n\n    \"PathID\" = '';\n\n    resetruleFiredCounts(\"ruleFiredFlags\", \"rulesfiredforrecordcount\");\n\n    \"_filter_\" = 1;\n\n    decisionPackage.execute(\n         \"a\"\n        ,\"b\"\n        ,\"c\"\n        ,\"PathID\"\n        ,\"ruleFiredFlags\", \"rulesFiredForRecordCount\"\n\n        ,\"_filter_\"\n);\n    \"_recordCorrelationKey\" = uuidgen();\n\n    output;\n  end;\nendthread;\n\n  ds2_options scond=none;\n\n  data \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\"(\n      overwrite=yes);\n\n    dcl thread decisionFlowThread t;\n\n    method run();\n       set from t threads=4;\n       output \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\";\n    end;\n  enddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 2.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get decision code without score definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows/{decisionId}/mappedCode#unbound \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request.unbound+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "mappings": [
        {
          "mappingType": "static",
          "mappingValue": 25,
          "variableName": "a"
        }
      ],
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/mappedCode#unbound',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/decisions/flows/{decisionId}/mappedCode#unbound', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request.unbound+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows/{decisionId}/mappedCode#unbound", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows/{decisionId}/mappedCode#unbound

    Returns the code to be able to run the decision based on mapping to a static input and output data set of SASEP.IN and SASEP.OUT rather than binding to a score definition. This is deprecated. Use endpoint /flows/{decisionId}/mappedCode with Content-Type header as application/vnd.sas.score.code.generation.request.unbound+json.

    Body parameter

    Score code generation request unbound.

    {
      "mappings": [
        {
          "mappingType": "static",
          "mappingValue": 25,
          "variableName": "a"
        }
      ],
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    body body #/paths/~1flows~1%7BdecisionId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request.unbound%2Bjson/schema false none

    Example responses

    Generated mapped code for decision flow.

    {
      "code": "\nds2_options scond=none;\n/* Custom Object add_cf retrieved on Fri May 07 16:53:12 UTC 2021 */\n/*{\"signatureExtension\":[]}*/\npackage \"add_dec_add_cf\" ;\n   method execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n    ds2_options scond=none;\n\n/* Decision add_dec version 1.5 generated on Fri May 07 16:53:12 UTC 2021 */\n  package Decision_ba7b8073_83f7_41ae_827 ;\n    dcl package logger logr_perf('App.tk.SID.Perf');\n    dcl double timer_start;\n    dcl double elapsed_time;\n    dcl double total_timer_start;\n    dcl double total_elapsed_time;\n\n    dcl package \"add_dec_add_cf\" \"add_dec_add_cf_hdl\"();\n\n    method initRuleFiredRecording();\n           dcl integer ruleFiredStartPosition;\n\n            /* query and set offsets - always traverse in same order as execute() method */\n            ruleFiredStartPosition = 1;\n    end;\n\n     method init();\n        initRuleFiredRecording();\n     end;\n\n    method execute (\n       double \"a\"\n      ,double \"b\"\n      ,in_out double \"c\"\n      ,in_out varchar \"PathID\"\n      ,in_out char \"ruleFiredFlags\"\n      ,in_out integer \"rulesFiredForRecordCount\"\n      ,in_out integer \"_filter_\"\n\n    );\n        dcl integer dg_filter_;\n\n        total_timer_start = datetime();\n\n        timer_start = datetime();\n        \"add_dec_add_cf_hdl\".execute(\"a\", \"b\", \"c\");\n        elapsed_time = datetime() - timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, Node Name: add_cf, Node ID: 5da31100-8063-4dae-8b6d-dbc5965328d9, NODE DURATION: ' .. elapsed_time);\n        if (\"_filter_\" = 0) then return;\n\n        \"PathID\" = \"PathID\" || '/' || '5da31100-8063-4dae-8b6d-dbc5965328d9';\n\n        \"end\":/*label for decision node link to flow end*/\n\n        total_elapsed_time = datetime() - total_timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, TOTAL DURATION: ' .. total_elapsed_time);\n\n     end;\n    endpackage;\n    ds2_options scond=none;\n  thread decisionFlowThread ;\n     dcl package Decision_ba7b8073_83f7_41ae_827 decisionPackage();\n     dcl varchar(38) \"PathID\";\n     dcl char(1) \"ruleFiredFlags\";\n     dcl integer       \"rulesFiredForRecordCount\" having label 'Rules Fired Count';\n     dcl char(36)      \"_recordCorrelationKey\";\n\n     dcl integer \"_filter_\";\n     /* declare input terms not read in from SET statement */\n\n     /* declare output terms not read in from SET statement */\n     dcl double \"c\";\n\n     /*declare static terms */\ndcl double \"b\";\ndcl double \"a\";\n\n  keep\n\n  \"PathID\" \"ruleFiredFlags\" \"rulesFiredForRecordCount\" \"_recordCorrelationKey\"\n  \"c\"\n    ;\n\n    method resetruleFiredCounts( in_out char \"ruleFiredFlags\", in_out integer \"rulesfiredforrecordcount\");\n        \"rulesfiredforrecordcount\"=0;\n    end;\n\n    method init();\n      decisionPackage.initRuleFiredRecording();\n    end;\n\n     method run();\n        dcl integer localRC;\n\n       set \"Public\".\"DUAL\"(\n          );\n\n        \"b\" = 3;\n        \"a\" = 2;\n\n    \"PathID\" = '';\n\n    resetruleFiredCounts(\"ruleFiredFlags\", \"rulesfiredforrecordcount\");\n\n    \"_filter_\" = 1;\n\n    decisionPackage.execute(\n         \"a\"\n        ,\"b\"\n        ,\"c\"\n        ,\"PathID\"\n        ,\"ruleFiredFlags\", \"rulesFiredForRecordCount\"\n\n        ,\"_filter_\"\n);\n    \"_recordCorrelationKey\" = uuidgen();\n\n    output;\n  end;\nendthread;\n\n  ds2_options scond=none;\n\n  data \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\"(\n      overwrite=yes);\n\n    dcl thread decisionFlowThread t;\n\n    method run();\n       set from t threads=4;\n       output \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\";\n    end;\n  enddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 2.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get decision code not bound to a score definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows/{decisionId}/mappedCode#unboundCodeOnly \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request.unbound+json' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    const inputBody = '{
      "mappings": [
        {
          "mappingType": "static",
          "mappingValue": 25,
          "variableName": "a"
        }
      ],
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/mappedCode#unboundCodeOnly',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.post('https://example.com/decisions/flows/{decisionId}/mappedCode#unboundCodeOnly', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request.unbound+json"},
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows/{decisionId}/mappedCode#unboundCodeOnly", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows/{decisionId}/mappedCode#unboundCodeOnly

    Returns the code directly as text without being wrapped in a JSON model, that a user can use to be able to run the decision based on mapping to a static input and output data set of SASEP.IN and SASEP.OUT rather than binding to a score definition. This is deprecated. Use the endpoint /flows/{decisionId}/mappedCode with Accept header as text/vnd.sas.source.ds2.

    Body parameter

    Score code generation request unbound.

    {
      "mappings": [
        {
          "mappingType": "static",
          "mappingValue": 25,
          "variableName": "a"
        }
      ],
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    body body #/paths/~1flows~1%7BdecisionId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request.unbound%2Bjson/schema false none

    Example responses

    Code generated from decision flow.

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the analysis code for a decision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows/{decisionId}/analysisCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.analysis.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.analysis.code+json'
    
    
    const inputBody = '{
      "scoreExecutionId": "fc6e491b-fc28-49b7-9d6b-2f82af24ada9",
      "analysisType": "decisionPathFrequency",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept':'application/vnd.sas.score.analysis.code+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/analysisCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.analysis.code+json'
    }
    
    r = requests.post('https://example.com/decisions/flows/{decisionId}/analysisCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.analysis.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.analysis.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows/{decisionId}/analysisCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows/{decisionId}/analysisCode

    Returns the analysis code that is used to generate the rule fired or path tracking reports based on the scoring definition.

    Body parameter

    Analysis code generation request.

    {
      "scoreExecutionId": "fc6e491b-fc28-49b7-9d6b-2f82af24ada9",
      "analysisType": "decisionPathFrequency",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    body body #/paths/~1flows~1%7BdecisionId%7D~1analysisCode/post/requestBody/content/application~1vnd.sas.score.analysis.code.generation.request%2Bjson/schema true The information for scoreExecutionId and hints.

    Example responses

    Generated analysis code for decision flow.

    {
      "code": "loadActionSet \"simple\";\nloadActionSet \"ds2\";\n\naction simple.freq /\n    casOut={name='add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path' caslib='Public' replace=TRUE}\n    table={name='add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_output' caslib='Public' vars={{name='PathID'}} };\n\naction runDs2 / program = 'data\n\"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path\"(overwrite=yes\nrename=( _charvar_=PathID _frequency_=Count) keep=(PathID Count));\n                               method run();\n                                   set \"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path\";\n                               end;\n                           enddata;';\n",
      "codeType": "application/json",
      "outputTableName": "add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path",
      "outputLibraryName": "Public",
      "version": 1
    }
    
    {
      "code": "loadActionSet \"simple\";\nloadActionSet \"ds2\";\n\naction simple.freq /\n    casOut={name='add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path' caslib='Public' replace=TRUE}\n    table={name='add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_output' caslib='Public' vars={{name='PathID'}} };\n\naction runDs2 / program = 'data\n\"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path\"(overwrite=yes\nrename=( _charvar_=PathID _frequency_=Count) keep=(PathID Count));\n                               method run();\n                                   set \"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path\";\n                               end;\n                           enddata;';\n",
      "codeType": "application/json",
      "outputTableName": "add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 200

    Analysis Code

    Name Type Required Restrictions Description
    » code string true none Executable code generated by a Score Object.
    » codeType string(media-type) true none Type of the code.
    » outputTableName string true none Name of the table that will be generated when the generated code is executed.
    » outputLibraryName string true none Name of the library where the table will be generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 1.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get decision step code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows/{decisionId}/decisionStepCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision.step.code+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision.step.code+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/decisionStepCode',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision.step.code+json'
    }
    
    r = requests.get('https://example.com/decisions/flows/{decisionId}/decisionStepCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision.step.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows/{decisionId}/decisionStepCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows/{decisionId}/decisionStepCode

    Returns the step code for the specified decision.

    Parameters
    Name In Type Required Description
    decisionId path string true The identifier for the decision.

    Example responses

    Decision step code for decision flow.

    {
      "creationTimeStamp": "2021-05-07T16:06:56.319Z",
      "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "type": "decision",
      "name": "add_dec",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "currentRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "version": 1
    }
    
    {
      "creationTimeStamp": "2021-05-07T16:06:56.319Z",
      "modifiedTimeStamp": "2021-05-07T16:06:56.319Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "type": "decision",
      "name": "add_dec",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "currentRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "version": 1
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No decision exists at the requested path. Inline
    Response Schema

    Status Code 200

    Decision Step Code

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string false none The name of the object used in decision step.
    » description string false none The description of the object used in decision step.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » code string false none The code of the object used in the decision step.
    » type string false none The object type of the object used in the decision step.
    » signature [any] false none Signature variables of the object used in the decision step.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get a list of external artifacts for a decision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows/{decisionId}/externalArtifacts \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.decision.external.artifact+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.decision.external.artifact+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/externalArtifacts',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.decision.external.artifact+json'
    }
    
    r = requests.get('https://example.com/decisions/flows/{decisionId}/externalArtifacts', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.decision.external.artifact+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows/{decisionId}/externalArtifacts", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows/{decisionId}/externalArtifacts

    Returns the list of external artifacts used by a decision revision. Objects used by a step of the steps collection in a decision flow are considered external artifacts. Some examples of such objects are files and web services. This endpoint returns the collection of external artifacts. The collection might be empty if there is no external artifact used by any step of the decision. The expected number of external artifacts is small. Therefore, this endpoint does not support any paging, filtering, or sorting of parameters.

    Parameters
    Name In Type Required Description
    decisionId path string true Id of the decision.
    Accept-Item header string false Used for selecting desired item representation.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.decision.external.artifact+json

    Example responses

    External artifacts related to decision flow.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/",
          "type": "application/vnd.sas.decision"
        }
      ],
      "name": "external-artifacts",
      "accept": "application/vnd.sas.decision.external.artifact",
      "count": 0,
      "items": [],
      "version": 2
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/",
          "type": "application/vnd.sas.decision"
        }
      ],
      "name": "external-artifacts",
      "accept": "application/vnd.sas.decision.external.artifact",
      "count": 0,
      "items": [],
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. externalArtifactsCollection
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    DecisionRevisions

    Contains the operations to create, read, and delete decisions.

    Get all revisions for a decision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows/{decisionId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.decision+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.decision+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.decision+json'
    }
    
    r = requests.get('https://example.com/decisions/flows/{decisionId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.decision+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows/{decisionId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows/{decisionId}/revisions

    Retrieves a list of all revisions that exist for a decision.

    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for a decision
    filter query string(filter-criteria) false The criteria for filtering the decision flow revisions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the decision flow revisions. See Sorting in REST APIs.
    start query integer false The starting index of the first item in a page. The index is 0-based. Default is 0.
    limit query integer false The maximum number of items to return in this page of results. The actual number of returned items might be less if the collection has been exhausted. The default is 10.
    Accept-Item header string(media-type) false Used for selecting desired item representation.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.decision+json
    Accept-Item application/vnd.sas.summary+json

    Example responses

    Decision flow revisions with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=2&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=0&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=1&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=3&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "POST",
          "rel": "createRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "name": "revisions",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 6,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T16:06:05.631Z",
          "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "77cfc1c3-f050-4169-939a-941e7c664215",
          "name": "add_dec",
          "type": "decision",
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
            },
            {
              "method": "GET",
              "rel": "code",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
              "type": "text/vnd.sas.source.ds2"
            },
            {
              "method": "POST",
              "rel": "mappedCode",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
              "type": "application/vnd.sas.score.code.generation.request",
              "responseType": "application/vnd.sas.score.mapped.code"
            },
            {
              "method": "GET",
              "rel": "decision",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Decision flow revisions with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=2&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=0&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=1&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=3&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "POST",
          "rel": "createRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "name": "revisions",
      "accept": "application/vnd.sas.decision",
      "start": 2,
      "count": 6,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T16:06:05.631Z",
          "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "77cfc1c3-f050-4169-939a-941e7c664215",
          "name": "add_dec",
          "majorRevision": 1,
          "minorRevision": 2,
          "signature": [
            {
              "creationTimeStamp": "2021-05-07T16:04:52.928Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
              "direction": "input",
              "name": "a",
              "dataType": "decimal"
            },
            {
              "creationTimeStamp": "2021-05-07T16:04:52.929Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
              "direction": "input",
              "name": "b",
              "dataType": "decimal"
            },
            {
              "creationTimeStamp": "2021-05-07T16:04:52.929Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
              "direction": "output",
              "name": "c",
              "dataType": "decimal"
            }
          ],
          "flow": {
            "creationTimeStamp": "2021-05-07T16:06:05.643Z",
            "modifiedTimeStamp": "2021-05-07T16:06:05.643Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "d246efaf-bd46-4437-8d66-2de3f012cce8",
            "steps": [
              {
                "type": "application/vnd.sas.decision.step.custom.object",
                "creationTimeStamp": "2021-05-07T16:06:05.646Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "34be776f-971c-4fcb-9a6d-30bbceec62d5",
                "publishedModule": {},
                "customObject": {
                  "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                  "name": "add_cf",
                  "type": "decisionDS2CodeFile"
                },
                "mappings": [
                  {
                    "creationTimeStamp": "2021-05-07T16:06:05.646Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "2c6f4172-c189-4a59-bf43-92eba3bbe77c",
                    "targetDecisionTermName": "a",
                    "direction": "input",
                    "stepTermName": "a"
                  },
                  {
                    "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "6110fe71-377a-4838-86e1-f12b70f42bba",
                    "targetDecisionTermName": "b",
                    "direction": "input",
                    "stepTermName": "b"
                  },
                  {
                    "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "255b9815-a949-4c61-972f-d42f9002f1cb",
                    "targetDecisionTermName": "c",
                    "direction": "output",
                    "stepTermName": "c"
                  }
                ],
                "links": [
                  {
                    "method": "GET",
                    "rel": "customObjectCode",
                    "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                    "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                    "responseType": "application/vnd.sas.decision.step.code"
                  }
                ]
              }
            ]
          },
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
            },
            {
              "method": "GET",
              "rel": "code",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
              "type": "text/vnd.sas.source.ds2"
            },
            {
              "method": "POST",
              "rel": "mappedCode",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
              "type": "application/vnd.sas.score.code.generation.request",
              "responseType": "application/vnd.sas.score.mapped.code"
            },
            {
              "method": "GET",
              "rel": "decision",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Decision flow revisions with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=2&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=0&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=1&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=3&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "POST",
          "rel": "createRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "name": "revisions",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 6,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T16:06:05.631Z",
          "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "77cfc1c3-f050-4169-939a-941e7c664215",
          "name": "add_dec",
          "type": "decision",
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
            },
            {
              "method": "GET",
              "rel": "code",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
              "type": "text/vnd.sas.source.ds2"
            },
            {
              "method": "POST",
              "rel": "mappedCode",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
              "type": "application/vnd.sas.score.code.generation.request",
              "responseType": "application/vnd.sas.score.mapped.code"
            },
            {
              "method": "GET",
              "rel": "decision",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Decision flow revisions with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=2&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=0&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=1&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=3&limit=1",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions?filter=eq(decisionId,'e2cf4209-2661-4ef1-b77f-10b91a6420e3')&sortBy=majorNumber:ascending,minorNumber:ascending&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision"
        },
        {
          "method": "POST",
          "rel": "createRevision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions",
          "type": "application/vnd.sas.decision",
          "responseType": "application/vnd.sas.decision"
        }
      ],
      "name": "revisions",
      "accept": "application/vnd.sas.decision",
      "start": 2,
      "count": 6,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T16:06:05.631Z",
          "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "77cfc1c3-f050-4169-939a-941e7c664215",
          "name": "add_dec",
          "majorRevision": 1,
          "minorRevision": 2,
          "signature": [
            {
              "creationTimeStamp": "2021-05-07T16:04:52.928Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
              "direction": "input",
              "name": "a",
              "dataType": "decimal"
            },
            {
              "creationTimeStamp": "2021-05-07T16:04:52.929Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
              "direction": "input",
              "name": "b",
              "dataType": "decimal"
            },
            {
              "creationTimeStamp": "2021-05-07T16:04:52.929Z",
              "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
              "createdBy": "edmdev",
              "modifiedBy": "edmdev",
              "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
              "direction": "output",
              "name": "c",
              "dataType": "decimal"
            }
          ],
          "flow": {
            "creationTimeStamp": "2021-05-07T16:06:05.643Z",
            "modifiedTimeStamp": "2021-05-07T16:06:05.643Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "d246efaf-bd46-4437-8d66-2de3f012cce8",
            "steps": [
              {
                "type": "application/vnd.sas.decision.step.custom.object",
                "creationTimeStamp": "2021-05-07T16:06:05.646Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "34be776f-971c-4fcb-9a6d-30bbceec62d5",
                "publishedModule": {},
                "customObject": {
                  "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                  "name": "add_cf",
                  "type": "decisionDS2CodeFile"
                },
                "mappings": [
                  {
                    "creationTimeStamp": "2021-05-07T16:06:05.646Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "2c6f4172-c189-4a59-bf43-92eba3bbe77c",
                    "targetDecisionTermName": "a",
                    "direction": "input",
                    "stepTermName": "a"
                  },
                  {
                    "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "6110fe71-377a-4838-86e1-f12b70f42bba",
                    "targetDecisionTermName": "b",
                    "direction": "input",
                    "stepTermName": "b"
                  },
                  {
                    "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                    "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                    "createdBy": "edmdev",
                    "modifiedBy": "edmdev",
                    "id": "255b9815-a949-4c61-972f-d42f9002f1cb",
                    "targetDecisionTermName": "c",
                    "direction": "output",
                    "stepTermName": "c"
                  }
                ],
                "links": [
                  {
                    "method": "GET",
                    "rel": "customObjectCode",
                    "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                    "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                    "responseType": "application/vnd.sas.decision.step.code"
                  }
                ]
              }
            ]
          },
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "type": "application/vnd.sas.decision"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
            },
            {
              "method": "GET",
              "rel": "code",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
              "type": "text/vnd.sas.source.ds2"
            },
            {
              "method": "POST",
              "rel": "mappedCode",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
              "type": "application/vnd.sas.score.code.generation.request",
              "responseType": "application/vnd.sas.score.mapped.code"
            },
            {
              "method": "GET",
              "rel": "decision",
              "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
              "type": "application/vnd.sas.decision"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No decision exists at the requested path. Inline
    Response Schema
    Enumerated Values
    Property Value
    type application/vnd.sas.decision.step.ruleset
    direction input
    direction output
    direction inOut
    type application/vnd.sas.decision.step.model
    type application/vnd.sas.decision.step.custom.object
    type application/vnd.sas.decision.step.record.contact
    type application/vnd.sas.decision.step.node.link
    type application/vnd.sas.decision.step.condition
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    dataType dataGrid
    direction input
    direction output
    direction inOut
    direction none
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    type application/vnd.sas.decision.step.branch
    booleanOperator AND
    booleanOperator OR

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a decision revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows/{decisionId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision+json' \
      -H 'Accept: application/vnd.sas.decision+json'
    
    
    const inputBody = '{
      "name": "My Decision With Code File",
      "signature": [
        {
          "direction": "input",
          "name": "my_input",
          "dataType": "decimal"
        },
        {
          "direction": "output",
          "name": "my_output",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "customObject": {
              "uri": "/decisions/codeFiles/34e54af1-c371-40b7-a186-7a3fcef7d033/revisions/b8fbb2d2-4046-423b-95e1-f9711b3ad26a",
              "name": "My DS2 Code File",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "targetDecisionTermName": "my_input",
                "direction": "input",
                "stepTermName": "my_input"
              },
              {
                "targetDecisionTermName": "my_output",
                "direction": "output",
                "stepTermName": "my_output"
              }
            ]
          }
        ]
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision+json',
      'Accept':'application/vnd.sas.decision+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision+json',
      'Accept': 'application/vnd.sas.decision+json'
    }
    
    r = requests.post('https://example.com/decisions/flows/{decisionId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision+json"},
            "Accept": []string{"application/vnd.sas.decision+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows/{decisionId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows/{decisionId}/revisions

    Creates a new revision for the decision.

    Body parameter

    Decision flow.

    {
      "name": "My Decision With Code File",
      "signature": [
        {
          "direction": "input",
          "name": "my_input",
          "dataType": "decimal"
        },
        {
          "direction": "output",
          "name": "my_output",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "customObject": {
              "uri": "/decisions/codeFiles/34e54af1-c371-40b7-a186-7a3fcef7d033/revisions/b8fbb2d2-4046-423b-95e1-f9711b3ad26a",
              "name": "My DS2 Code File",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "targetDecisionTermName": "my_input",
                "direction": "input",
                "stepTermName": "my_input"
              },
              {
                "targetDecisionTermName": "my_output",
                "direction": "output",
                "stepTermName": "my_output"
              }
            ]
          }
        ]
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for a decision
    revisionType query string false Valid Values are 'major' or 'minor'. This value determines how the server generates the major or minor revision numbers. If major is provided the next available major revision number is initiated. For example, if the decision has revisions 1.0, 1.1, 1.2, 2.0, 2.1, when you create a new major revision the result is 3.0. If minor is provided, then the next available minor revision number is reserved based on the existing revisions. This parameter is defaulted to 'minor', if not supplied.
    fromRevisionUri query string false This value specifies the URI of the decision revision from which the new decision is created. This property enables you to trace the lineage of a decision. The valid format for this parameter is '/decisions/flows/${decisionId}/revisions/${revisionId}'
    body body decision true none
    Enumerated Values
    Parameter Value
    revisionType major
    revisionType minor

    Example responses

    Deecision flow revision with full details.

    {
      "creationTimeStamp": "2021-05-07T16:06:05.631Z",
      "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "77cfc1c3-f050-4169-939a-941e7c664215",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 2,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:05.643Z",
        "modifiedTimeStamp": "2021-05-07T16:06:05.643Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "d246efaf-bd46-4437-8d66-2de3f012cce8",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:05.646Z",
            "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "34be776f-971c-4fcb-9a6d-30bbceec62d5",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:05.646Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "2c6f4172-c189-4a59-bf43-92eba3bbe77c",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6110fe71-377a-4838-86e1-f12b70f42bba",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "255b9815-a949-4c61-972f-d42f9002f1cb",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "decision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        }
      ],
      "decisionId": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:05.631Z",
      "version": 2
    }
    
    {
      "creationTimeStamp": "2021-05-07T16:06:05.631Z",
      "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "77cfc1c3-f050-4169-939a-941e7c664215",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 2,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:05.643Z",
        "modifiedTimeStamp": "2021-05-07T16:06:05.643Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "d246efaf-bd46-4437-8d66-2de3f012cce8",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:05.646Z",
            "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "34be776f-971c-4fcb-9a6d-30bbceec62d5",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:05.646Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "2c6f4172-c189-4a59-bf43-92eba3bbe77c",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6110fe71-377a-4838-86e1-f12b70f42bba",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "255b9815-a949-4c61-972f-d42f9002f1cb",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "decision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        }
      ],
      "decisionId": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:05.631Z",
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A revision of the decision was created. decision
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No decision exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Last-Modified string No description
    201 Location string No description
    201 ETag string The entity tag for the decision flow revision.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get content for a decision revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows/{decisionId}/revisions/{revisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision+json'
    }
    
    r = requests.get('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows/{decisionId}/revisions/{revisionId}

    Retrieves the content for the decision revision requested.

    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    revisionId path string true Identifier for the decision revision.

    Example responses

    Deecision flow revision with full details.

    {
      "creationTimeStamp": "2021-05-07T16:06:05.631Z",
      "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "77cfc1c3-f050-4169-939a-941e7c664215",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 2,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:05.643Z",
        "modifiedTimeStamp": "2021-05-07T16:06:05.643Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "d246efaf-bd46-4437-8d66-2de3f012cce8",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:05.646Z",
            "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "34be776f-971c-4fcb-9a6d-30bbceec62d5",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:05.646Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "2c6f4172-c189-4a59-bf43-92eba3bbe77c",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6110fe71-377a-4838-86e1-f12b70f42bba",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "255b9815-a949-4c61-972f-d42f9002f1cb",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "decision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        }
      ],
      "decisionId": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:05.631Z",
      "version": 2
    }
    

    Decision flow revision with resource summary details.

    {
      "creationTimeStamp": "2021-05-07T16:06:05.631Z",
      "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "77cfc1c3-f050-4169-939a-941e7c664215",
      "type": "decision",
      "name": "add_dec",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "type": "application/vnd.sas.summary"
        }
      ],
      "version": 2
    }
    

    Deecision flow revision with full details.

    {
      "creationTimeStamp": "2021-05-07T16:06:05.631Z",
      "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "77cfc1c3-f050-4169-939a-941e7c664215",
      "name": "add_dec",
      "majorRevision": 1,
      "minorRevision": 2,
      "signature": [
        {
          "creationTimeStamp": "2021-05-07T16:04:52.928Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "ab71e7ea-abe8-4a69-afd5-4a2ba65ef5c8",
          "direction": "input",
          "name": "a",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "d6b357c6-e798-48b1-ad42-bb3db4cfa774",
          "direction": "input",
          "name": "b",
          "dataType": "decimal"
        },
        {
          "creationTimeStamp": "2021-05-07T16:04:52.929Z",
          "modifiedTimeStamp": "2021-05-07T16:06:56.330Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "8de5614b-48c2-4631-b819-ecc3e63ee0a6",
          "direction": "output",
          "name": "c",
          "dataType": "decimal"
        }
      ],
      "flow": {
        "creationTimeStamp": "2021-05-07T16:06:05.643Z",
        "modifiedTimeStamp": "2021-05-07T16:06:05.643Z",
        "createdBy": "edmdev",
        "modifiedBy": "edmdev",
        "id": "d246efaf-bd46-4437-8d66-2de3f012cce8",
        "steps": [
          {
            "type": "application/vnd.sas.decision.step.custom.object",
            "creationTimeStamp": "2021-05-07T16:06:05.646Z",
            "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
            "createdBy": "edmdev",
            "modifiedBy": "edmdev",
            "id": "34be776f-971c-4fcb-9a6d-30bbceec62d5",
            "publishedModule": {},
            "customObject": {
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "name": "add_cf",
              "type": "decisionDS2CodeFile"
            },
            "mappings": [
              {
                "creationTimeStamp": "2021-05-07T16:06:05.646Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.646Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "2c6f4172-c189-4a59-bf43-92eba3bbe77c",
                "targetDecisionTermName": "a",
                "direction": "input",
                "stepTermName": "a"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "6110fe71-377a-4838-86e1-f12b70f42bba",
                "targetDecisionTermName": "b",
                "direction": "input",
                "stepTermName": "b"
              },
              {
                "creationTimeStamp": "2021-05-07T16:06:05.647Z",
                "modifiedTimeStamp": "2021-05-07T16:06:05.647Z",
                "createdBy": "edmdev",
                "modifiedBy": "edmdev",
                "id": "255b9815-a949-4c61-972f-d42f9002f1cb",
                "targetDecisionTermName": "c",
                "direction": "output",
                "stepTermName": "c"
              }
            ],
            "links": [
              {
                "method": "GET",
                "rel": "customObjectCode",
                "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
                "responseType": "application/vnd.sas.decision.step.code"
              }
            ]
          }
        ]
      },
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "decision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        }
      ],
      "decisionId": "e2cf4209-2661-4ef1-b77f-10b91a6420e3",
      "nodeCount": 1,
      "folderType": "userFolder",
      "sourceRevisionUri": "/decisions/flows/ab9b6a31-7b81-4202-af3f-86be4b6a89ba/revisions/9aa1c575-76b6-4fbd-b865-eb7fb32065bf",
      "copyTimeStamp": "2021-05-07T16:06:05.631Z",
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. decision
    404 Not Found No decision revision exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description
    200 ETag string The entity tag for the decision flow revision.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a locked decision revision

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /flows/{decisionId}/revisions/{revisionId}

    Deletes the specified locked decision revision.

    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    revisionId path string true Identifier for the decision revision.
    Responses
    Status Meaning Description Schema
    204 No Content The decision revision was deleted. None
    Response Headers
    Status Header Type Format Description
    204 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get code for a decision revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/code \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    
    const headers = {
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/code',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.get('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/code', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/code", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows/{decisionId}/revisions/{revisionId}/code

    Retrieves the DS2 package code, which can then be used to execute the decision revision.

    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    revisionId path string true Identifier for the decision revision.
    codeTarget query string false The type of platform or scenario that the generated code is used in. If the generated DS2 code is going to be run in the SAS Micro Analytic Service, then the "microAnalyticService" type should be specified. If the code is included as part of another decision, and therefore should not be wrapped in a driver, "subDecision" should be specified. In all other cases, "others" should be specified.
    Detailed descriptions

    codeTarget: The type of platform or scenario that the generated code is used in. If the generated DS2 code is going to be run in the SAS Micro Analytic Service, then the "microAnalyticService" type should be specified. If the code is included as part of another decision, and therefore should not be wrapped in a driver, "subDecision" should be specified. In all other cases, "others" should be specified.

    Enumerated Values
    Parameter Value
    codeTarget microAnalyticService
    codeTarget others
    codeTarget subDecision

    Example responses

    Code generated from decision flow.

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    404 Not Found No code for the decision revision exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the mapped code of a decision revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "scoreDefinitionId": "2d7d079d-963f-4c5e-a920-262accd4eb9e",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows/{decisionId}/revisions/{revisionId}/mappedCode

    Returns the code bound to data specified in the score request for execution for the decision revision.

    Body parameter

    Score code generation request.

    {
      "scoreDefinitionId": "2d7d079d-963f-4c5e-a920-262accd4eb9e",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    revisionId path string true Identifier for the revision.
    body body #/paths/~1flows~1%7BdecisionId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request%2Bjson/schema false none

    Example responses

    Generated mapped code for decision flow.

    {
      "code": "\nds2_options scond=none;\n/* Custom Object add_cf retrieved on Fri May 07 16:53:12 UTC 2021 */\n/*{\"signatureExtension\":[]}*/\npackage \"add_dec_add_cf\" ;\n   method execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n    ds2_options scond=none;\n\n/* Decision add_dec version 1.5 generated on Fri May 07 16:53:12 UTC 2021 */\n  package Decision_ba7b8073_83f7_41ae_827 ;\n    dcl package logger logr_perf('App.tk.SID.Perf');\n    dcl double timer_start;\n    dcl double elapsed_time;\n    dcl double total_timer_start;\n    dcl double total_elapsed_time;\n\n    dcl package \"add_dec_add_cf\" \"add_dec_add_cf_hdl\"();\n\n    method initRuleFiredRecording();\n           dcl integer ruleFiredStartPosition;\n\n            /* query and set offsets - always traverse in same order as execute() method */\n            ruleFiredStartPosition = 1;\n    end;\n\n     method init();\n        initRuleFiredRecording();\n     end;\n\n    method execute (\n       double \"a\"\n      ,double \"b\"\n      ,in_out double \"c\"\n      ,in_out varchar \"PathID\"\n      ,in_out char \"ruleFiredFlags\"\n      ,in_out integer \"rulesFiredForRecordCount\"\n      ,in_out integer \"_filter_\"\n\n    );\n        dcl integer dg_filter_;\n\n        total_timer_start = datetime();\n\n        timer_start = datetime();\n        \"add_dec_add_cf_hdl\".execute(\"a\", \"b\", \"c\");\n        elapsed_time = datetime() - timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, Node Name: add_cf, Node ID: 5da31100-8063-4dae-8b6d-dbc5965328d9, NODE DURATION: ' .. elapsed_time);\n        if (\"_filter_\" = 0) then return;\n\n        \"PathID\" = \"PathID\" || '/' || '5da31100-8063-4dae-8b6d-dbc5965328d9';\n\n        \"end\":/*label for decision node link to flow end*/\n\n        total_elapsed_time = datetime() - total_timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, TOTAL DURATION: ' .. total_elapsed_time);\n\n     end;\n    endpackage;\n    ds2_options scond=none;\n  thread decisionFlowThread ;\n     dcl package Decision_ba7b8073_83f7_41ae_827 decisionPackage();\n     dcl varchar(38) \"PathID\";\n     dcl char(1) \"ruleFiredFlags\";\n     dcl integer       \"rulesFiredForRecordCount\" having label 'Rules Fired Count';\n     dcl char(36)      \"_recordCorrelationKey\";\n\n     dcl integer \"_filter_\";\n     /* declare input terms not read in from SET statement */\n\n     /* declare output terms not read in from SET statement */\n     dcl double \"c\";\n\n     /*declare static terms */\ndcl double \"b\";\ndcl double \"a\";\n\n  keep\n\n  \"PathID\" \"ruleFiredFlags\" \"rulesFiredForRecordCount\" \"_recordCorrelationKey\"\n  \"c\"\n    ;\n\n    method resetruleFiredCounts( in_out char \"ruleFiredFlags\", in_out integer \"rulesfiredforrecordcount\");\n        \"rulesfiredforrecordcount\"=0;\n    end;\n\n    method init();\n      decisionPackage.initRuleFiredRecording();\n    end;\n\n     method run();\n        dcl integer localRC;\n\n       set \"Public\".\"DUAL\"(\n          );\n\n        \"b\" = 3;\n        \"a\" = 2;\n\n    \"PathID\" = '';\n\n    resetruleFiredCounts(\"ruleFiredFlags\", \"rulesfiredforrecordcount\");\n\n    \"_filter_\" = 1;\n\n    decisionPackage.execute(\n         \"a\"\n        ,\"b\"\n        ,\"c\"\n        ,\"PathID\"\n        ,\"ruleFiredFlags\", \"rulesFiredForRecordCount\"\n\n        ,\"_filter_\"\n);\n    \"_recordCorrelationKey\" = uuidgen();\n\n    output;\n  end;\nendthread;\n\n  ds2_options scond=none;\n\n  data \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\"(\n      overwrite=yes);\n\n    dcl thread decisionFlowThread t;\n\n    method run();\n       set from t threads=4;\n       output \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\";\n    end;\n  enddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Code generated from decision flow.

    Generated mapped code for decision flow.

    {
      "code": "\nds2_options scond=none;\n/* Custom Object add_cf retrieved on Fri May 07 16:53:12 UTC 2021 */\n/*{\"signatureExtension\":[]}*/\npackage \"add_dec_add_cf\" ;\n   method execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n    ds2_options scond=none;\n\n/* Decision add_dec version 1.5 generated on Fri May 07 16:53:12 UTC 2021 */\n  package Decision_ba7b8073_83f7_41ae_827 ;\n    dcl package logger logr_perf('App.tk.SID.Perf');\n    dcl double timer_start;\n    dcl double elapsed_time;\n    dcl double total_timer_start;\n    dcl double total_elapsed_time;\n\n    dcl package \"add_dec_add_cf\" \"add_dec_add_cf_hdl\"();\n\n    method initRuleFiredRecording();\n           dcl integer ruleFiredStartPosition;\n\n            /* query and set offsets - always traverse in same order as execute() method */\n            ruleFiredStartPosition = 1;\n    end;\n\n     method init();\n        initRuleFiredRecording();\n     end;\n\n    method execute (\n       double \"a\"\n      ,double \"b\"\n      ,in_out double \"c\"\n      ,in_out varchar \"PathID\"\n      ,in_out char \"ruleFiredFlags\"\n      ,in_out integer \"rulesFiredForRecordCount\"\n      ,in_out integer \"_filter_\"\n\n    );\n        dcl integer dg_filter_;\n\n        total_timer_start = datetime();\n\n        timer_start = datetime();\n        \"add_dec_add_cf_hdl\".execute(\"a\", \"b\", \"c\");\n        elapsed_time = datetime() - timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, Node Name: add_cf, Node ID: 5da31100-8063-4dae-8b6d-dbc5965328d9, NODE DURATION: ' .. elapsed_time);\n        if (\"_filter_\" = 0) then return;\n\n        \"PathID\" = \"PathID\" || '/' || '5da31100-8063-4dae-8b6d-dbc5965328d9';\n\n        \"end\":/*label for decision node link to flow end*/\n\n        total_elapsed_time = datetime() - total_timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, TOTAL DURATION: ' .. total_elapsed_time);\n\n     end;\n    endpackage;\n    ds2_options scond=none;\n  thread decisionFlowThread ;\n     dcl package Decision_ba7b8073_83f7_41ae_827 decisionPackage();\n     dcl varchar(38) \"PathID\";\n     dcl char(1) \"ruleFiredFlags\";\n     dcl integer       \"rulesFiredForRecordCount\" having label 'Rules Fired Count';\n     dcl char(36)      \"_recordCorrelationKey\";\n\n     dcl integer \"_filter_\";\n     /* declare input terms not read in from SET statement */\n\n     /* declare output terms not read in from SET statement */\n     dcl double \"c\";\n\n     /*declare static terms */\ndcl double \"b\";\ndcl double \"a\";\n\n  keep\n\n  \"PathID\" \"ruleFiredFlags\" \"rulesFiredForRecordCount\" \"_recordCorrelationKey\"\n  \"c\"\n    ;\n\n    method resetruleFiredCounts( in_out char \"ruleFiredFlags\", in_out integer \"rulesfiredforrecordcount\");\n        \"rulesfiredforrecordcount\"=0;\n    end;\n\n    method init();\n      decisionPackage.initRuleFiredRecording();\n    end;\n\n     method run();\n        dcl integer localRC;\n\n       set \"Public\".\"DUAL\"(\n          );\n\n        \"b\" = 3;\n        \"a\" = 2;\n\n    \"PathID\" = '';\n\n    resetruleFiredCounts(\"ruleFiredFlags\", \"rulesfiredforrecordcount\");\n\n    \"_filter_\" = 1;\n\n    decisionPackage.execute(\n         \"a\"\n        ,\"b\"\n        ,\"c\"\n        ,\"PathID\"\n        ,\"ruleFiredFlags\", \"rulesFiredForRecordCount\"\n\n        ,\"_filter_\"\n);\n    \"_recordCorrelationKey\" = uuidgen();\n\n    output;\n  end;\nendthread;\n\n  ds2_options scond=none;\n\n  data \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\"(\n      overwrite=yes);\n\n    dcl thread decisionFlowThread t;\n\n    method run();\n       set from t threads=4;\n       output \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\";\n    end;\n  enddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 2.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get decision revision code without a score definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode#unbound \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request.unbound+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "mappings": [
        {
          "mappingType": "static",
          "mappingValue": 25,
          "variableName": "a"
        }
      ],
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode#unbound',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode#unbound', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request.unbound+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode#unbound", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows/{decisionId}/revisions/{revisionId}/mappedCode#unbound

    Returns the code to be able to run the decision revision based on mapping to a static input and output data set of SASEP.IN and SASEP.OUT rather than binding to a score definition. This is deprecated. Please use endpoint /flows/{decisionId}/revisions/{revisionId}/mappedCode with Content-Type header as application/vnd.sas.score.code.generation.request.unbound+json.

    Body parameter

    Score code generation request unbound.

    {
      "mappings": [
        {
          "mappingType": "static",
          "mappingValue": 25,
          "variableName": "a"
        }
      ],
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    revisionId path string true Identifier for the revision.
    body body #/paths/~1flows~1%7BdecisionId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request.unbound%2Bjson/schema false none

    Example responses

    Generated mapped code for decision flow.

    {
      "code": "\nds2_options scond=none;\n/* Custom Object add_cf retrieved on Fri May 07 16:53:12 UTC 2021 */\n/*{\"signatureExtension\":[]}*/\npackage \"add_dec_add_cf\" ;\n   method execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n    ds2_options scond=none;\n\n/* Decision add_dec version 1.5 generated on Fri May 07 16:53:12 UTC 2021 */\n  package Decision_ba7b8073_83f7_41ae_827 ;\n    dcl package logger logr_perf('App.tk.SID.Perf');\n    dcl double timer_start;\n    dcl double elapsed_time;\n    dcl double total_timer_start;\n    dcl double total_elapsed_time;\n\n    dcl package \"add_dec_add_cf\" \"add_dec_add_cf_hdl\"();\n\n    method initRuleFiredRecording();\n           dcl integer ruleFiredStartPosition;\n\n            /* query and set offsets - always traverse in same order as execute() method */\n            ruleFiredStartPosition = 1;\n    end;\n\n     method init();\n        initRuleFiredRecording();\n     end;\n\n    method execute (\n       double \"a\"\n      ,double \"b\"\n      ,in_out double \"c\"\n      ,in_out varchar \"PathID\"\n      ,in_out char \"ruleFiredFlags\"\n      ,in_out integer \"rulesFiredForRecordCount\"\n      ,in_out integer \"_filter_\"\n\n    );\n        dcl integer dg_filter_;\n\n        total_timer_start = datetime();\n\n        timer_start = datetime();\n        \"add_dec_add_cf_hdl\".execute(\"a\", \"b\", \"c\");\n        elapsed_time = datetime() - timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, Node Name: add_cf, Node ID: 5da31100-8063-4dae-8b6d-dbc5965328d9, NODE DURATION: ' .. elapsed_time);\n        if (\"_filter_\" = 0) then return;\n\n        \"PathID\" = \"PathID\" || '/' || '5da31100-8063-4dae-8b6d-dbc5965328d9';\n\n        \"end\":/*label for decision node link to flow end*/\n\n        total_elapsed_time = datetime() - total_timer_start;\n        logr_perf.log( 'd', 'Package Name: Decision_ba7b8073_83f7_41ae_827, TOTAL DURATION: ' .. total_elapsed_time);\n\n     end;\n    endpackage;\n    ds2_options scond=none;\n  thread decisionFlowThread ;\n     dcl package Decision_ba7b8073_83f7_41ae_827 decisionPackage();\n     dcl varchar(38) \"PathID\";\n     dcl char(1) \"ruleFiredFlags\";\n     dcl integer       \"rulesFiredForRecordCount\" having label 'Rules Fired Count';\n     dcl char(36)      \"_recordCorrelationKey\";\n\n     dcl integer \"_filter_\";\n     /* declare input terms not read in from SET statement */\n\n     /* declare output terms not read in from SET statement */\n     dcl double \"c\";\n\n     /*declare static terms */\ndcl double \"b\";\ndcl double \"a\";\n\n  keep\n\n  \"PathID\" \"ruleFiredFlags\" \"rulesFiredForRecordCount\" \"_recordCorrelationKey\"\n  \"c\"\n    ;\n\n    method resetruleFiredCounts( in_out char \"ruleFiredFlags\", in_out integer \"rulesfiredforrecordcount\");\n        \"rulesfiredforrecordcount\"=0;\n    end;\n\n    method init();\n      decisionPackage.initRuleFiredRecording();\n    end;\n\n     method run();\n        dcl integer localRC;\n\n       set \"Public\".\"DUAL\"(\n          );\n\n        \"b\" = 3;\n        \"a\" = 2;\n\n    \"PathID\" = '';\n\n    resetruleFiredCounts(\"ruleFiredFlags\", \"rulesfiredforrecordcount\");\n\n    \"_filter_\" = 1;\n\n    decisionPackage.execute(\n         \"a\"\n        ,\"b\"\n        ,\"c\"\n        ,\"PathID\"\n        ,\"ruleFiredFlags\", \"rulesFiredForRecordCount\"\n\n        ,\"_filter_\"\n);\n    \"_recordCorrelationKey\" = uuidgen();\n\n    output;\n  end;\nendthread;\n\n  ds2_options scond=none;\n\n  data \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\"(\n      overwrite=yes);\n\n    dcl thread decisionFlowThread t;\n\n    method run();\n       set from t threads=4;\n       output \"Public\".\"add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output\";\n    end;\n  enddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_dec_Scenario_1_add_dec_2021-05-07_16-53-11_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 2.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get code for decision revision not bound to score definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode#unboundCodeOnly \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request.unbound+json' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    const inputBody = '{
      "mappings": [
        {
          "mappingType": "static",
          "mappingValue": 25,
          "variableName": "a"
        }
      ],
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode#unboundCodeOnly',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request.unbound+json',
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.post('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode#unboundCodeOnly', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request.unbound+json"},
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/mappedCode#unboundCodeOnly", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows/{decisionId}/revisions/{revisionId}/mappedCode#unboundCodeOnly

    Returns the code directly as text without being wrapped in a JSON model, that a user can use to be able to run the decision revision based on mapping to a static input and output data set of SASEP.IN and SASEP.OUT rather than binding to a score definition. This is deprecated. Please use the endpoint /flows/{decisionId}/revisions/{revisionId}/mappedCode with header Content-Type as application/vnd.sas.score.code.generation.request.unbound+json and header Accept as text/vnd.sas.source.ds2.

    Body parameter

    Score code generation request unbound.

    {
      "mappings": [
        {
          "mappingType": "static",
          "mappingValue": 25,
          "variableName": "a"
        }
      ],
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    revisionId path string true Identifier for the revision.
    body body #/paths/~1flows~1%7BdecisionId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request.unbound%2Bjson/schema false none

    Example responses

    Code generated from decision flow.

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get analysis code for decision revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/analysisCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.analysis.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.analysis.code+json'
    
    
    const inputBody = '{
      "scoreExecutionId": "fc6e491b-fc28-49b7-9d6b-2f82af24ada9",
      "analysisType": "decisionPathFrequency",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept':'application/vnd.sas.score.analysis.code+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/analysisCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.analysis.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.analysis.code+json'
    }
    
    r = requests.post('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/analysisCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.analysis.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.analysis.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/analysisCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /flows/{decisionId}/revisions/{revisionId}/analysisCode

    Retrieves the analysis code that is required for the collection rule fired or path tracking information for the decision revision.

    Body parameter

    Analysis code generation request.

    {
      "scoreExecutionId": "fc6e491b-fc28-49b7-9d6b-2f82af24ada9",
      "analysisType": "decisionPathFrequency",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    decisionId path string true Identifier for the decision.
    revisionId path string true Identifier for the revision.
    body body #/paths/~1flows~1%7BdecisionId%7D~1analysisCode/post/requestBody/content/application~1vnd.sas.score.analysis.code.generation.request%2Bjson/schema true Analysis request information including the type and name of the analysis that is being performed.

    Example responses

    Generated analysis code for decision flow.

    {
      "code": "loadActionSet \"simple\";\nloadActionSet \"ds2\";\n\naction simple.freq /\n    casOut={name='add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path' caslib='Public' replace=TRUE}\n    table={name='add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_output' caslib='Public' vars={{name='PathID'}} };\n\naction runDs2 / program = 'data\n\"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path\"(overwrite=yes\nrename=( _charvar_=PathID _frequency_=Count) keep=(PathID Count));\n                               method run();\n                                   set \"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path\";\n                               end;\n                           enddata;';\n",
      "codeType": "application/json",
      "outputTableName": "add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path",
      "outputLibraryName": "Public",
      "version": 1
    }
    
    {
      "code": "loadActionSet \"simple\";\nloadActionSet \"ds2\";\n\naction simple.freq /\n    casOut={name='add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path' caslib='Public' replace=TRUE}\n    table={name='add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_output' caslib='Public' vars={{name='PathID'}} };\n\naction runDs2 / program = 'data\n\"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path\"(overwrite=yes\nrename=( _charvar_=PathID _frequency_=Count) keep=(PathID Count));\n                               method run();\n                                   set \"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path\";\n                               end;\n                           enddata;';\n",
      "codeType": "application/json",
      "outputTableName": "add_cf_Scenario_1_add_cf_2021-05-07_00-50-22_path",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 200

    Analysis Code

    Name Type Required Restrictions Description
    » code string true none Executable code generated by a Score Object.
    » codeType string(media-type) true none Type of the code.
    » outputTableName string true none Name of the table that will be generated when the generated code is executed.
    » outputLibraryName string true none Name of the library where the table will be generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 1.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get decision revision step code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/decisionStepCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision.step.code+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision.step.code+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/decisionStepCode',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision.step.code+json'
    }
    
    r = requests.get('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/decisionStepCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision.step.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/decisionStepCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows/{decisionId}/revisions/{revisionId}/decisionStepCode

    Returns the decision step code for the specified decision revision.

    Parameters
    Name In Type Required Description
    decisionId path string true The identifier for the decision.
    revisionId path string true The identifier for the revision.

    Example responses

    Decision step code generated from decision flow revision.

    {
      "creationTimeStamp": "2021-05-07T16:06:05.631Z",
      "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "77cfc1c3-f050-4169-939a-941e7c664215",
      "type": "decision",
      "name": "add_dec",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "decision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        }
      ],
      "version": 1
    }
    
    {
      "creationTimeStamp": "2021-05-07T16:06:05.631Z",
      "modifiedTimeStamp": "2021-05-07T16:06:22.755Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "77cfc1c3-f050-4169-939a-941e7c664215",
      "type": "decision",
      "name": "add_dec",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "type": "application/vnd.sas.decision"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215"
        },
        {
          "method": "GET",
          "rel": "code",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/code",
          "type": "text/vnd.sas.source.ds2"
        },
        {
          "method": "POST",
          "rel": "mappedCode",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/mappedCode",
          "type": "application/vnd.sas.score.code.generation.request",
          "responseType": "application/vnd.sas.score.mapped.code"
        },
        {
          "method": "GET",
          "rel": "externalArtifacts",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "decision",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3",
          "type": "application/vnd.sas.decision"
        }
      ],
      "version": 1
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No decision exists at the requested path. Inline
    Response Schema

    Status Code 200

    Decision Step Code

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string false none The name of the object used in decision step.
    » description string false none The description of the object used in decision step.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » code string false none The code of the object used in the decision step.
    » type string false none The object type of the object used in the decision step.
    » signature [any] false none Signature variables of the object used in the decision step.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get list of external artifacts for decision revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/externalArtifacts \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.decision.external.artifact+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.decision.external.artifact+json'
    };
    
    fetch('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/externalArtifacts',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.decision.external.artifact+json'
    }
    
    r = requests.get('https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/externalArtifacts', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.decision.external.artifact+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/flows/{decisionId}/revisions/{revisionId}/externalArtifacts", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /flows/{decisionId}/revisions/{revisionId}/externalArtifacts

    Returns the list of external artifacts used by a decision revision. Objects used by a step of the steps collection in a decision flow are considered external artifacts. Some examples of such objects are files and web services. This endpoint returns the collection of external artifacts. The collection might be empty if there is no external artifact used by any step of the decision. The expected number of external artifacts is small. Therefore, this endpoint does not support any paging, filtering, or sorting of parameters.

    Parameters
    Name In Type Required Description
    decisionId path string true Id of the decision.
    revisionId path string true Id of the revision.
    Accept-Item header string false Used for selecting desired item representation.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.decision.external.artifact+json

    Example responses

    External artifacts related to decision flow revision.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/",
          "type": "application/vnd.sas.decision"
        }
      ],
      "name": "externalArtifacts",
      "accept": "application/vnd.sas.decision.external.artifact",
      "count": 0,
      "items": [],
      "version": 2
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/externalArtifacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.external.artifact"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/",
          "uri": "/decisions/flows/e2cf4209-2661-4ef1-b77f-10b91a6420e3/revisions/77cfc1c3-f050-4169-939a-941e7c664215/",
          "type": "application/vnd.sas.decision"
        }
      ],
      "name": "externalArtifacts",
      "accept": "application/vnd.sas.decision.external.artifact",
      "count": 0,
      "items": [],
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. externalArtifactsCollection
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    CodeFiles

    Contains operations for code files.

    Get a collection of code files

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/codeFiles \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.decision.code.file+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.decision.code.file+json'
    };
    
    fetch('https://example.com/decisions/codeFiles',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.decision.code.file+json'
    }
    
    r = requests.get('https://example.com/decisions/codeFiles', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.decision.code.file+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/codeFiles", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /codeFiles

    Returns a collection of code files based on the specified pagination, filtering, and sorting options. The items in the collection, depend on the Accept-Item header.

    Parameters
    Name In Type Required Description
    Accept-Item header string(media-type) false Used for selecting desired item representation.
    start query integer(int64) false The index of the first code file to return.
    limit query integer(int32) false The maximum number of code files to return.
    filter query string(filter-criteria) false The criteria for filtering the code files. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the code files. See Sorting in REST APIs.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.decision.code.file+json
    Accept-Item application/vnd.sas.summary+json

    Example responses

    Decision code files with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles?sortBy=name&start=1&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/codeFiles?sortBy=name&start=2&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        }
      ],
      "name": "codeFiles",
      "accept": "application/vnd.sas.summary",
      "start": 1,
      "count": 4,
      "items": [
        {
          "creationTimeStamp": "2021-05-06T20:21:04.420Z",
          "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "decisionDS2CodeFile",
          "name": "add_cf",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles",
              "uri": "/decisions/codeFiles",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
              "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Decision code files with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles?sortBy=name&start=1&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/codeFiles?sortBy=name&start=2&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        }
      ],
      "name": "codeFiles",
      "accept": "application/vnd.sas.decision.code.file",
      "start": 1,
      "count": 4,
      "items": [
        {
          "creationTimeStamp": "2021-05-06T20:21:04.420Z",
          "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "cd404a82-af5b-4835-9672-9730470a6be8",
          "name": "add_cf",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "type": "decisionDS2CodeFile",
          "signature": [
            {
              "name": "a",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "b",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "c",
              "dataType": "decimal",
              "direction": "inOut"
            }
          ],
          "status": "valid",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles",
              "uri": "/decisions/codeFiles",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
              "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
            }
          ],
          "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
          "copyTimeStamp": "2021-05-06T20:21:04.490Z",
          "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Decision code files with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles?sortBy=name&start=1&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/codeFiles?sortBy=name&start=2&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        }
      ],
      "name": "codeFiles",
      "accept": "application/vnd.sas.summary",
      "start": 1,
      "count": 4,
      "items": [
        {
          "creationTimeStamp": "2021-05-06T20:21:04.420Z",
          "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "decisionDS2CodeFile",
          "name": "add_cf",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles",
              "uri": "/decisions/codeFiles",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
              "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Decision code files with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles?sortBy=name&start=1&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/decisions/codeFiles?sortBy=name&start=2&limit=1",
          "uri": "/decisions/codeFiles?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        }
      ],
      "name": "codeFiles",
      "accept": "application/vnd.sas.decision.code.file",
      "start": 1,
      "count": 4,
      "items": [
        {
          "creationTimeStamp": "2021-05-06T20:21:04.420Z",
          "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "cd404a82-af5b-4835-9672-9730470a6be8",
          "name": "add_cf",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "type": "decisionDS2CodeFile",
          "signature": [
            {
              "name": "a",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "b",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "c",
              "dataType": "decimal",
              "direction": "inOut"
            }
          ],
          "status": "valid",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles",
              "uri": "/decisions/codeFiles",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
              "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
            }
          ],
          "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
          "copyTimeStamp": "2021-05-06T20:21:04.490Z",
          "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema
    Enumerated Values
    Property Value
    type decisionDS2CodeFile
    type decisionSQLCodeFile
    type decisionPythonFile
    status valid
    status error
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    direction input
    direction inOut
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a code file

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/codeFiles \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.code.file+json' \
      -H 'Accept: application/vnd.sas.decision.code.file+json'
    
    
    const inputBody = '{
      "name": "add_cf",
      "type": "decisionDS2CodeFile",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.code.file+json',
      'Accept':'application/vnd.sas.decision.code.file+json'
    };
    
    fetch('https://example.com/decisions/codeFiles',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.code.file+json',
      'Accept': 'application/vnd.sas.decision.code.file+json'
    }
    
    r = requests.post('https://example.com/decisions/codeFiles', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.code.file+json"},
            "Accept": []string{"application/vnd.sas.decision.code.file+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/codeFiles", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /codeFiles

    Creates a new code file based on the representation in the request body.

    Body parameter

    Creating or updating a decision code file.

    {
      "name": "add_cf",
      "type": "decisionDS2CodeFile",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9"
    }
    
    Parameters
    Name In Type Required Description
    parentFolderUri query string(/folders/folders/{parentFolderId}) false The folder where the target code file is located.
    fromRevisionUri query string(/decisions/codeFiles/{codeFileId}/revisions/{revisionId}) false This value specifies the URI of the code file revision from which the new code file is created. This property enables you to trace the lineage of a code file. The valid format for this parameter is '/decisions/codeFiles/${codeFileId}/revisions/${revisionId}'
    body body codeFileCollection true Code file details that needs to be created.

    Example responses

    Decision code file with full details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    
    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A code file was created. codeFileCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Location string The URL of the code file.
    201 ETag string The entity tag for the code file.
    201 Last-Modified string The timestamp in EEE, dd MMM yyyy HH:mm:ss GMT format when the code file was last modified.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get a code file

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/codeFiles/{codeFileId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision.code.file+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision.code.file+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision.code.file+json'
    }
    
    r = requests.get('https://example.com/decisions/codeFiles/{codeFileId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision.code.file+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/codeFiles/{codeFileId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /codeFiles/{codeFileId}

    Returns the representation of the specified code file.

    Parameters
    Name In Type Required Description
    codeFileId path string true The unique identifier for the code file.

    Example responses

    Decision code file with full details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    

    Decision code file with resource summary details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "type": "decisionDS2CodeFile",
      "name": "add_cf",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 2
    }
    

    Decision code file with full details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. codeFileCollection
    404 Not Found No code file exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the code file.
    200 Last-Modified string The timestamp in EEE, dd MMM yyyy HH:mm:ss GMT format when the code file was last modified.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Update a code file

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/decisions/codeFiles/{codeFileId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.code.file+json' \
      -H 'Accept: application/vnd.sas.decision.code.file+json' \
      -H 'If-Match: "kknyjgku"'
    
    
    const inputBody = '{
      "name": "add_cf",
      "type": "decisionDS2CodeFile",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.code.file+json',
      'Accept':'application/vnd.sas.decision.code.file+json',
      'If-Match':'"kknyjgku"'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.code.file+json',
      'Accept': 'application/vnd.sas.decision.code.file+json',
      'If-Match': '"kknyjgku"'
    }
    
    r = requests.put('https://example.com/decisions/codeFiles/{codeFileId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.code.file+json"},
            "Accept": []string{"application/vnd.sas.decision.code.file+json"},
            "If-Match": []string{""kknyjgku""},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/decisions/codeFiles/{codeFileId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /codeFiles/{codeFileId}

    Updates a code file based on the representation in the request body. Only the name and description of a code file can be updated with this operation.

    Body parameter

    Creating or updating a decision code file.

    {
      "name": "add_cf",
      "type": "decisionDS2CodeFile",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9"
    }
    
    Parameters
    Name In Type Required Description
    codeFileId path string true The identifier for the decision.
    If-Match header string true Etag value from when the originating object was retrieved.
    body body codeFileCollection true The unique identifier for the code file.

    Example responses

    Decision code file with full details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    
    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The code file was updated. codeFileCollection
    400 Bad Request The request was invalid. errorResponse
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the code file.
    200 Last-Modified string The timestamp in EEE, dd MMM yyyy HH:mm:ss GMT format when the code file was last modified.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    412 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    428 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a code file

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/decisions/codeFiles/{codeFileId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/decisions/codeFiles/{codeFileId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/decisions/codeFiles/{codeFileId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /codeFiles/{codeFileId}

    Deletes the specified code file.

    Parameters
    Name In Type Required Description
    codeFileId path string true The unique identifier for the code file.
    Responses
    Status Meaning Description Schema
    204 No Content The code file was deleted. None
    Response Headers
    Status Header Type Format Description
    204 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the summary for a code file

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/codeFiles/{codeFileId}#summary \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}#summary',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/decisions/codeFiles/{codeFileId}#summary', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/codeFiles/{codeFileId}#summary", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /codeFiles/{codeFileId}#summary

    Returns the summary representation of the specified code file. This is deprecated. Use endpoint /codeFiles/{codeFileId} with Accept header as application/vnd.sas.summary+json.

    Parameters
    Name In Type Required Description
    codeFileId path string true The unique identifier for the code file.

    Example responses

    Decision code file with resource summary details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "type": "decisionDS2CodeFile",
      "name": "add_cf",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. resourceSummaryCollection/allOf/1/properties/items/items
    404 Not Found No code file exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the code file.
    200 Last-Modified string The timestamp in EEE, dd MMM yyyy HH:mm:ss GMT format when the code file was last modified.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the mapped code for a code file

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/codeFiles/{codeFileId}/mappedCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "scoreDefinitionId": "2d7d079d-963f-4c5e-a920-262accd4eb9e",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}/mappedCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/decisions/codeFiles/{codeFileId}/mappedCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/codeFiles/{codeFileId}/mappedCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /codeFiles/{codeFileId}/mappedCode

    Returns the code to be able to run the code file based on the provided data and mapping information in the request.

    Body parameter

    Score code generation request.

    {
      "scoreDefinitionId": "2d7d079d-963f-4c5e-a920-262accd4eb9e",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    codeFileId path string true The code file ID.
    body body #/paths/~1flows~1%7BdecisionId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request%2Bjson/schema true The information for the scoreDefinitionId and hints.

    Example responses

    Decision code file mapped code.

    {
      "code": "/*{\"signatureExtension\":[]}*/\n\npackage CODE_FILE_SCORE /inline;\n\n\n/*end custom function code */\n\nmethod execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n\n\nthread score_codefile_execution_thread ;\n\n     dcl package CODE_FILE_SCORE codefiletest();\n     dcl double \"c\";\n\n     dcl double \"a\";\n     dcl double \"b\";\n\n    dcl double \"a\";\n    dcl double \"b\";\n\n     keep \"c\";\n     method run();\n\n         dcl int localRC;\n\n         set \"Public\".\"DUAL\" (\n\n         );\n\n         \"a\" = 2;\n         \"b\" = 3;\n\n         codefiletest.execute(\n                \"a\"\n              , \"b\"\n              , \"c\"\n         );\n\n         output;\n     end;\nendthread;\n\n\ndata \"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-51-51_output\"\n(overwrite=yes);\n\n    dcl thread score_codefile_execution_thread _t;\n    method run();\n        set from _t threads=4;\n        output;\n    end;\nenddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_cf_Scenario_1_add_cf_2021-05-07_00-51-51_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    
    {
      "code": "/*{\"signatureExtension\":[]}*/\n\npackage CODE_FILE_SCORE /inline;\n\n\n/*end custom function code */\n\nmethod execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n\n\nthread score_codefile_execution_thread ;\n\n     dcl package CODE_FILE_SCORE codefiletest();\n     dcl double \"c\";\n\n     dcl double \"a\";\n     dcl double \"b\";\n\n    dcl double \"a\";\n    dcl double \"b\";\n\n     keep \"c\";\n     method run();\n\n         dcl int localRC;\n\n         set \"Public\".\"DUAL\" (\n\n         );\n\n         \"a\" = 2;\n         \"b\" = 3;\n\n         codefiletest.execute(\n                \"a\"\n              , \"b\"\n              , \"c\"\n         );\n\n         output;\n     end;\nendthread;\n\n\ndata \"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-51-51_output\"\n(overwrite=yes);\n\n    dcl thread score_codefile_execution_thread _t;\n    method run();\n        set from _t threads=4;\n        output;\n    end;\nenddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_cf_Scenario_1_add_cf_2021-05-07_00-51-51_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 2.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the decision step code for a code file

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/codeFiles/{codeFileId}/decisionStepCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision.step.code+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision.step.code+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}/decisionStepCode',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision.step.code+json'
    }
    
    r = requests.get('https://example.com/decisions/codeFiles/{codeFileId}/decisionStepCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision.step.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/codeFiles/{codeFileId}/decisionStepCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /codeFiles/{codeFileId}/decisionStepCode

    Returns the decision step code for the specified code file.

    Parameters
    Name In Type Required Description
    codeFileId path string true The code file ID.

    Example responses

    Decision code file with decision step code details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "type": "decisionDS2CodeFile",
      "name": "add_cf",
      "code": "/*{\"signatureExtension\":[]}*/\npackage \"${PACKAGE_NAME}\" /inline;\n   method execute(double a, double b, in_out double c);\n        c=a+b;\n   end;\nendpackage;\n",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 1
    }
    
    {
      "creationTimeStamp": "2021-05-06T20:21:04.420Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.882Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "cd404a82-af5b-4835-9672-9730470a6be8",
      "type": "decisionDS2CodeFile",
      "name": "add_cf",
      "code": "/*{\"signatureExtension\":[]}*/\npackage \"${PACKAGE_NAME}\" /inline;\n   method execute(double a, double b, in_out double c);\n        c=a+b;\n   end;\nendpackage;\n",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 1
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No code file exists at the requested path. Inline
    Response Schema

    Status Code 200

    Decision Step Code

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string false none The name of the object used in decision step.
    » description string false none The description of the object used in decision step.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » code string false none The code of the object used in the decision step.
    » type string false none The object type of the object used in the decision step.
    » signature [any] false none Signature variables of the object used in the decision step.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    CodeFileRevisions

    Contains operations for code file revisions.

    Get a collection of revisions of a code file

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/codeFiles/{codeFileId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.decision.code.file+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.decision.code.file+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}/revisions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.decision.code.file+json'
    }
    
    r = requests.get('https://example.com/decisions/codeFiles/{codeFileId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.decision.code.file+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/codeFiles/{codeFileId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /codeFiles/{codeFileId}/revisions

    Returns a collection of code file revisions based on the specified pagination, filtering, and sorting options. The items in the collection, depend on the Accept-Item header.

    Parameters
    Name In Type Required Description
    codeFileId path string true The unique identifier for the code file.
    Accept-Item header string(media-type) false Used for selecting desired item representation.
    start query integer(int64) false The index of the first code file to return.
    limit query integer(int32) false The maximum number of code files to return.
    filter query string(filter-criteria) false The criteria for filtering the code files. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the code files. See Sorting in REST APIs.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.decision.code.file+json
    Accept-Item application/vnd.sas.summary+json

    Example responses

    Decision code file revisions with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=3&limit=20",
          "uri": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=3&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=0&limit=20",
          "uri": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=0&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        }
      ],
      "name": "codeFiles",
      "accept": "application/vnd.sas.summary",
      "start": 3,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-05-06T21:36:42.228Z",
          "modifiedTimeStamp": "2021-05-06T21:36:42.228Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "a956c407-8086-414f-984e-0c20d5de71bc",
          "type": "decisionDS2CodeFile",
          "name": "add_cf",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b/content",
              "uri": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc"
            }
          ],
          "version": 2
        },
        {
          "creationTimeStamp": "2021-05-06T21:37:00.131Z",
          "modifiedTimeStamp": "2021-05-06T21:37:00.131Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "66c99a48-0903-44ea-948f-7c711fde4291",
          "type": "decisionDS2CodeFile",
          "name": "add_cf",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1/content",
              "uri": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291"
            }
          ],
          "version": 2
        }
      ],
      "limit": 20,
      "version": 2
    }
    

    Decision code file revisions with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=3&limit=20",
          "uri": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=3&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=0&limit=20",
          "uri": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=0&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        }
      ],
      "name": "codeFiles",
      "accept": "application/vnd.sas.summary",
      "start": 3,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-05-06T21:36:42.228Z",
          "modifiedTimeStamp": "2021-05-06T21:36:42.228Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "a956c407-8086-414f-984e-0c20d5de71bc",
          "name": "add_cf",
          "majorRevision": 1,
          "minorRevision": 3,
          "locked": true,
          "type": "decisionDS2CodeFile",
          "signature": [
            {
              "name": "a",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "b",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "c",
              "dataType": "decimal",
              "direction": "inOut"
            }
          ],
          "status": "valid",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b/content",
              "uri": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc"
            }
          ],
          "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
          "copyTimeStamp": "2021-05-06T21:36:42.228Z",
          "fileUri": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b",
          "version": 2
        },
        {
          "creationTimeStamp": "2021-05-06T21:37:00.131Z",
          "modifiedTimeStamp": "2021-05-06T21:37:00.131Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "66c99a48-0903-44ea-948f-7c711fde4291",
          "name": "add_cf",
          "majorRevision": 1,
          "minorRevision": 4,
          "locked": false,
          "type": "decisionDS2CodeFile",
          "signature": [
            {
              "name": "a",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "b",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "c",
              "dataType": "decimal",
              "direction": "output"
            }
          ],
          "status": "valid",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1/content",
              "uri": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291"
            }
          ],
          "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
          "copyTimeStamp": "2021-05-06T21:37:00.131Z",
          "fileUri": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1",
          "version": 2
        }
      ],
      "limit": 20,
      "version": 2
    }
    

    Decision code file revisions with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=3&limit=20",
          "uri": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=3&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=0&limit=20",
          "uri": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=0&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        }
      ],
      "name": "codeFiles",
      "accept": "application/vnd.sas.summary",
      "start": 3,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-05-06T21:36:42.228Z",
          "modifiedTimeStamp": "2021-05-06T21:36:42.228Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "a956c407-8086-414f-984e-0c20d5de71bc",
          "type": "decisionDS2CodeFile",
          "name": "add_cf",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b/content",
              "uri": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc"
            }
          ],
          "version": 2
        },
        {
          "creationTimeStamp": "2021-05-06T21:37:00.131Z",
          "modifiedTimeStamp": "2021-05-06T21:37:00.131Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "66c99a48-0903-44ea-948f-7c711fde4291",
          "type": "decisionDS2CodeFile",
          "name": "add_cf",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1/content",
              "uri": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291"
            }
          ],
          "version": 2
        }
      ],
      "limit": 20,
      "version": 2
    }
    

    Decision code file revisions with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=3&limit=20",
          "uri": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=3&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=0&limit=20",
          "uri": "/decisions/codeFiles?filter=eq(codeFileId,'cd404a82-af5b-4835-9672-9730470a6be8')&start=0&limit=20",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/decisions/codeFiles",
          "uri": "/decisions/codeFiles",
          "type": "application/vnd.sas.decision.code.file",
          "responseType": "application/vnd.sas.decision.code.file"
        }
      ],
      "name": "codeFiles",
      "accept": "application/vnd.sas.summary",
      "start": 3,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-05-06T21:36:42.228Z",
          "modifiedTimeStamp": "2021-05-06T21:36:42.228Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "a956c407-8086-414f-984e-0c20d5de71bc",
          "name": "add_cf",
          "majorRevision": 1,
          "minorRevision": 3,
          "locked": true,
          "type": "decisionDS2CodeFile",
          "signature": [
            {
              "name": "a",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "b",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "c",
              "dataType": "decimal",
              "direction": "inOut"
            }
          ],
          "status": "valid",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b/content",
              "uri": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/a956c407-8086-414f-984e-0c20d5de71bc"
            }
          ],
          "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
          "copyTimeStamp": "2021-05-06T21:36:42.228Z",
          "fileUri": "/files/files/cccfa23a-6943-42eb-8743-aa5d3ff0db9b",
          "version": 2
        },
        {
          "creationTimeStamp": "2021-05-06T21:37:00.131Z",
          "modifiedTimeStamp": "2021-05-06T21:37:00.131Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "66c99a48-0903-44ea-948f-7c711fde4291",
          "name": "add_cf",
          "majorRevision": 1,
          "minorRevision": 4,
          "locked": false,
          "type": "decisionDS2CodeFile",
          "signature": [
            {
              "name": "a",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "b",
              "dataType": "decimal",
              "direction": "input"
            },
            {
              "name": "c",
              "dataType": "decimal",
              "direction": "output"
            }
          ],
          "status": "valid",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.code.file"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1/content",
              "uri": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1/content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "type": "application/vnd.sas.decision.step.code"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291",
              "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/66c99a48-0903-44ea-948f-7c711fde4291"
            }
          ],
          "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
          "copyTimeStamp": "2021-05-06T21:37:00.131Z",
          "fileUri": "/files/files/7916329a-4e35-4d3c-b865-de42eddc3bb1",
          "version": 2
        }
      ],
      "limit": 20,
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema
    Enumerated Values
    Property Value
    type decisionDS2CodeFile
    type decisionSQLCodeFile
    type decisionPythonFile
    status valid
    status error
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    direction input
    direction inOut
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a code file revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/codeFiles/{codeFileId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.code.file+json' \
      -H 'Accept: application/vnd.sas.decision.code.file+json'
    
    
    const inputBody = '{
      "name": "add_cf",
      "type": "decisionDS2CodeFile",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.code.file+json',
      'Accept':'application/vnd.sas.decision.code.file+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}/revisions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.code.file+json',
      'Accept': 'application/vnd.sas.decision.code.file+json'
    }
    
    r = requests.post('https://example.com/decisions/codeFiles/{codeFileId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.code.file+json"},
            "Accept": []string{"application/vnd.sas.decision.code.file+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/codeFiles/{codeFileId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /codeFiles/{codeFileId}/revisions

    Creates a new code file revision based on the representation in the request body.

    Body parameter

    Creating or updating a decision code file.

    {
      "name": "add_cf",
      "type": "decisionDS2CodeFile",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9"
    }
    
    Parameters
    Name In Type Required Description
    codeFileId path string true The unique identifier for the code file.
    revisionType query string false 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 code file 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.
    fromRevisionUri query string(/decisions/codeFiles/{codeFileId}/revisions/{revisionId}) false This value specifies the URI of the code file revision from which the new code file revision is created. This property enables you to trace the lineage of a code file. The valid format for this parameter is '/decisions/codeFiles/${codeFileId}/revisions/${revisionId}'
    body body codeFileCollection true Code file revision details that needs to be created.
    Enumerated Values
    Parameter Value
    revisionType major
    revisionType minor

    Example responses

    Decision code file revision with full details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.490Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.490Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "f02aa26d-af06-4198-9705-2306bad711a1",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    
    {
      "creationTimeStamp": "2021-05-06T20:21:04.490Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.490Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "f02aa26d-af06-4198-9705-2306bad711a1",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A code file revision was created. codeFileCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Location string The URL of the code file revision.
    201 ETag string The entity tag for the code file revision.
    201 Last-Modified string The timestamp in EEE, dd MMM yyyy HH:mm:ss GMT format when the code file revision was last modified.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get a code file revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision.code.file+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision.code.file+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision.code.file+json'
    }
    
    r = requests.get('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision.code.file+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /codeFiles/{codeFileId}/revisions/{revisionId}

    Returns the representation of the specified code file revision.

    Parameters
    Name In Type Required Description
    codeFileId path string true The unique identifier for the code file.
    revisionId path string true The unique identifier for the code file revision.

    Example responses

    Decision code file revision with full details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.490Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.490Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "f02aa26d-af06-4198-9705-2306bad711a1",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    

    Decision code file revision with ressource summary details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.490Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.490Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "f02aa26d-af06-4198-9705-2306bad711a1",
      "type": "decisionDS2CodeFile",
      "name": "add_cf",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1"
        }
      ],
      "version": 2
    }
    

    Decision code file revision with full details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.490Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.490Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "f02aa26d-af06-4198-9705-2306bad711a1",
      "name": "add_cf",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "type": "decisionDS2CodeFile",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "inOut"
        }
      ],
      "status": "valid",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1"
        }
      ],
      "sourceRevisionUri": "/decisions/codeFiles/57d3b887-472b-4bd5-a021-b6f336efed41/revisions/200b0999-08ae-4371-a06c-f08d8c246f64",
      "copyTimeStamp": "2021-05-06T20:21:04.490Z",
      "fileUri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9",
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. codeFileCollection
    404 Not Found No code file revision exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the code file revision.
    200 Last-Modified string The timestamp in EEE, dd MMM yyyy HH:mm:ss GMT format when the code file revision was last modified.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a code file revision

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /codeFiles/{codeFileId}/revisions/{revisionId}

    Deletes the specified code file revision.

    Parameters
    Name In Type Required Description
    codeFileId path string true The unique identifier for the code file.
    revisionId path string true The unique identifier for the code file revision.
    Responses
    Status Meaning Description Schema
    204 No Content The code file revision was deleted. None
    Response Headers
    Status Header Type Format Description
    204 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the summary for a code file revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}#summary \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}#summary',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}#summary', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}#summary", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /codeFiles/{codeFileId}/revisions/{revisionId}#summary

    Returns the summary representation of the specified code file revision. This is deprecated. Please use endpoint /codeFiles/{codeFileId}/revisions/{revisionId} with Accept header application/vnd.sas.summary+json.

    Parameters
    Name In Type Required Description
    codeFileId path string true The unique identifier for the code file.
    revisionId path string true The unique identifier for the code file revision.

    Example responses

    Decision code file revision with ressource summary details.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.490Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.490Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "f02aa26d-af06-4198-9705-2306bad711a1",
      "type": "decisionDS2CodeFile",
      "name": "add_cf",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1"
        }
      ],
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. resourceSummaryCollection/allOf/1/properties/items/items
    404 Not Found No code file revision exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the code file revision.
    200 Last-Modified string The timestamp in EEE, dd MMM yyyy HH:mm:ss GMT format when the code file revision was last modified.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the mapped code of a code file revision

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}/mappedCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.score.code.generation.request+json' \
      -H 'Accept: application/vnd.sas.score.mapped.code+json'
    
    
    const inputBody = '{
      "scoreDefinitionId": "2d7d079d-963f-4c5e-a920-262accd4eb9e",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.score.code.generation.request+json',
      'Accept':'application/vnd.sas.score.mapped.code+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}/mappedCode',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.score.code.generation.request+json',
      'Accept': 'application/vnd.sas.score.mapped.code+json'
    }
    
    r = requests.post('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}/mappedCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.score.code.generation.request+json"},
            "Accept": []string{"application/vnd.sas.score.mapped.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}/mappedCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /codeFiles/{codeFileId}/revisions/{revisionId}/mappedCode

    Returns the code to be able to run the code file based on the provided data and mapping information in the request.

    Body parameter

    Score code generation request.

    {
      "scoreDefinitionId": "2d7d079d-963f-4c5e-a920-262accd4eb9e",
      "hints": {
        "tableBaseName": "add_test_"
      }
    }
    
    Parameters
    Name In Type Required Description
    codeFileId path string true The code file ID.
    revisionId path string true The code file revision ID.
    body body #/paths/~1flows~1%7BdecisionId%7D~1mappedCode/post/requestBody/content/application~1vnd.sas.score.code.generation.request%2Bjson/schema true The information for the scoreDefinitionId and hints.

    Example responses

    Decision code file mapped code.

    {
      "code": "/*{\"signatureExtension\":[]}*/\n\npackage CODE_FILE_SCORE /inline;\n\n\n/*end custom function code */\n\nmethod execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n\n\nthread score_codefile_execution_thread ;\n\n     dcl package CODE_FILE_SCORE codefiletest();\n     dcl double \"c\";\n\n     dcl double \"a\";\n     dcl double \"b\";\n\n    dcl double \"a\";\n    dcl double \"b\";\n\n     keep \"c\";\n     method run();\n\n         dcl int localRC;\n\n         set \"Public\".\"DUAL\" (\n\n         );\n\n         \"a\" = 2;\n         \"b\" = 3;\n\n         codefiletest.execute(\n                \"a\"\n              , \"b\"\n              , \"c\"\n         );\n\n         output;\n     end;\nendthread;\n\n\ndata \"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-51-51_output\"\n(overwrite=yes);\n\n    dcl thread score_codefile_execution_thread _t;\n    method run();\n        set from _t threads=4;\n        output;\n    end;\nenddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_cf_Scenario_1_add_cf_2021-05-07_00-51-51_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    
    {
      "code": "/*{\"signatureExtension\":[]}*/\n\npackage CODE_FILE_SCORE /inline;\n\n\n/*end custom function code */\n\nmethod execute(double a, double b, in_out double c);\n    c=a+b;\n   end;\nendpackage;\n\n\nthread score_codefile_execution_thread ;\n\n     dcl package CODE_FILE_SCORE codefiletest();\n     dcl double \"c\";\n\n     dcl double \"a\";\n     dcl double \"b\";\n\n    dcl double \"a\";\n    dcl double \"b\";\n\n     keep \"c\";\n     method run();\n\n         dcl int localRC;\n\n         set \"Public\".\"DUAL\" (\n\n         );\n\n         \"a\" = 2;\n         \"b\" = 3;\n\n         codefiletest.execute(\n                \"a\"\n              , \"b\"\n              , \"c\"\n         );\n\n         output;\n     end;\nendthread;\n\n\ndata \"Public\".\"add_cf_Scenario_1_add_cf_2021-05-07_00-51-51_output\"\n(overwrite=yes);\n\n    dcl thread score_codefile_execution_thread _t;\n    method run();\n        set from _t threads=4;\n        output;\n    end;\nenddata;\n",
      "codeType": "text/vnd.sas.source.ds2",
      "outputTableName": "add_cf_Scenario_1_add_cf_2021-05-07_00-51-51_output",
      "outputLibraryName": "Public",
      "version": 1
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 200

    Mapped Code

    Name Type Required Restrictions Description
    » code string true none The executable code generated by a score object.
    » codeType string(media-type) true none The type of code.
    » outputTableName string true none The name of the table that is generated when the code is executed.
    » outputLibraryName string true none The name of the library where the table is generated when the code is executed.
    » version integer false none This media type's schema version number. This representation is version 2.

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get the decision step code for a code file revision

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}/decisionStepCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision.step.code+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision.step.code+json'
    };
    
    fetch('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}/decisionStepCode',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision.step.code+json'
    }
    
    r = requests.get('https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}/decisionStepCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision.step.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/codeFiles/{codeFileId}/revisions/{revisionId}/decisionStepCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /codeFiles/{codeFileId}/revisions/{revisionId}/decisionStepCode

    Returns the decision step code for the specified code file revision.

    Parameters
    Name In Type Required Description
    codeFileId path string true The code file ID.
    revisionId path string true The code file revision ID.

    Example responses

    Decision code file revision as decision step code.

    {
      "creationTimeStamp": "2021-05-06T20:21:04.490Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.490Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "f02aa26d-af06-4198-9705-2306bad711a1",
      "type": "decisionDS2CodeFile",
      "name": "add_cf",
      "code": "/*{\"signatureExtension\":[]}*/\npackage \"${PACKAGE_NAME}\" /inline;\n   method execute(double a, double b, in_out double c);\n        c=a+b;\n   end;\nendpackage;\n",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1"
        }
      ],
      "version": 1
    }
    
    {
      "creationTimeStamp": "2021-05-06T20:21:04.490Z",
      "modifiedTimeStamp": "2021-05-06T20:21:04.490Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "f02aa26d-af06-4198-9705-2306bad711a1",
      "type": "decisionDS2CodeFile",
      "name": "add_cf",
      "code": "/*{\"signatureExtension\":[]}*/\npackage \"${PACKAGE_NAME}\" /inline;\n   method execute(double a, double b, in_out double c);\n        c=a+b;\n   end;\nendpackage;\n",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.code.file"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content",
          "uri": "/files/files/2110f410-bb15-41d4-a0a5-e707fececfe9/content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "type": "application/vnd.sas.decision.step.code"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1",
          "uri": "/decisions/codeFiles/cd404a82-af5b-4835-9672-9730470a6be8/revisions/f02aa26d-af06-4198-9705-2306bad711a1"
        }
      ],
      "version": 1
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No code file exists at the requested path. Inline
    Response Schema

    Status Code 200

    Decision Step Code

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string false none The name of the object used in decision step.
    » description string false none The description of the object used in decision step.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » code string false none The code of the object used in the decision step.
    » type string false none The object type of the object used in the decision step.
    » signature [any] false none Signature variables of the object used in the decision step.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    DecisionNodeTypes

    Contains operations for decision node types.

    Get a list of all decision node types

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/decisionNodeTypes \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.decision.node.type+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.decision.node.type+json'
    };
    
    fetch('https://example.com/decisions/decisionNodeTypes',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.decision.node.type+json'
    }
    
    r = requests.get('https://example.com/decisions/decisionNodeTypes', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.decision.node.type+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/decisionNodeTypes", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /decisionNodeTypes

    Returns a resource collection of all decision node types.

    Parameters
    Name In Type Required Description
    filter query string(filter-criteria) false The criteria for filtering the decision node types. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the decision node types. See Sorting in REST APIs.
    start query integer false The starting index of the first item in a page. The index is 0-based. Default is 0.
    limit query integer false The maximum number of items to return in this page of results. The actual number of returned items might be less if the collection has been exhausted. The default limit is 10.
    Accept-Item header string false If provided, this should be an alternative media type that the service recognizes. If the media type is not one that the service can provide, a 406 response is returned.

    Example responses

    Decision node types with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/decisionNodeTypes",
          "uri": "/decisions/decisionNodeTypes",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/decisionNodeTypes?start=0&limit=1",
          "uri": "/decisions/decisionNodeTypes?start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/decisionNodeTypes?start=1&limit=1",
          "uri": "/decisions/decisionNodeTypes?start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes?start=2&limit=1",
          "uri": "/decisions/decisionNodeTypes?start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "createDecisionNodeType",
          "href": "/decisions/decisionNodeTypes",
          "uri": "/decisions/decisionNodeTypes",
          "type": "application/vnd.sas.decision.node.type",
          "responseType": "application/vnd.sas.decision.node.type"
        }
      ],
      "name": "decisionNodeTypes",
      "accept": "application/vnd.sas.decision.node.type",
      "start": 2,
      "count": 3,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T18:12:17.412Z",
          "modifiedTimeStamp": "2021-05-07T18:12:17.412Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "a86ded32-73bd-434d-9f89-29ba4a90c131",
          "name": "Demo Node Type 3",
          "hasProperties": false,
          "hasInputs": true,
          "hasOutputs": true,
          "inputDatagridMappable": false,
          "outputDatagridMappable": false,
          "inputDecisionTermMappable": true,
          "outputDecisionTermMappable": true,
          "independentMappings": false,
          "themeId": "DNT_THEME1",
          "type": "static",
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "responseType": "application/vnd.sas.decision.node.type"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "type": "application/vnd.sas.decision.node.type",
              "responseType": "application/vnd.sas.decision.node.type"
            },
            {
              "method": "POST",
              "rel": "setContent",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
              "type": "application/vnd.sas.decision.node.type.content",
              "responseType": "application/vnd.sas.decision.node.type.content"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
              "responseType": "application/vnd.sas.decision.node.type.content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
              "responseType": "application/vnd.sas.decision.step.code"
            }
          ]
        }
      ],
      "limit": 1,
      "version": 2
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/decisions/decisionNodeTypes",
          "uri": "/decisions/decisionNodeTypes",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/decisions/decisionNodeTypes?start=0&limit=1",
          "uri": "/decisions/decisionNodeTypes?start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/decisions/decisionNodeTypes?start=1&limit=1",
          "uri": "/decisions/decisionNodeTypes?start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes?start=2&limit=1",
          "uri": "/decisions/decisionNodeTypes?start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "createDecisionNodeType",
          "href": "/decisions/decisionNodeTypes",
          "uri": "/decisions/decisionNodeTypes",
          "type": "application/vnd.sas.decision.node.type",
          "responseType": "application/vnd.sas.decision.node.type"
        }
      ],
      "name": "decisionNodeTypes",
      "accept": "application/vnd.sas.decision.node.type",
      "start": 2,
      "count": 3,
      "items": [
        {
          "creationTimeStamp": "2021-05-07T18:12:17.412Z",
          "modifiedTimeStamp": "2021-05-07T18:12:17.412Z",
          "createdBy": "edmdev",
          "modifiedBy": "edmdev",
          "id": "a86ded32-73bd-434d-9f89-29ba4a90c131",
          "name": "Demo Node Type 3",
          "hasProperties": false,
          "hasInputs": true,
          "hasOutputs": true,
          "inputDatagridMappable": false,
          "outputDatagridMappable": false,
          "inputDecisionTermMappable": true,
          "outputDecisionTermMappable": true,
          "independentMappings": false,
          "themeId": "DNT_THEME1",
          "type": "static",
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "responseType": "application/vnd.sas.decision.node.type"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
              "type": "application/vnd.sas.decision.node.type",
              "responseType": "application/vnd.sas.decision.node.type"
            },
            {
              "method": "POST",
              "rel": "setContent",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
              "type": "application/vnd.sas.decision.node.type.content",
              "responseType": "application/vnd.sas.decision.node.type.content"
            },
            {
              "method": "GET",
              "rel": "content",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
              "responseType": "application/vnd.sas.decision.node.type.content"
            },
            {
              "method": "GET",
              "rel": "decisionStepCode",
              "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
              "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
              "responseType": "application/vnd.sas.decision.step.code"
            }
          ]
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Not acceptable.

    {
      "httpStatusCode": 406,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. decisionNodeTypeCollection
    406 Not Acceptable The request was not acceptable. An invalid media type was specified for the Accept-Item header value. Inline
    Response Schema

    Status Code 406

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    406 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a decision node type

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/decisionNodeTypes \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.node.type+json' \
      -H 'Accept: application/vnd.sas.decision.node.type+json'
    
    
    const inputBody = '{
      "name": "Demo Node Type",
      "hasProperties": false,
      "hasInputs": true,
      "hasOutputs": true,
      "inputDatagridMappable": false,
      "outputDatagridMappable": false,
      "inputDecisionTermMappable": true,
      "outputDecisionTermMappable": true,
      "independentMappings": false,
      "themeId": "DNT_THEME1",
      "type": "static"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.node.type+json',
      'Accept':'application/vnd.sas.decision.node.type+json'
    };
    
    fetch('https://example.com/decisions/decisionNodeTypes',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.node.type+json',
      'Accept': 'application/vnd.sas.decision.node.type+json'
    }
    
    r = requests.post('https://example.com/decisions/decisionNodeTypes', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.node.type+json"},
            "Accept": []string{"application/vnd.sas.decision.node.type+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/decisionNodeTypes", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /decisionNodeTypes

    Creates a new decision node type based on the provided content.

    Body parameter

    Creating or updating a decision node type.

    {
      "name": "Demo Node Type",
      "hasProperties": false,
      "hasInputs": true,
      "hasOutputs": true,
      "inputDatagridMappable": false,
      "outputDatagridMappable": false,
      "inputDecisionTermMappable": true,
      "outputDecisionTermMappable": true,
      "independentMappings": false,
      "themeId": "DNT_THEME1",
      "type": "static"
    }
    
    Parameters
    Name In Type Required Description
    body body decisionNodeType true DecisionNodeType representation to create a decision node type.

    Example responses

    Decision node type with full details.

    {
      "creationTimeStamp": "2021-05-07T18:12:17.412Z",
      "modifiedTimeStamp": "2021-05-07T18:12:17.412Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "name": "Demo Node Type 3",
      "hasProperties": false,
      "hasInputs": true,
      "hasOutputs": true,
      "inputDatagridMappable": false,
      "outputDatagridMappable": false,
      "inputDecisionTermMappable": true,
      "outputDecisionTermMappable": true,
      "independentMappings": false,
      "themeId": "DNT_THEME1",
      "type": "static",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "responseType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "type": "application/vnd.sas.decision.node.type",
          "responseType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "POST",
          "rel": "setContent",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "type": "application/vnd.sas.decision.node.type.content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
          "responseType": "application/vnd.sas.decision.step.code"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2021-05-07T18:12:17.412Z",
      "modifiedTimeStamp": "2021-05-07T18:12:17.412Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "name": "Demo Node Type 3",
      "hasProperties": false,
      "hasInputs": true,
      "hasOutputs": true,
      "inputDatagridMappable": false,
      "outputDatagridMappable": false,
      "inputDecisionTermMappable": true,
      "outputDecisionTermMappable": true,
      "independentMappings": false,
      "themeId": "DNT_THEME1",
      "type": "static",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "responseType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "type": "application/vnd.sas.decision.node.type",
          "responseType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "POST",
          "rel": "setContent",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "type": "application/vnd.sas.decision.node.type.content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
          "responseType": "application/vnd.sas.decision.step.code"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The decision node type was created. decisionNodeType
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Last-Modified string No description
    201 Location string No description
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get decision node type content

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision.node.type.content+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision.node.type.content+json'
    };
    
    fetch('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision.node.type.content+json'
    }
    
    r = requests.get('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision.node.type.content+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /decisionNodeTypes/{nodeTypeId}/content

    Retrieves the decision node type content, which can then be used to represent the decision node type when the containing decision is executed.

    Parameters
    Name In Type Required Description
    nodeTypeId path string true Identifier for the decision node type.

    Example responses

    Decision node type content with full details.

    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "nodeTypeId": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "nodeTypeId": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ]
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No decision node type code exists at the requested path. Inline
    Response Schema

    Status Code 200

    Decision Node Type Content

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » nodeTypeId string false none The id of the decision node type associated with this decision node type content
    » contentType string true none The type of logic to be executed when the associated decision node type is included in a decision flow (DS2 is only support contentType as of now)
    » staticContent string false none The logic to be executed when a decision node type of type "static" is is executed. If the decision node type is not of type "static" this property should be null
    » nodeTypeSignatureTerms [any] false none Signature variables of the decision node type.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» autoPopulate boolean false none 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 string(enumeration) true none Data type of the dataGrid column.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description
    200 ETag string The entity tag for the decision flow.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Update a decision node type

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/decisions/decisionNodeTypes/{nodeTypeId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.node.type+json' \
      -H 'Accept: application/vnd.sas.decision.node.type+json' \
      -H 'If-Match: "kknyjgku"'
    
    
    const inputBody = '{
      "name": "Demo Node Type",
      "hasProperties": false,
      "hasInputs": true,
      "hasOutputs": true,
      "inputDatagridMappable": false,
      "outputDatagridMappable": false,
      "inputDecisionTermMappable": true,
      "outputDecisionTermMappable": true,
      "independentMappings": false,
      "themeId": "DNT_THEME1",
      "type": "static"
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.node.type+json',
      'Accept':'application/vnd.sas.decision.node.type+json',
      'If-Match':'"kknyjgku"'
    };
    
    fetch('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.node.type+json',
      'Accept': 'application/vnd.sas.decision.node.type+json',
      'If-Match': '"kknyjgku"'
    }
    
    r = requests.put('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.node.type+json"},
            "Accept": []string{"application/vnd.sas.decision.node.type+json"},
            "If-Match": []string{""kknyjgku""},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/decisions/decisionNodeTypes/{nodeTypeId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /decisionNodeTypes/{nodeTypeId}

    Updates the decision node type.

    Body parameter

    Creating or updating a decision node type.

    {
      "name": "Demo Node Type",
      "hasProperties": false,
      "hasInputs": true,
      "hasOutputs": true,
      "inputDatagridMappable": false,
      "outputDatagridMappable": false,
      "inputDecisionTermMappable": true,
      "outputDecisionTermMappable": true,
      "independentMappings": false,
      "themeId": "DNT_THEME1",
      "type": "static"
    }
    
    Parameters
    Name In Type Required Description
    nodeTypeId path string true Identifier for the decision node type.
    If-Match header string true Etag value from when the originating object was retrieved.
    body body decisionNodeType true Decision Node Type content to use in update

    Example responses

    Decision node type with full details.

    {
      "creationTimeStamp": "2021-05-07T18:12:17.412Z",
      "modifiedTimeStamp": "2021-05-07T18:12:17.412Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "name": "Demo Node Type 3",
      "hasProperties": false,
      "hasInputs": true,
      "hasOutputs": true,
      "inputDatagridMappable": false,
      "outputDatagridMappable": false,
      "inputDecisionTermMappable": true,
      "outputDecisionTermMappable": true,
      "independentMappings": false,
      "themeId": "DNT_THEME1",
      "type": "static",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "responseType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "type": "application/vnd.sas.decision.node.type",
          "responseType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "POST",
          "rel": "setContent",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "type": "application/vnd.sas.decision.node.type.content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
          "responseType": "application/vnd.sas.decision.step.code"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2021-05-07T18:12:17.412Z",
      "modifiedTimeStamp": "2021-05-07T18:12:17.412Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "name": "Demo Node Type 3",
      "hasProperties": false,
      "hasInputs": true,
      "hasOutputs": true,
      "inputDatagridMappable": false,
      "outputDatagridMappable": false,
      "inputDecisionTermMappable": true,
      "outputDecisionTermMappable": true,
      "independentMappings": false,
      "themeId": "DNT_THEME1",
      "type": "static",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "responseType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131",
          "type": "application/vnd.sas.decision.node.type",
          "responseType": "application/vnd.sas.decision.node.type"
        },
        {
          "method": "POST",
          "rel": "setContent",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "type": "application/vnd.sas.decision.node.type.content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        },
        {
          "method": "GET",
          "rel": "content",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        },
        {
          "method": "GET",
          "rel": "decisionStepCode",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/decisionStepCode",
          "responseType": "application/vnd.sas.decision.step.code"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. decisionNodeType
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No decision node type exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description
    200 ETag string The entity tag for the decision flow.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    412 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    428 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a decision node type

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/decisions/decisionNodeTypes/{nodeTypeId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/decisions/decisionNodeTypes/{nodeTypeId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /decisionNodeTypes/{nodeTypeId}

    Deletes the specified decision node type.

    Parameters
    Name In Type Required Description
    nodeTypeId path string true Identifier for the decision node type.
    Responses
    Status Meaning Description Schema
    204 No Content The decision node type was deleted. None
    Response Headers
    Status Header Type Format Description
    204 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Add decision node type content to a decision node type

    Code samples

    # You can also use wget
    curl -X POST https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.node.type.content+json' \
      -H 'Accept: application/vnd.sas.decision.node.type.content+json'
    
    
    const inputBody = '{
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.node.type.content+json',
      'Accept':'application/vnd.sas.decision.node.type.content+json'
    };
    
    fetch('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.node.type.content+json',
      'Accept': 'application/vnd.sas.decision.node.type.content+json'
    }
    
    r = requests.post('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.node.type.content+json"},
            "Accept": []string{"application/vnd.sas.decision.node.type.content+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /decisionNodeTypes/{nodeTypeId}/content

    Creates a new decision node type content associated with a decision node type based on the provided content.

    Body parameter

    Creating or updating a decision node type content.

    {
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    nodeTypeId path string true Identifier for the decision node type.
    body body #/paths/~1decisionNodeTypes~1%7BnodeTypeId%7D~1content/post/requestBody/content/application~1vnd.sas.decision.node.type.content%2Bjson/schema true DecisionNodeTypeContent representation to create a decision node type content.

    Example responses

    Decision node type content with full details.

    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "nodeTypeId": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "nodeTypeId": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created The decision node type was created. Inline
    400 Bad Request The request was invalid. errorResponse
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match. Inline
    Response Schema

    Status Code 201

    Decision Node Type Content

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » nodeTypeId string false none The id of the decision node type associated with this decision node type content
    » contentType string true none The type of logic to be executed when the associated decision node type is included in a decision flow (DS2 is only support contentType as of now)
    » staticContent string false none The logic to be executed when a decision node type of type "static" is is executed. If the decision node type is not of type "static" this property should be null
    » nodeTypeSignatureTerms [any] false none Signature variables of the decision node type.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» autoPopulate boolean false none 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 string(enumeration) true none Data type of the dataGrid column.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Last-Modified string No description
    201 Location string No description
    201 ETag string The entity tag for the decision flow.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    412 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    428 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Update a decision node type content

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.node.type.content+json' \
      -H 'Accept: application/vnd.sas.decision.node.type.content+json' \
      -H 'If-Match: "kknyjgku"'
    
    
    const inputBody = '{
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.node.type.content+json',
      'Accept':'application/vnd.sas.decision.node.type.content+json',
      'If-Match':'"kknyjgku"'
    };
    
    fetch('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.node.type.content+json',
      'Accept': 'application/vnd.sas.decision.node.type.content+json',
      'If-Match': '"kknyjgku"'
    }
    
    r = requests.put('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.node.type.content+json"},
            "Accept": []string{"application/vnd.sas.decision.node.type.content+json"},
            "If-Match": []string{""kknyjgku""},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/content", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /decisionNodeTypes/{nodeTypeId}/content

    Updates a decision node type content associated with a decision node type based on the provided content.

    Body parameter

    Creating or updating a decision node type content.

    {
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    nodeTypeId path string true Identifier for the decision node type.
    If-Match header string true Etag value from when the originating object was retrieved.
    body body #/paths/~1decisionNodeTypes~1%7BnodeTypeId%7D~1content/post/requestBody/content/application~1vnd.sas.decision.node.type.content%2Bjson/schema true DecisionNodeTypeContent representation to update a pre-existing decision node type content.

    Example responses

    Decision node type content with full details.

    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "nodeTypeId": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "nodeTypeId": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "nodeTypeId": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "nodeTypeId": "a86ded32-73bd-434d-9f89-29ba4a90c131",
      "contentType": "DS2",
      "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "nodeTypeSignatureTerms": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    201 Created The decision node type content was updated. Inline
    400 Bad Request The request was invalid. errorResponse
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match. Inline
    Response Schema

    Status Code 200

    Decision Node Type Content

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » nodeTypeId string false none The id of the decision node type associated with this decision node type content
    » contentType string true none The type of logic to be executed when the associated decision node type is included in a decision flow (DS2 is only support contentType as of now)
    » staticContent string false none The logic to be executed when a decision node type of type "static" is is executed. If the decision node type is not of type "static" this property should be null
    » nodeTypeSignatureTerms [any] false none Signature variables of the decision node type.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» autoPopulate boolean false none 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 string(enumeration) true none Data type of the dataGrid column.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 201

    Decision Node Type Content

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » nodeTypeId string false none The id of the decision node type associated with this decision node type content
    » contentType string true none The type of logic to be executed when the associated decision node type is included in a decision flow (DS2 is only support contentType as of now)
    » staticContent string false none The logic to be executed when a decision node type of type "static" is is executed. If the decision node type is not of type "static" this property should be null
    » nodeTypeSignatureTerms [any] false none Signature variables of the decision node type.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» autoPopulate boolean false none 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 string(enumeration) true none Data type of the dataGrid column.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the decision node type content.
    200 Last-Modified string The timestamp when the decision node type content was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Last-Modified string No description
    201 Location string No description
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    412 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    428 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get decision node type decision step code (static decision node types only)

    Code samples

    # You can also use wget
    curl -X GET https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/decisionStepCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision.step.code+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision.step.code+json'
    };
    
    fetch('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/decisionStepCode',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision.step.code+json'
    }
    
    r = requests.get('https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/decisionStepCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision.step.code+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/decisions/decisionNodeTypes/{nodeTypeId}/decisionStepCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /decisionNodeTypes/{nodeTypeId}/decisionStepCode

    Returns the decision step code for the specified decision node type of type static.

    Parameters
    Name In Type Required Description
    nodeTypeId path string true The unique identifier for the decision node type.
    codeTarget query string false Target where the DS2 code is deployed.
    Enumerated Values
    Parameter Value
    codeTarget others
    codeTarget microAnalyticService

    Example responses

    Decision step code for decision node type.

    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "type": "dntStatic",
      "code": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ],
      "version": 1
    }
    
    {
      "creationTimeStamp": "2021-05-07T18:33:04.846Z",
      "modifiedTimeStamp": "2021-05-07T18:33:04.846Z",
      "createdBy": "edmdev",
      "modifiedBy": "edmdev",
      "id": "15af2c7d-f162-4c76-949f-842940d636c5",
      "type": "dntStatic",
      "code": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;\n",
      "signature": [
        {
          "name": "a",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "c",
          "dataType": "decimal",
          "direction": "input"
        },
        {
          "name": "b",
          "dataType": "decimal",
          "direction": "output"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "uri": "/decisions/decisionNodeTypes/a86ded32-73bd-434d-9f89-29ba4a90c131/content",
          "responseType": "application/vnd.sas.decision.node.type.content"
        }
      ],
      "version": 1
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No decisionNodeType exists at the requested path. Inline
    Response Schema

    Status Code 200

    Decision Step Code

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string false none The name of the object used in decision step.
    » description string false none The description of the object used in decision step.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » code string false none The code of the object used in the decision step.
    » type string false none The object type of the object used in the decision step.
    » signature [any] false none Signature variables of the object used in the decision step.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1flows/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 ETag string The entity tag for the decision node type.
    200 Last-Modified string The timestamp when the decision node type was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Schemas

    resourceSummaryCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "type": "string",
          "description": "string",
          "typeDefName": "string",
          "iconUri": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    
    

    Resource Summary Collection

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [object] false none The links that apply to the collection.
    »» Link object false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [object] true none Array consisting of one page of the objects as summary resources.
    »» Resource Summary object false none The summarized representation of a resource. Often used in collection responses when more specific details aren't needed.
    »»» id string true none The unique identifier for the resource.
    »»» name string false none The name of the resource.
    »»» type string false none The type of the resource.
    »»» description string false none The description of the resource.
    »»» typeDefName string false none (version 2) The name of the type definition that describes the contents of this resource.
    »»» iconUri string false none (version 2) The URI of an icon assigned to this resource, overrides default icons for the type.
    »»» createdBy string false none The user who created the resource.
    »»» creationTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was created.
    »»» modifiedBy string false none The user who most recently modified the resource.
    »»» modifiedTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was last modified.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] true none The links that apply to the resource.
    »»» version integer true none The version number of the resource. This representation is version 2.

    decisionCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "description": "string",
          "majorRevision": 0,
          "locked": true,
          "minorRevision": 0,
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "createdBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "nodeCount": 0,
          "sourceRevisionUri": "string",
          "copyTimeStamp": "2019-08-24T14:15:22Z",
          "flow": {
            "id": "string",
            "creationTimeStamp": "2019-08-24T14:15:22Z",
            "createdBy": "string",
            "modifiedTimeStamp": "2019-08-24T14:15:22Z",
            "modifiedBy": "string",
            "steps": [
              {
                "type": "application/vnd.sas.decision.step.ruleset",
                "mappingDataGridName": "string",
                "ruleSet": {
                  "name": "string",
                  "id": "string",
                  "versionId": "string",
                  "versionName": "string"
                },
                "mappings": [
                  {
                    "stepTermName": "string",
                    "direction": "input",
                    "targetDecisionTermName": "string",
                    "targetDataGridTermName": "string"
                  }
                ]
              }
            ]
          },
          "signature": [
            {
              "id": "string",
              "name": "string",
              "description": "string",
              "defaultValue": {},
              "length": 0,
              "createdBy": "string",
              "creationTimeStamp": "2019-08-24T14:15:22Z",
              "modifiedBy": "string",
              "modifiedTimeStamp": "2019-08-24T14:15:22Z",
              "dataType": "string",
              "direction": "input",
              "dataGridExtension": [
                {
                  "id": "string",
                  "name": "string",
                  "length": 0,
                  "dataType": "string"
                }
              ],
              "legacy": true
            }
          ],
          "subjectLevel": "string",
          "subjectId": {
            "id": "string",
            "name": "string"
          },
          "folderType": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    
    

    Decision Collection

    Properties
    Name Type Required Restrictions Description
    Decision Collection any false none A paginated list of decision representations, with optional links to first, prev, next, and last page of the collection.

    allOf

    Name Type Required Restrictions Description
    anonymous resourceSummaryCollection/allOf/0 false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [object] true none Array consisting of one page of Decision resources.
    »» Decision object false none The representation of a decision.
    »»» id string false none The string ID for the decision.
    »»» name string true none The name for the decision.
    »»» description string false none The description for the decision.
    »»» majorRevision integer false none Major version number of the revision being viewed of the decision. 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.
    »»» locked boolean false none Flag that indicates whether the content being viewed is locked or editable.
    »»» minorRevision integer false none Minor version number of the current revision of the decision. 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.
    »»» creationTimeStamp string(date-time) false none The timestamp when the decision was created.
    »»» createdBy string false none The user ID who created the decision.
    »»» modifiedTimeStamp string(date-time) false none The timestamp when the decision properties was modified.
    »»» modifiedBy string false none The user ID who modified the decision.
    »»» nodeCount integer false none The total number of decision steps(nodes) in the decision flow.
    »»» sourceRevisionUri string false none The URI of the decision revision this decision is being created from.
    »»» copyTimeStamp string(date-time) false none The time stamp when the decision revision was copied.
    »»» flow object false none The representation of a decision flow.
    »»»» id string false none The string ID for the decision flow.
    »»»» creationTimeStamp string(date-time) false none The timestamp when the decision flow was created.
    »»»» createdBy string false none The user ID who created the decision flow.
    »»»» modifiedTimeStamp string(date-time) false none The timestamp when the decision flow properties was modified.
    »»»» modifiedBy string false none The user ID who modified the decision flow.
    »»»» steps [anyOf] false none The sequence of rule sets, models, custom objects, branches, and conditions that represent the decision-making flow object.

    anyOf

    Name Type Required Restrictions Description
    »»»»» anonymous object false none A ruleSet step within a decision.
    »»»»»» type string(enumeration) true none Type of step being referenced within the decision flow.
    »»»»»» mappingDataGridName string false none Datagrid signature term name that is used by mapping. Valid only for customObject, ruleSet and model steps.
    »»»»»» ruleSet object false none Specifies the rule set that is being referenced for this step. Required if type is set to 'application/vnd.sas.decision.step.ruleset'.
    »»»»»»» name string false none The name of the rule set being referenced.
    »»»»»»» id string true none Identifier of the rule set that is being referenced.
    »»»»»»» versionId string true none The identifier of the rule set version that is being referenced.
    »»»»»»» versionName string false none The name of the version that is being referenced.
    »»»»»» mappings [object] false none Variable mappings for the model or rule set being referenced. Required if type is set to 'application/vnd.sas.decision.step.model' or 'application/vnd.sas.decision.step.ruleset'.
    »»»»»»» Decision Step Mapping object false none Represents the mapping between the terms input and output by a decision step and the signature entries of the decision.
    »»»»»»»» stepTermName string true none The name of the step term to which the decision signature entry is mapped.
    »»»»»»»» direction string true none Describes whether mapping is an input, output, or both from the point of view of the decision step.
    »»»»»»»» targetDecisionTermName string false none The name of the decision signature entry to which a step term will be mapped.
    »»»»»»»» targetDataGridTermName string false none The name of the term inside the mappedDataGrid term to which a step term will be mapped.

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none A model step within a decision.
    »»»»»» type string(enumeration) true none Type of step being referenced within the decision flow.
    »»»»»» mappingDataGridName string false none Datagrid signature term name that is used by mapping. Valid only for customObject, ruleSet and model steps.
    »»»»»» model object false none Represents a model be referenced as a step within a decision flow.
    »»»»»»» name string true none The name of the model being referenced.
    »»»»»»» id string true none The ID of the model that is being referenced.
    »»»»»» mappings [decisionCollection/allOf/1/properties/items/items/properties/flow/properties/steps/items/anyOf/0/properties/mappings/items] false none Variable mappings for the model or rule set being referenced. Required if type is set to 'application/vnd.sas.decision.step.model' or 'application/vnd.sas.decision.step.ruleset'.

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none A custom object step within a decision.
    »»»»»» type string(enumeration) true none Type of step being referenced within the decision flow.
    »»»»»» mappingDataGridName string false none Datagrid signature term name that is used by mapping. Valid only for customObject, ruleSet and model steps.
    »»»»»» customObject object false none Represents a step containing a custom implemented step within the decision flow. Treatment groups, code files, and other decisions can be referenced using a custom object step.
    »»»»»»» name string true none The name of the custom object being referenced.
    »»»»»»» uri string true none The URI of the custom object that is being referenced. URIs to code files, treatment groups, and other decisions are currently supported.
    »»»»»»» type string false none Type of object that is being referenced. Known supported types treatmentGroup, decision, decisionDs2CodeFile, decisionSQLCodeFile, and decisionPythonFile.
    »»»»»» mappings [decisionCollection/allOf/1/properties/items/items/properties/flow/properties/steps/items/anyOf/0/properties/mappings/items] false none Variable mappings for the model or rule set being referenced. Required if type is set to 'application/vnd.sas.decision.step.model' or 'application/vnd.sas.decision.step.ruleset'.

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none A record contact step within a decision.
    »»»»»» type string(enumeration) true none Type of step being referenced within the decision flow.
    »»»»»» recordContact object false none Represents the user specifying that contact information should be recorded at this step within the flow and details that should be recorded.
    »»»»»»» name string true none Logical name of this node for business user identification.
    »»»»»»» ruleFiredTracking boolean true none Flag that determines whether the current rule fired information will be recorded with the contact information being written.
    »»»»»»» pathTracking boolean true none Flag that determines whether the current path of steps that were taken in the decision up to this step will be recorded with the contact information being written.
    »»»»»»» treatmentDatagridTerm string false none The name of the decision signature entry to that contains treatment information that should be recorded during the contact for future response tracking. Provided data grid term must have a 'treatmentId' column extension.
    »»»»»»» responseTrackingVariableName string false none The name of the system-generated variable that will be created in the output of this decision that will contain a unique response tracking code that can be used for updating contact information in the Subject Contact API that corresponds to this step. This value will be determined by the service.
    »»»»»»» excludeFromContactAggregation boolean false none Flag that determines the setting of the 'excludeFromAggregation' member when contacts from this step are recorded. If not set it defaults to false.
    »»»»»»» channelTerm string false none The name of the decision signature entry to which contains channel that should be recorded during the contact for future response tracking. Provided term should be a 'string' type.
    »»»»»»» auditTerms [object] false none List of signature entries that will be included within the recorded contact information.
    »»»»»»»» Audit Term object false none Represents a term that is being recorded for auditing purposes during contact recording.
    »»»»»»»»» name string true none The name of the term that is being referenced from the signature.

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none Represents a link within a decision flow, which directs the execution flow of the decision to an arbitrary node based on the linkLabel of the target node.
    »»»»»» type string(enumeration) false none Type of step being referenced within the decision flow.
    »»»»»» decisionNodeLinkTarget string true none The linkLabel of the node to which execution flow should be directed.

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none A condition step within a decision.
    »»»»»» type string(enumeration) true none Type of step being referenced within the decision flow.
    »»»»»» condition object false none Represents a condition step within a decision flow.
    »»»»»»» lhsTerm decisionCollection/allOf/1/properties/items/items/properties/signature/items true none Represents a term that is used for a condition comparison within a decision.
    »»»»»»» rhsTerm decisionCollection/allOf/1/properties/items/items/properties/signature/items false none Represents a term that is used for a condition comparison within a decision.
    »»»»»»» rhsConstant string false none none
    »»»»»»» operator string true none none
    »»»»»» conditionExpression string false none Condition expressed as expression. Can be used instead of condition.
    »»»»»» onTrue decisionCollection/allOf/1/properties/items/items/properties/flow false none The representation of a decision flow.
    »»»»»» onFalse decisionCollection/allOf/1/properties/items/items/properties/flow false none The representation of a decision flow.

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none Represents a branch decision flow step. A branch step contains a list of branchCases and a defaultCase. During the execution of a branch step each branchCases condition is evaluated in order. The decision flow will follow the first branchCases who's condition evaluates true. If no branchCases's condition evaluates true the branchStep's defaultCase path is followed.
    »»»»»» type string(enumeration) false none Type of step being referenced within the decision flow.
    »»»»»» name string false none The logical name of this node for business user identification.
    »»»»»» branchType string(enumeration) true none One of:
    * range - A branch step with branchType "range" contains branchCases that define a "range" condition for either a variable lower bound, a variable upper bound, or a variable range.
    * equals - A branch step with branchType "equals" contains branchCases that define "equals" conditions. All conditions in an "equals" branch must use the "=" operator. Several "equals" conditions can be "OR"ed.
    * like - A branch step with branchType "like" contains branchCases that define "like" conditions. All conditions in an "equals" branch must use the "like" operator. Several "like" conditions can be "OR"ed.
    »»»»»» branchCases [object] false none Specifies an array of branchCases. At execution time each branchCase is evaluated in order. The "onTrue" path of the first branchCase whose condition(s) evaluates true is followed. If no branchCase's condition(s) evaluates true the defaultCase path is followed.
    »»»»»»» Decision Case object false none Represents a single case within a branch step of a decision flow. A case can contain a simpleCondition or compoundCondition, but not both.
    »»»»»»»» id string false none The system-assigned unique ID for this object
    »»»»»»»» label string false none A label for the branch case.
    »»»»»»»» simpleCondition object false none Represents a simple condition. The left hand side (lhs), right hand side (rhs) and operator of the condition are evaluated to produce a boolean result of "true" or "false".
    »»»»»»»»» id string false none The system-assigned unique ID for this object
    »»»»»»»»» lhsTerm decisionCollection/allOf/1/properties/items/items/properties/signature/items true none Represents a term that is used for a condition comparison within a decision.
    »»»»»»»»» rhsTerm decisionCollection/allOf/1/properties/items/items/properties/signature/items false none Represents a term that is used for a condition comparison within a decision.
    »»»»»»»»» rhsConstant string false none Specifies the constant to compare the lhsTerm to.
    »»»»»»»»» operator string true none Specifies the comparison operation or operator to use when to compare the lhsTerm to rhsTerm or rhsConstant.
    »»»»»»»» compoundCondition object false none Represents a compound condition. The left hand side (lhs), right hand side (rhs) and operator of the condition are evaluated to produce a boolean result of "true" or "false". A compound condition has a left hand side (lhsSimpleCondition or lhsCompoundCondition) a right hand side (rhsSimpleCondition or rhsCompoundCondition) and a boolean operator.
    »»»»»»»»» id string false none The system-assigned unique ID for this object
    »»»»»»»»» booleanOperator string(enumeration) true none Specifies the booleanOperator of the condition.
    »»»»»»»»» lhsSimpleCondition decisionCollection/allOf/1/properties/items/items/properties/flow/properties/steps/items/anyOf/6/properties/branchCases/items/properties/simpleCondition false none Represents a simple condition. The left hand side (lhs), right hand side (rhs) and operator of the condition are evaluated to produce a boolean result of "true" or "false".
    »»»»»»»»» lhsCompoundCondition decisionCollection/allOf/1/properties/items/items/properties/flow/properties/steps/items/anyOf/6/properties/branchCases/items/properties/compoundCondition false none Represents a compound condition. The left hand side (lhs), right hand side (rhs) and operator of the condition are evaluated to produce a boolean result of "true" or "false". A compound condition has a left hand side (lhsSimpleCondition or lhsCompoundCondition) a right hand side (rhsSimpleCondition or rhsCompoundCondition) and a boolean operator.
    »»»»»»»»» rhsSimpleCondition decisionCollection/allOf/1/properties/items/items/properties/flow/properties/steps/items/anyOf/6/properties/branchCases/items/properties/simpleCondition false none Represents a simple condition. The left hand side (lhs), right hand side (rhs) and operator of the condition are evaluated to produce a boolean result of "true" or "false".
    »»»»»»»»» rhsCompoundCondition decisionCollection/allOf/1/properties/items/items/properties/flow/properties/steps/items/anyOf/6/properties/branchCases/items/properties/compoundCondition false none Represents a compound condition. The left hand side (lhs), right hand side (rhs) and operator of the condition are evaluated to produce a boolean result of "true" or "false". A compound condition has a left hand side (lhsSimpleCondition or lhsCompoundCondition) a right hand side (rhsSimpleCondition or rhsCompoundCondition) and a boolean operator.
    »»»»»»»» onTrue decisionCollection/allOf/1/properties/items/items/properties/flow false none The representation of a decision flow.
    »»»»»» defaultCase decisionCollection/allOf/1/properties/items/items/properties/flow false none The representation of a decision flow.

    continued

    Name Type Required Restrictions Description
    »»» signature [object] true none The set of terms local to this decision with input and output behavior.
    »»»» Decision Condition Term object false none Represents a term that is used for a condition comparison within a decision.
    »»»»» id string false none The system-assigned unique ID for this object
    »»»»» name string true none Name of the term that can be referenced. Term names must be unique within a rule set.
    »»»»» description string false none Description of the term
    »»»»» defaultValue object false none The initial value of the term.
    »»»»» length integer false none Suggested length for use when generating code.
    »»»»» createdBy string false none The user who created the term.
    »»»»» creationTimeStamp string(date-time) false none The date and time that the term was created.
    »»»»» modifiedBy string false none The user ID of the authenticated user who last updated the term.
    »»»»» modifiedTimeStamp string(date-time) false none The date and time that the term was last modified.
    »»»»» dataType string(enumeration) true none The type of data that the term is intended to be used with.
    »»»»» direction string(enumeration) true none 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.
    »»»»» dataGridExtension [object] false none none
    »»»»»» Signature Term Extension object false none Signature Term Extension is used to store the column information of a DataGrid variable.
    »»»»»»» id string false none The system-assigned unique ID for this object
    »»»»»»» name string true none The name of the term that can be referenced. Term names must be unique within a rule set.
    »»»»»»» length integer false none The suggested length for use when generating code.
    »»»»»»» dataType string(enumeration) true none 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.
    »»»»» legacy boolean false none the flag of legacy variable.
    »»» subjectLevel string false none Indicates the type of subject ID.
    »»» subjectId object false none The reference for the term used to identify the subject.
    »»»» id string false none The id for the signature term.
    »»»» name string true none Name of the term that is being referenced within the objects signature.
    »»» folderType string false none Indicates the type of folder where the decision is located.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none Links to related resources or operations.
    »»» version integer false none The version number of the domain representation. This representation is version 1.
    Enumerated Values
    Property Value
    type application/vnd.sas.decision.step.ruleset
    direction input
    direction output
    direction inOut
    type application/vnd.sas.decision.step.model
    type application/vnd.sas.decision.step.custom.object
    type application/vnd.sas.decision.step.record.contact
    type application/vnd.sas.decision.step.node.link
    type application/vnd.sas.decision.step.condition
    type application/vnd.sas.decision.step.branch
    booleanOperator AND
    booleanOperator OR
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime
    dataType dataGrid
    direction input
    direction output
    direction inOut
    direction none
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    externalArtifact

    {
      "name": "string",
      "artifactType": "string",
      "artifactProperties": {},
      "parentURI": "string",
      "version": 0
    }
    
    

    External Artifact

    Properties
    Name Type Required Restrictions Description
    name string false none An assigned name of the artifact.
    artifactType string false none The type of artifact.
    artifactProperties object false none A map of keys to strings that are relevant for this artifact type. For example, for an analytic store, this map has a key for the astoreUri.
    parentURI string false none The URI of the object, such as the model or business rule set, that makes use of this artifact.
    version integer false none This media type's schema version number. This representation is version 1.

    externalArtifactsCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "string",
          "artifactType": "string",
          "artifactProperties": {},
          "parentURI": "string",
          "version": 0
        }
      ]
    }
    
    

    External Artifacts Collection

    Properties
    Name Type Required Restrictions Description
    External Artifacts Collection any false none A collection of external artifact representation

    allOf

    Name Type Required Restrictions Description
    anonymous resourceSummaryCollection/allOf/0 false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [externalArtifact] false none The actual results of a query.

    codeFileCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "description": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "majorRevision": 0,
          "minorRevision": 0,
          "locked": true,
          "type": "decisionDS2CodeFile",
          "status": "valid",
          "errorCode": 0,
          "errorMessage": "string",
          "signature": [
            {
              "name": "string",
              "dataType": "string",
              "direction": "input",
              "length": 0,
              "dataGridExtension": [
                {
                  "name": "string",
                  "length": 0,
                  "dataType": "string"
                }
              ]
            }
          ],
          "folderType": "string",
          "sourceRevisionUri": "string",
          "copyTimeStamp": "2019-08-24T14:15:22Z",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "fileUri": "string",
          "version": 0
        }
      ]
    }
    
    

    Code File Collection

    Properties
    Name Type Required Restrictions Description
    Code File Collection any false none One page of decision representations, with optional links to first, prev, next, and last page of the collection.

    allOf

    Name Type Required Restrictions Description
    anonymous resourceSummaryCollection/allOf/0 false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none Array consisting of one page of Decision resources.
    »» Code File object false none Wrapper to file resource, which contains the signature of the code. This represents application/vnd.sas.decision.code.file media type (version 5).
    »»» id string false none The system-assigned unique ID for this object.
    »»» name string false none The code file name.
    »»» description string false none The code file description.
    »»» createdBy string false none The user who created the code file.
    »»» creationTimeStamp string(date-time) false none The date and time that the code file was created.
    »»» modifiedBy string false none The user ID of the authenticated user who last updated the code file.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the code file was last modified.
    »»» majorRevision integer false none Major version number of the revision being viewed of the code file. 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 POST.
    »»» minorRevision integer false none Minor version number of the current revision of the code file. 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 POST.
    »»» locked boolean false none Flag which indicates whether the content of the revision being viewed is locked or editable.
    »»» type string(enumeration) true none Type of the code.
    »»» status string(enumeration) false none Status of the code content.
    »»» errorCode integer false none Error code when parsing code content.
    »»» errorMessage string false none Error message when parsing code content.
    »»» signature [any] false none Array of signature terms.
    »»»» Code File Signature Term object false none Represents the code file signature term.
    »»»»» name string true none The name of the code file signature term.
    »»»»» dataType string true none Data type of the code file signature term.
    »»»»» direction string true none Direction of the code file signature term.
    »»»»» length integer false none Length of the signature term. Valid for string data type.
    »»»»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»»»» Code File Signature Term DataGrid Extension object false none Code File Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»»»» name string true none Name of the dataGrid column.
    »»»»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    »»» folderType string false none Indicates the type of folder where the code file is located.
    »»» sourceRevisionUri string false none The URI of the code file revision this code file is being created from.
    »»» copyTimeStamp string(date-time) false none The time stamp when the code file revision was copied.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »»» fileUri string true none The URI of the file resource, which contains code.
    »»» version integer false none This media type's schema version number. This representation is version 2.
    Enumerated Values
    Property Value
    type decisionDS2CodeFile
    type decisionSQLCodeFile
    type decisionPythonFile
    status valid
    status error
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    direction input
    direction inOut
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    decisionNodeTypeCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "description": "string",
          "hasProperties": true,
          "hasInputs": true,
          "hasOutputs": true,
          "inputDatagridMappable": true,
          "outputDatagridMappable": true,
          "inputDecisionTermMappable": true,
          "outputDecisionTermMappable": true,
          "independentMappings": true,
          "themeId": "string",
          "type": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    
    

    Decision Node Types Collection

    Properties
    Name Type Required Restrictions Description
    Decision Node Types Collection any false none A paginated list of decision node type representations, with optional links to first, prev, next, and last page of the collection.

    allOf

    Name Type Required Restrictions Description
    anonymous resourceSummaryCollection/allOf/0 false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none Array consisting of one page of Decision Node Type resources.
    »» Decision Node Type object false none Contains information needed to extend the decision flow with a new node type
    »»» id string false none The system-assigned unique ID for this object.
    »»» name string true none The name of the DecisionNodeType used by the infrastructure to indentify this node type (no spaces or special characters).
    »»» description string false none The description of the DecisionNodeType.
    »»» hasProperties boolean false none indicates whether or not the DecisionNodeType should be present a properties pane when included in a decision flow
    »»» hasInputs boolean true none indicates that the DecisionNodeType has inputs which should be mapped to decision flow or datagrid variables
    »»» hasOutputs boolean true none indicates that the DecisionNodeType has outputs which should be mapped to decision flow or datagrid variables
    »»» inputDatagridMappable boolean false none indicates that the DecisionNodeType's inputs may be mapped to datagrid extensions
    »»» outputDatagridMappable boolean false none indicates that the DecisionNodeType's outputs may be mapped to datagrid extensions
    »»» inputDecisionTermMappable boolean false none indicates that the DecisionNodeType's inputs may be mapped to decision variables
    »»» outputDecisionTermMappable boolean false none indicates that the DecisionNodeType's outputs may be mapped to decision variables
    »»» independentMappings boolean false none indicates whether same-named inputs/outputs may be mapped independently
    »»» themeId string false none indicating a standard theme which will result in a unique icon and color. The available themes are DNT_THEME1, DNT_THEME2, DNT_THEME3, DNT_THEME4, and DNT_THEME5
    »»» type string true none the type for this DecisionNodeType (static is only supported type as of now)
    »»» createdBy string false none The user who created the object used in decision step.
    »»» creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    »»» modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 1.

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    Decision Media Types
    application/vnd.sas.decision

    Provides information about a decision.

    The schema is at decision.

    application/vnd.sas.decision+json

    Used to represent a decision.

    
     {
           "name": "CreditOffer",
           "creationTimeStamp": "2017-06-12T20:27:44.561Z",
           "modifiedTimeStamp": "2017-06-12T20:29:14.370Z",
           "createdBy": "bob",
           "modifiedBy": "bob",
           "majorRevision" : 1,
           "minorRevision" : 0,
           "nodeCount": 4,
           "locked" : false,
           "id": "43f73aff-2040-4152-9923-9dbb37e73ba7",
           "signature": [
              {
                 "name": "CustIncome",
                 "direction": "inOut",
                 "version": 1,
                 "dataType": "decimal",
                 "creationTimeStamp": "2017-06-12T20:29:13.706Z",
                 "modifiedTimeStamp": "2017-06-12T20:29:13.706Z",
                 "createdBy": "bob",
                 "modifiedBy": "bob",
                 "id": "cc88b4f7-647e-404a-992a-03624a005cef"
              },
              {
                 "name": "EM_PROBABILITY",
                 "direction": "output",
                 "dataType": "decimal",
                 "creationTimeStamp": "2017-06-12T20:29:13.815Z",
                 "modifiedTimeStamp": "2017-06-12T20:29:13.815Z",
                 "createdBy": "bob",
                 "modifiedBy": "bob",
                 "id": "4f3301d9-ee22-4527-b97d-ff47327cccda"
              },
              {
                 "name": "EM_SEGMENT",
                 "direction": "input",
                 "dataType": "decimal",
                 "creationTimeStamp": "2017-06-12T20:29:13.865Z",
                 "modifiedTimeStamp": "2017-06-12T20:29:13.865Z",
                 "createdBy": "bob",
                 "modifiedBy": "bob",
                 "id": "8cacfb49-68c3-4d10-ae9b-211076a65594"
              },
              {
                 "name": "YOJ",
                 "direction": "inOut",
                 "dataType": "decimal",
                 "creationTimeStamp": "2017-06-12T20:29:14.269Z",
                 "modifiedTimeStamp": "2017-06-12T20:29:14.269Z",
                 "createdBy": "bob",
                 "modifiedBy": "bob",
                 "id": "84e70f06-f9a2-404e-b2f1-82f5d0513893"
              },
              {
                 "name": "DELINQ",
                 "direction": "inOut",
                 "dataType": "decimal",
                 "creationTimeStamp": "2017-06-12T20:29:14.300Z",
                 "modifiedTimeStamp": "2017-06-12T20:29:14.300Z",
                 "createdBy": "bob",
                 "modifiedBy": "bob",
                 "id": "73813b84-8458-47f6-9b0d-3a082fe5c6ef"
              },
              {
                 "name": "CreditAmount",
                 "direction": "output",
                 "dataType": "integer",
                 "creationTimeStamp": "2017-06-12T20:29:14.334Z",
                 "modifiedTimeStamp": "2017-06-12T20:29:14.334Z",
                 "createdBy": "bob",
                 "modifiedBy": "bob",
                 "id": "1822f7d8-11b7-45c5-810d-4e75356957a8"
              },
              {
                 "name": "customerId",
                 "direction": "output",
                 "dataType": "string",
                 "defaultValue" : "-",
                 "creationTimeStamp": "2017-06-12T20:29:14.334Z",
                 "modifiedTimeStamp": "2017-06-12T20:29:14.334Z",
                 "createdBy": "bob",
                 "modifiedBy": "bob",
                 "id": "0f22f7d8-13b7-75c5-e10d-9e75356957a8"
              }       
           ],
           "subjectId": {
                "name": "customerId",
                "id": "0f22f7d8-13b7-75c5-e10d-9e75356957a8"
           },
           "subjectLevel": "household",
           "folderType": "myFolder",
           "flow": {
                "creationTimeStamp": "2017-06-12T20:27:44.682Z",
                "modifiedTimeStamp": "2017-06-12T20:27:44.682Z",
                "createdBy": "bob",
                "modifiedBy": "bob",
                "id": "dc271752-275f-4a15-aef7-442434f1097d",
                "steps": [
                     {
                        "type": "application/vnd.sas.decision.step.model",
                        "creationTimeStamp": "2017-06-12T20:29:15.931Z",
                        "modifiedTimeStamp": "2017-06-12T20:29:15.931Z",
                        "createdBy": "bob",
                        "modifiedBy": "bob",
                        "id": "e1a6f9bc-c7fe-4e4e-a38a-ac3397db5fef",
                        "model": {
                           "name": "CreditScore",
                           "id": "dfeda8cc-2d5a-4e86-bfcd-17add2b08b87"
                        },
                        "mappings": [
                           {
                              "stepTermName": "CustIncome",
                              "dataType": "decimal",
                              "direction": "input",
                              "targetDecisionTermName": "CustIncome",
                              "creationTimeStamp": "2017-06-12T20:29:15.931Z",
                              "modifiedTimeStamp": "2017-06-12T20:29:15.931Z",
                              "createdBy": "bob",
                              "modifiedBy": "bob",
                              "id": "023c2373-6b2f-4c33-a6ed-6cb37ec29169"
                           },
                           {
                              "stepTermName": "EM_PROBABILITY",
                              "dataType": "decimal",
                              "direction": "output",
                              "targetDecisionTermName": "EM_PROBABILITY",
                              "creationTimeStamp": "2017-06-12T20:29:15.933Z",
                              "modifiedTimeStamp": "2017-06-12T20:29:15.933Z",
                              "createdBy": "bob",
                              "modifiedBy": "bob",
                              "id": "0d7251a6-7ff3-47c4-8322-386f321e8362"
                           },
                           {
                              "stepTermName": "EM_SEGMENT",
                              "dataType": "decimal",
                              "direction": "output",
                              "targetDecisionTermName": "EM_SEGMENT",
                              "creationTimeStamp": "2017-06-12T20:29:15.933Z",
                              "modifiedTimeStamp": "2017-06-12T20:29:15.933Z",
                              "createdBy": "bob",
                              "modifiedBy": "bob",
                              "id": "f2e89bd1-0985-4c47-a6d8-f09136418e36"
                           }
                        ]            
                     },
                     {
                        "type": "application/vnd.sas.decision.step.condition",
                        "creationTimeStamp": "2017-06-12T20:29:15.936Z",
                        "modifiedTimeStamp": "2017-06-12T20:29:15.936Z",
                        "createdBy": "bob",
                        "modifiedBy": "bob",
                        "id": "5a246276-9576-4ffc-917c-f4ad48d0910b",
                        "condition": {
                           "lhsTerm": {
                              "name": "EM_PROBABILITY"
                           },
                           "rhsConstant": ".8",
                           "operator": ">"
                        },
                        "onTrue": {
                           "creationTimeStamp": "2017-06-12T20:29:15.935Z",
                           "modifiedTimeStamp": "2017-06-12T20:29:15.935Z",
                           "createdBy": "bob",
                           "modifiedBy": "bob",
                           "id": "0da51b99-e17e-4bcc-8ba5-5debb3698a3f",
                           "steps": [
                              {
                                 "type": "application/vnd.sas.decision.step.ruleset",
                                 "creationTimeStamp": "2017-06-12T20:29:15.935Z",
                                 "modifiedTimeStamp": "2017-06-12T20:29:15.935Z",
                                 "createdBy": "bob",
                                 "modifiedBy": "bob",
                                 "id": "c8d051f9-b09c-4d73-9e01-4e60ce8fcb77",
                                 "ruleset": {
                                    "name": "OfferCredit",
                                    "id": "d71140fa-1d40-44d1-99b9-2157a084adcc",
                                    "versionId": "3483ed58-f66c-4090-89ed-331c3743eaf2"
                                 },
                                 "mappings": [
                                    {
                                       "stepTermName": "YOJ",
                                       "dataType": "decimal",
                                       "direction": "inOut",
                                       "targetDecisionTermName": "YOJ",
                                       "creationTimeStamp": "2017-06-12T20:29:15.935Z",
                                       "modifiedTimeStamp": "2017-06-12T20:29:15.935Z",
                                       "createdBy": "bob",
                                       "modifiedBy": "bob",
                                       "id": "0c9b5ea1-96cf-41cb-94fe-f44cde8e1d9a"
                                    },
                                    {
                                       "stepTermName": "DELINQ",
                                       "dataType": "decimal",
                                       "direction": "inOut",
                                       "targetDecisionTermName": "DELINQ",
                                       "creationTimeStamp": "2017-06-12T20:29:15.935Z",
                                       "modifiedTimeStamp": "2017-06-12T20:29:15.935Z",
                                       "createdBy": "bob",
                                       "modifiedBy": "bob",
                                       "id": "7f0ac7d3-33f1-45b7-8526-d63a05aeb5e6"
                                    },
                                    {
                                       "stepTermName": "CreditAmount",
                                       "dataType": "integer",
                                       "direction": "output",
                                       "targetDecisionTermName": "CreditAmount",
                                       "creationTimeStamp": "2017-06-12T20:29:15.935Z",
                                       "modifiedTimeStamp": "2017-06-12T20:29:15.935Z",
                                       "createdBy": "bob",
                                       "modifiedBy": "bob",
                                       "id": "23590aee-9bfc-49da-bcba-13f21820cf04"
                                    }
                                 ]
                              }
                           ]
                        },
                        "onFalse": {
                           "creationTimeStamp": "2017-06-12T20:29:15.935Z",
                           "modifiedTimeStamp": "2017-06-12T20:29:15.935Z",
                           "createdBy": "bob",
                           "modifiedBy": "bob",
                           "id": "495d3376-6023-4a78-94ee-9d7f70a612a2",
                           "steps": [
                              {
                                 "type": "application/vnd.sas.decision.step.ruleset",
                                 "creationTimeStamp": "2017-06-12T20:29:15.935Z",
                                 "modifiedTimeStamp": "2017-06-12T20:29:15.935Z",
                                 "createdBy": "bob",
                                 "modifiedBy": "bob",
                                 "id": "b1dd6a2f-c9f6-45b6-883e-56eb720abc6f",
                                 "ruleset": {
                                    "name": "DenyCredit",
                                    "id": "686c1a62-0a71-486d-afca-f011c231abfc",
                                    "versionId": "fca7da09-b3fb-4261-8c28-6f8918bab7ba"                      
                                 },
                                 "mappings": [
                                    {
                                       "stepTermName": "CreditAmount",
                                       "dataType": "integer",
                                       "direction": "output",
                                       "targetDecisionTermName": "CreditAmount",
                                       "creationTimeStamp": "2017-06-12T20:29:15.936Z",
                                       "modifiedTimeStamp": "2017-06-12T20:29:15.936Z",
                                       "createdBy": "bob",
                                       "modifiedBy": "bob",
                                       "id": "5c43811f-de22-47a7-b2c5-97351dffdd26"
                                    }
                                 ]
                              }
                           ]
                        }
                     }
                  ]
           }
        }
    
    application/vnd.sas.decision.external.artifact

    Captures external artifact information.

    The schema is at externalArtifact

    application/vnd.sas.decision.external.artifact+json

    Used to represent an external artifact used by a step of a decision flow.

    
     {
       "name":"_237FM9YRQ8IOD5NCLCTWTV91Y_AST",
       "artifactType":"analyticStore",
       "artifactProperties": {
           "astoreName":"_237FM9YRQ8IOD5NCLCTWTV91Y_AST",
           "astoreKey":"B8C22117BA793FC68AD1DD298363E8A779A33287",
           "astoreURI":"/dataTables/dataSources/cas~fs~cas-shared-default~fs~ModelStore/tables/_237FM9YRQ8IOD5NCLCTWTV91Y_AST",
           "astoreFileLocation":"file:///models/astores/viya/_237FM9YRQ8IOD5NCLCTWTV91Y_AST.astore"
       },
       "parentURI":"/modelRepository/models/140ce5f0-78d9-4f67-8d83-7048d7119424",
    }
    
    Externally Defined Media Types
    application/vnd.sas.collection

    A paginated, filterable, sortable collection of resource representations. In this API, this is a collection of application/vnd.sas.decision.

    See application/vnd.sas.collection.

    application/vnd.sas.summary

    A media type used in SAS REST Application Programming Interfaces (APIs) to represent a summary of a resource.

    See application/vnd.sas.summary

    application/vnd.sas.error

    A media type used in SAS REST Application Programming Interfaces (APIs) to represent an error response.

    See application/vnd.sas.error

    application/vnd.sas.score.code.generation.request

    Request format for generating code mapped to specific data based on the specified scoring definition within the request.

    Supported hints within the scoreCodeGenerationRequest for code generation with this service are the following:

    See application/vnd.sas.score.code.generation.request

    vnd.sas.score.code.generation.request.unbound

    Request format for generating the code that is mapped to a generic input and output data set based and is not bound to a scoring definition.

    The schema is at unboundScoreCodeGenerationRequest.

    Supported hints are the same as scoreCodeGenerationRequest for generating code with 3 exceptions debugColumnHint, tableBaseName, and outputLibraryName, are not supported with this type. Also, the following hints are available for this request type.

    See application/vnd.sas.score.code.generation.request.unbound.

    application/vnd.sas.score.mapped.code

    This type is used as a response to request for execution code made with application/vnd.sas.score.execution.request to generate code that is mapped to specific data based on the request.

    The codeType that is returned within the mappedCode is always text/vnd.sas.source.ds2 for this version of the service.

    See application/vnd.sas.score.mapped.code

    application/vnd.sas.score.analysis.code.generation.request

    Request format for generating analysis code mapped to analyze specific data based on the specified score execution (scoreExecutionId) within the request.

    Supported analysis types within the analysisCodeGenerationRequest are the following:

    Hints that are supported when submitting a request are:

    See application/vnd.sas.score.analysis.code.generation.request

    application/vnd.sas.score.analysis.code

    This type is used as a response to request for analysis code made with application/vnd.sas.score.analysis.request to generate analysis code that is mapped to specific data based on the request.

    The codeType that is returned within the analysisCode is text/vnd.sas.source.ds2 or application/json for this version of the service depending on the analysis type requested.

    See application/vnd.sas.score.analysis.code.

    Code File Media Types
    application/vnd.sas.decision.code.file

    Provides code file information.

    The schema is at codeFile.

    application/vnd.sas.decision.code.file+json

    Used to represent a code file.

    
     {
       "name": "CreditOffer",
       "type": "decisionDS2PackageFile",
       "fileUri": "/files/files/0c7281d8-063d-49dd-be6b-392e9c9e930c"
    }
    
    Decision Node Type Media Types
    application/vnd.sas.decision.node.type

    Provides decision node type information.

    The schema is at decisionNodeType.

    application/vnd.sas.decision.node.type+json

    Used to represent a decision node type.

    
     {
        "creationTimeStamp": "2019-12-19T19:48:09.938Z",
        "modifiedTimeStamp": "2019-12-19T19:48:09.938Z",
        "createdBy": "bob",
        "modifiedBy": "bob",
        "id": "8df82895-5cc8-4929-b5e0-d5401277ee52",
        "name": "Sum Two Decimals",
        "hasProperties": false,
        "hasInputs": true,
        "hasOutputs": true,
        "inputDatagridMappable": false,
        "outputDatagridMappable": false,
        "inputDecisionTermMappable": true,
        "outputDecisionTermMappable": true,
        "independentMappings": false,
        "themeId": "DNT_THEME1",
        "type": "static",
        "links": [
            {
                "method": "GET",
                "rel": "self",
                "href": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52",
                "uri": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52",
                "responseType": "application/vnd.sas.decision.node.type"
            },
            {
                "method": "DELETE",
                "rel": "delete",
                "href": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52",
                "uri": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52"
            },
            {
                "method": "PUT",
                "rel": "update",
                "href": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52",
                "uri": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52",
                "type": "application/vnd.sas.decision.node.type",
                "responseType": "application/vnd.sas.decision.node.type"
            },
            {
                "method": "POST",
                "rel": "setContent",
                "href": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52/content",
                "uri": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52/content",
                "type": "application/vnd.sas.decision.node.type.content",
                "responseType": "application/vnd.sas.decision.node.type.content"
            },
            {
                "method": "GET",
                "rel": "content",
                "href": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52/content",
                "uri": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52/content",
                "responseType": "application/vnd.sas.decision.node.type.content"
            },
            {
                "method": "GET",
                "rel": "decisionStepCode",
                "href": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52/decisionStepCode",
                "uri": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52/decisionStepCode",
                "responseType": "application/vnd.sas.decision.step.code"
            }
        ]
    }
    
    application/vnd.sas.decision.node.type.content

    Provides decision node type content information.

    The schema is at decisionNodeTypeContent.

    application/vnd.sas.decision.node.type.content+json

    Used to represent a decision node type content.

    
     {
        "creationTimeStamp": "2019-12-19T19:48:14.144Z",
        "modifiedTimeStamp": "2019-12-19T19:48:14.144Z",
        "createdBy": "bob",
        "modifiedBy": "bob",
        "id": "8e068844-6063-4a90-8055-07da87264c7e",
        "nodeTypeId": "8df82895-5cc8-4929-b5e0-d5401277ee52",
        "contentType": "DS2",
        "staticContent": "package \"${PACKAGE_NAME}\" /inline;\n    method execute(double a, double c, in_out double b);\n    b=a+c;\n   end;\nendpackage;",
        "nodeTypeSignatureTerms": [
            {
                "creationTimeStamp": "2019-12-19T19:48:14.158Z",
                "modifiedTimeStamp": "2019-12-19T19:48:14.158Z",
                "createdBy": "bob",
                "modifiedBy": "bob",
                "id": "7b290397-97ac-4748-9a75-5f969b88b50d",
                "nodeTypeContentId": "8e068844-6063-4a90-8055-07da87264c7e",
                "name": "a",
                "dataType": "decimal",
                "direction": "input"
            },
            {
                "creationTimeStamp": "2019-12-19T19:48:14.159Z",
                "modifiedTimeStamp": "2019-12-19T19:48:14.159Z",
                "createdBy": "bob",
                "modifiedBy": "bob",
                "id": "34867736-d565-4083-a6e8-70cf9fd3840e",
                "nodeTypeContentId": "8e068844-6063-4a90-8055-07da87264c7e",
                "name": "c",
                "dataType": "decimal",
                "direction": "input"
            },
            {
                "creationTimeStamp": "2019-12-19T19:48:14.159Z",
                "modifiedTimeStamp": "2019-12-19T19:48:14.159Z",
                "createdBy": "bob",
                "modifiedBy": "bob",
                "id": "a54869ff-c8b9-4e42-8b13-9c6f8a8705aa",
                "nodeTypeContentId": "8e068844-6063-4a90-8055-07da87264c7e",
                "name": "b",
                "dataType": "decimal",
                "direction": "output"
            }
        ],
        "links": [
            {
                "method": "GET",
                "rel": "self",
                "href": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52/content",
                "uri": "/decisions/decisionNodeTypes/8df82895-5cc8-4929-b5e0-d5401277ee52/content",
                "responseType": "application/vnd.sas.decision.node.type.content"
            }
        ]
    }
    
    Resource Relationships

    Resource relationship diagram

    Root

    Path: /

    The root of the API. This resource contains links to the top-level resources in the API.

    The GET / response include the following links.

    Relation Method Description
    decisions GET Returns the first page of the decision collection.
    URI: /flows
    Response type: application/vnd.sas.collection
    createDecision POST Creates a new decision.
    URI: /flows
    Request type: application/vnd.sas.decision
    Response type: application/vnd.sas.decision
    codeFiles GET Returns the first page of the code files collection.
    URI: /codeFiles
    Response type: application/vnd.sas.collection
    createCodeFile POST Creates a new code file.
    URI: /codeFiles
    Request type: application/vnd.sas.decision.code.file
    Response type: application/vnd.sas.decision.code.file
    decisionNodeTypes GET Returns the first page of the decision node types collection.
    URI: /decisionNodeTypes
    Response type: application/vnd.sas.sas.collection
    createDecisionNodeType POST Creates a new decision node type.
    URI: /decisionNodeTypes
    Request type: application/vnd.sas.decision.node.type
    Response type: application/vnd.sas.decision.node.type
    Decisions

    Path: /flows

    This resource provides a collection of decisions. Default page size is 10.

    The decisions collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.decision resources. (These types apply to the response for the self and collection links below.)

    The GET /flows response include the following links.

    Relation Method Description
    createDecision POST Creates a new decision.
    Request type: application/vnd.sas.decision
    Response type: application/vnd.sas.decision
    self GET Returns the current page of the collection in summary format.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.summary
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.decision
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the decisions collection is by ascending creationTimeStamp.

    Filtering and sorting can use the following members of a decision:

    Filter by name - ?filter=eq(name, 'CreditDecision')

    Filter by multiple names - ?filter=in(name, 'district-southeast', 'district-northeast')

    Filter by time value - ?filter=gt(creationTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combining filters - ?filter=and(gt(creationTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    Decision

    Path: /flows/{decisionId}

    This resource provides the contents of a decision.

    The GET /flows/{decisionId} response includes the following links.

    Relation Method Description
    self GET Returns the full representation of a decision.
    Response type: application/vnd.sas.decision
    revisions GET Returns a list of revisions for the decision.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.summary
    code GET Acquires the generated code for the decision.
    Response type: text/vnd.sas.source.ds2
    mappedCode POST Returns the mapped code object for execution in the Score Execution service.
    Request type: application/vnd.sas.score.code.generation.request
    Response type: application/vnd.sas.score.mapped.code
    delete DELETE Deletes a decision.
    update PUT Updates a decision.
    Request type: application/vnd.sas.decision
    Response type: application/vnd.sas.decision
    Package Code

    Path: /flows/{decisionId}/code

    Returns a representation of a decision as a DS2 package that can be integrated to call a DS2 program.

    Mapped Code

    Path: /flows/{decisionId}/mappedCode

    Responds with a full executable program based on one of two different types of requests:

    This resource can be retrieved as two different representations:

    Analysis Code

    Path: /flows/{decisionId}/analysisCode

    Responds with a full executable program for analysis of the mappedCode results based on application/vnd.sas.score.analysis.request, which is provided within the request.

    The analysisCode response representation is application/vnd.sas.score.analysis.code, which contains the generated analysis code.

    External Artifacts

    Path: /flows/{decisionId}/externalArtifacts

    Captures the collection of external artifacts used by a decision flow.

    Members of the /flows/{decisionId}/externalArtifacts collection are not individually accessible via identifiers.

    The 'external artifacts' collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.decision.external.artifact resources.

    The GET /flows/{decisionId}/externalArtifacts response includes the following links.

    Relation Method Description
    up GET Returns the parent resource.
    Response type: application/vnd.sas.decision.
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.decision.external.artifact.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.decision.external.artifact.
    Sorting and Filtering

    This collection does not support sorting and filtering.

    Decision Revisions

    Path: /flows/{decisionId}/revisions

    This resource provides a collection of decision content across all revisions for the decision. Default page size is 10.

    The revisions collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.decision resources. (These types apply to the response for the self and collection links below.)

    The GET /flows/{decisionId}/revisions response includes the following links.

    Relation Method Description
    createRevision POST Creates a new decision revision.
    Request type: application/vnd.sas.decision
    Response type: application/vnd.sas.decision
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.summary
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.summary
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the decisions collection is by ascending creationTimeStamp.

    Filtering and sorting can use the following members of a decision:

    Filter by name - ?filter=eq(name, 'district-name')

    Filter by multiple names - ?filter=in(name, 'district-southeast', 'district-northeast')

    Filter by time value - ?filter=gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combining filters - ?filter=and(gt(creatiomTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    Decision Revision Content

    Path: /flows/{decisionId}/revisions/{revisionId}

    This resource provides the content of a decision revision.

    The GET /flows/{decisionId}/revisions/{revisionId} response includes the following links.

    Relation Method Description
    self GET Returns the full representation of a revision.
    Response type: application/vnd.sas.decision
    delete DELETE Deletes a locked decision revision.
    code GET Acquires the generated code for the revision.
    Response type: text/vnd.sas.source.ds2
    mappedCode POST Returns the mapped code object for the revision for execution in the Score Execution service
    Request type: application/vnd.sas.score.code.generation.request
    Response type: application/vnd.sas.score.mapped.code
    decision GET Returns the revisions parent decision.
    Response type: application/vnd.sas.decision
    Revision Package Code

    Path: /flows/{decisionId}/revisions/{revisionId}/code

    Returns a representation of the decision revision as a DS2 package that can be integrated to call a DS2 program.

    Revision Mapped Code

    Path: /flows/{decisionId}/revisions/{revisionId}/mappedCode

    Responds with a full executable program for the revision based on one of two different types of requests:

    This resource can be retrieved as two different representations:

    Revision Analysis Code

    Path: /flows/{decisionId}/revisions/{revisionId}/analysisCode

    Responds with a full executable program for analysis of the mappedCode results generated for the revision based on application/vnd.sas.score.analysis.request, which is provided within the request.

    The analysisCode response representation is application/vnd.sas.score.analysis.code, which contains the generated analysis code.

    Revision External Artifacts

    Path: /flows/{decisionId}/revisions/{revisionId}/externalArtifacts

    Captures the collection of external artifacts used by a decision flow revision.

    Members of the /flows/{decisionId}/revisions/{revisionId}/externalArtifacts collection are not individually accessible via identifiers.

    The 'external artifacts' collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.decision.external.artifact resources.

    The GET /flows/{decisionId}/externalArtifacts response includes the following links.

    Relation Method Description
    up GET Returns the parent resource.
    Response type: application/vnd.sas.decision.
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.decision.external.artifact.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.decision.external.artifact.
    Sorting and Filtering

    This collection does not support sorting and filtering.




    Code Files

    Path: /codeFiles

    This API provides collection of Code Files.

    Default page size is 20.

    The codeFiles collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.decision.code.file resources or application/vnd.sas.summary. (These types apply to the response for the self, collection, prev, next, first, and last links below.)

    Responses include the following links.

    Relation Method Description
    create POST Creates a new code file im the collection.
    Request type: application/vnd.sas.decision.code.file.
    Response type: application/vnd.sas.decision.code.file.
    self GET Returns the current page from the collection.
    Response type: application/vnd.sas.collection.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    Filtering and sorting can use the following members of the codeFile:

    Code File

    Path: /codeFiles/{codeFileId}

    This API provides a code file.

    The codeFile representation is application/vnd.sas.decision.code.file.

    Responses include the following links.

    Relation Method Description
    up GET Returns the collection to which a code file belongs.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.decision.code.file.
    Response item type: application/vnd.sas.summary.
    self GET Returns a code file by id.
    Response type: application/vnd.sas.decision.code.file.
    alternate GET Returns a code file summary by id.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes a code file by id.
    Code File Summary

    Path: /codeFiles/{codeFileId}

    This API provides Code File Summary.

    The codeFileSummary representation is application/vnd.sas.summary.

    Responses include the following links.

    Relation Method Description
    up GET Returns the collection to which a code file belongs.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.summary.
    Response item type: application/vnd.sas.decision.code.file.
    self GET Returns a code file by id.
    Response type: application/vnd.sas.decision.code.file.
    alternate GET Returns a code file summary by id.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes a code file by id.
    Decision Node Types

    Path: /decisionNodeTypes

    This resource provides a collection of decision node types. Default page size is 10.

    The decisionNodeTypes collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.decision.node.type resources. (These types apply to the response for the self and collection links below.)

    The GET /decisionNodeTypes response includes the following links.

    Relation Method Description
    createDecisionNodeType POST Creates a new decision node type.
    Request type: application/vnd.sas.decision.node.type
    Response type: application/vnd.sas.decision.node.type
    self GET Returns the current page of the collection in summary format.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.summary
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection
    Item type: application/vnd.sas.decision.node,type
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the decisionNodeTypess collection is by ascending creationTimeStamp.

    Filtering and sorting can use the following members of a decisionNodeTypes:

    Filter by name - ?filter=eq(name, 'DemoDecisionNodeType')

    Filter by multiple names - ?filter=in(name, 'DemoDecisionNodeType', 'DemoDecisionNodeType2')

    Filter by time value - ?filter=gt(creationTimeStamp, '2017-01-27T03%3A03%3A00Z')

    Combining filters - ?filter=and(gt(creationTimeStamp, '2017-01-27T03%3A03%3A00Z'), eq(createdBy, 'mgr10977')

    DecisionNodeType

    Path: /decisionNodeTypes/{nodeTypeId}

    This resource provides the contents of a decision node type.

    The GET /flows/{decisionId} response includes the following links.

    Relation Method Description
    self GET Returns the full representation of a decision node type.
    Response type: application/vnd.sas.decision.node.type
    delete DELETE Deletes a decision node type.
    update PUT Updates a decision node type.
    Request type: application/vnd.sas.decision.node.type
    Response type: application/vnd.sas.decision.node.type
    setContent POST Sets the content of a decision node type.
    Request type: application/vnd.sas.decision.node.type.content
    Response type: application/vnd.sas.decision.node.type.content
    content GET Sets the content of a decision node type.
    Response type: application/vnd.sas.decision.node.type.content
    decisionStepCode GET Gets the decision step code for a decision node type.
    Response type: application/vnd.sas.decision.step.code

    Treatment Definitions

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers License: SAS Institute

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Treatment Definitions API is used for creating and maintaining treatment definitions and treatment definition groups.

    Usage Notes

    Overview

    The Treatment Definitions API provides the ability to define treatment definitions and treatment definition groups. A treatment represents a response that is returned based on the result of a decision. For example, an offer determined by a decision to entice a subject to buy a product. The treatment contains name-value pairs that provide external system cues on how to act based on the result of the decision. The name-value pairs can also be used for information-only purposes for managing the treatments and to provide business context. The action determined by the treatment could be interaction with a customer, configuration of a process, or information that can be displayed to a user.

    Treatment definition groups can be added to decisions. When decisions with treatment groups are executed, they produce treatments using the code generated from the treatment definition group.

    Security

    Please see Security in SAS REST APIs for details about authentication and authorization.

    Authorization rules for the treatment definitions:

    Authorization rules for the treatment definition group:

    Terminology

    treatment

    an offer that is returned by a decision and can be sent to a subject.

    treatment definition

    the set of eligibility rules and attributes that define an offer.

    treatment definition group

    a set of treatment definitions, customized attribute values, and additional data that can be added to a decision.

    treatment definition attribute

    an attribute that is returned as a response that is based on a decision and part of a treatment.

    treatment definition group member

    a treatment definition that is part of the treatment definition group.

    attribute value mapping

    the mapping between treatment definition group variables and treatment definition attributes. Defines the source of the treatment definition attribute value.

    attribute name alias

    an alternate name for a treatment definition attribute in a treatment definition group.

    locked treatment definition revision

    the current treatment definition revision is locked when a new revision is created. The user cannot edit a locked treatment definition revision. A locked treatment definition revision cannot be unlocked.

    current treatment definition revision

    a treatment definition revision that is not in a locked state is called the current treatment definition revision. Only the current treatment definition revision is editable.

    locked treatment definition group revision

    a treatment definition group revision can be in locked state. A locked treatment definition group revision cannot be edited. A locked treatment definition group revision cannot be unlocked. The current treatment definition group revision is locked when a new revision is created.

    current treatment definition group revision

    a treatment definition group revision, which is not locked is called a current treatment definition group revision. Only the current treatment definition group revision is editable.

    active treatment definition group revision

    any locked revision of a treatment definition group can be made active. The active treatment definition group revision code is published to SAS Micro Analytic Service when activated. Only one revision is active at a time.

    rule set

    a sequenced group of related business rules that accomplish a logical business operation. See the Business Rules API for more details.

    decision

    allows users to build and retrieve a decision flow by linking statistical models in combination with deterministic logic from business rules for the purpose of integrating into an operational process. See the Decision API for more details.

    Error Codes

    HTTP Status Code Error Code Description
    200-201 94400 The eligibility end date is invalid.
    200-201 94401 The eligibility rule set is invalid.
    200-201 94402 The treatment definition attribute format is invalid.
    200-201 94403 The range is invalid for the treatment definition attribute.
    200-201 94404 The minimum is invalid for the treatment definition attribute.
    200-201 94405 The maximum is invalid for the treatment definition attribute.
    200-201 94406 The minimum length is invalid for the treatment definition attribute.
    200-201 94407 The maximum length is invalid for the treatment definition attribute.
    200-201 94408 The enum is invalid for the treatment definition attribute.
    200-201 94409 The enum value of the treatment definition attribute is invalid.
    200-201 94410 The treatment definition attribute default value is invalid.
    200-201 94411 The treatment definition group member is invalid.
    200-201 94412 The treatment definition group member attribute mapping is invalid.
    200-201 94413 The treatment definition group member attribute mapping type is invalid.
    200-201 94414 The treatment definition group member attribute mapping value is invalid.
    200-201 94415 The treatment definition group member attribute alias is invalid.
    400 1177 The data object is invalid.
    400 94416 The codeTarget parameter is invalid.
    404 1006 The resource ID is invalid.
    409 1000 An attempt to add an object as a member of a folder failed.
    428 1011 The "If-Match" header is not specified.
    412 1013 The "If-Match" header value does not match the entity tag of the resource.

    Operations

    Root

    Contains the operations for the root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns a list of top-level resource links for this API.

    Example responses

    Treatment definitions root content.

    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "treatmentDefinitions",
          "href": "/treatmentDefinition/definitions",
          "uri": "/treatmentDefinition/definitions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.treatment.definition"
        },
        {
          "method": "POST",
          "rel": "createTreatmentDefinition",
          "href": "/treatmentDefinition/definitions",
          "uri": "/treatmentDefinition/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "treatmentDefinitionGroups",
          "href": "/treatmentDefinition/definitionGroups",
          "uri": "/treatmentDefinition/definitionGroups",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "POST",
          "rel": "createTreatmentDefinitionGroup",
          "href": "/treatmentDefinition/definitionGroups",
          "uri": "/treatmentDefinition/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ]
    }
    
    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "treatmentDefinitions",
          "href": "/treatmentDefinition/definitions",
          "uri": "/treatmentDefinition/definitions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.treatment.definition"
        },
        {
          "method": "POST",
          "rel": "createTreatmentDefinition",
          "href": "/treatmentDefinition/definitions",
          "uri": "/treatmentDefinition/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "treatmentDefinitionGroups",
          "href": "/treatmentDefinition/definitionGroups",
          "uri": "/treatmentDefinition/definitionGroups",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "POST",
          "rel": "createTreatmentDefinitionGroup",
          "href": "/treatmentDefinition/definitionGroups",
          "uri": "/treatmentDefinition/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. A collection of link objects was returned. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] true none The API's top-level links.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description

    Treatment Definitions

    Contains operations to create, read, update, and delete treatment definitions.

    Get a list of all treatment definitions

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.treatment.definition+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.treatment.definition+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.treatment.definition+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.treatment.definition+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitions

    Returns a resource collection of all treatment definitions.

    Parameters
    Name In Type Required Description
    start query integer false The starting index of the first item in a page. The index is 0-based.
    limit query integer false The maximum number of items to return in this page of results. The actual number of returned items might be less if the collection has been exhausted.
    filter query string(filter-criteria) false The criteria for filtering the treatment definitions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the treatment definitions. See Sorting in REST APIs.
    Accept-Item header string(media-type) false Used for selecting the desired item representation.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.treatment.definition+json
    Accept-Item application/vnd.sas.summary+json
    Accept-Item application/vnd.sas.dcm.summary+json

    Example responses

    Treatment definitions with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "treatmentDefinition",
          "name": "My Treatment Definition",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.treatment.definition",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "name": "My Treatment Definition",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "attributes": [
            {
              "id": "8ede1bcb-18c9-4dac-b767-e78aef25f8a4",
              "name": "foo",
              "valueConstraints": [
                {
                  "dataType": "string"
                },
                {
                  "required": false
                },
                {
                  "readonly": false
                },
                {
                  "multiple": false
                },
                {
                  "range": false
                }
              ]
            },
            {
              "id": "2d80a3d5-cd67-4fd2-97fb-8e7f45b90e1e",
              "name": "bar",
              "valueConstraints": [
                {
                  "dataType": "number"
                },
                {
                  "format": "decimal"
                },
                {
                  "required": false
                },
                {
                  "readonly": false
                },
                {
                  "multiple": false
                },
                {
                  "range": false
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "folderType": "folderType",
          "sourceRevisionUri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:05.406Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with revision summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.dcm.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "name": "My Treatment Definition",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:05.406Z",
          "folderType": "myFolder",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "treatmentDefinition",
          "name": "My Treatment Definition",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.treatment.definition",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "name": "My Treatment Definition",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "attributes": [
            {
              "id": "8ede1bcb-18c9-4dac-b767-e78aef25f8a4",
              "name": "foo",
              "valueConstraints": [
                {
                  "dataType": "string"
                },
                {
                  "required": false
                },
                {
                  "readonly": false
                },
                {
                  "multiple": false
                },
                {
                  "range": false
                }
              ]
            },
            {
              "id": "2d80a3d5-cd67-4fd2-97fb-8e7f45b90e1e",
              "name": "bar",
              "valueConstraints": [
                {
                  "dataType": "number"
                },
                {
                  "format": "decimal"
                },
                {
                  "required": false
                },
                {
                  "readonly": false
                },
                {
                  "multiple": false
                },
                {
                  "range": false
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "folderType": "folderType",
          "sourceRevisionUri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:05.406Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with revision summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.dcm.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "name": "My Treatment Definition",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:05.406Z",
          "folderType": "myFolder",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema
    Enumerated Values
    Property Value
    status valid
    status error
    dataType string
    dataType number
    dataType boolean
    format date
    format datetime
    format url
    format decimal
    format integer

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new treatment definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/treatmentDefinitions/definitions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.treatment.definition+json' \
      -H 'Accept: application/vnd.sas.treatment.definition+json'
    
    
    const inputBody = '{
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.treatment.definition+json',
      'Accept':'application/vnd.sas.treatment.definition+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.treatment.definition+json',
      'Accept': 'application/vnd.sas.treatment.definition+json'
    }
    
    r = requests.post('https://example.com/treatmentDefinitions/definitions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.treatment.definition+json"},
            "Accept": []string{"application/vnd.sas.treatment.definition+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/treatmentDefinitions/definitions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /definitions

    Creates a new treatment definition based on the provided content

    Body parameter

    Treatment definition.

    {
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    fromRevisionUri query string(/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}) false This value specifies the URI of the treatment definition revision from which the new treatment definition is being created. This property enables you to trace the lineage of a treatment definition.
    body body #/paths/~1definitions/post/requestBody/content/application~1vnd.sas.treatment.definition%2Bjson/schema true Treatment details that need to be created.

    Example responses

    Treatment definition with full details.

    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "d39deb65-9e77-4340-a258-5a48f360954f",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "48cbcd9c-2517-4c1d-902a-28769751dff7",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "352b97bf-500f-435b-9358-855b5d4bb03a",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "ffabcac8-4f55-499f-b63d-5d8a52575547",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "8e67bc1d-a529-49dc-b704-9763549d43a3",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "d39deb65-9e77-4340-a258-5a48f360954f",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "48cbcd9c-2517-4c1d-902a-28769751dff7",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "352b97bf-500f-435b-9358-855b5d4bb03a",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "ffabcac8-4f55-499f-b63d-5d8a52575547",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "8e67bc1d-a529-49dc-b704-9763549d43a3",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A treatment definition was created. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 201

    Treatment Definition

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string true none The treatment definition name.
    » description string false none The treatment definition description.
    » createdBy string false none The user who created the treatment definition.
    » creationTimeStamp string(date-time) false none The date and time that the treatment definition was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the treatment definition.
    » modifiedTimeStamp string(date-time) false none The date and time that the treatment definition was last modified.
    » majorRevision integer false none Major version number of the revision being viewed of the treatment definition. 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.
    » minorRevision integer false none Minor version number of the current revision of the treatment definition. 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.
    » locked boolean false none Flag that indicates whether the content of the revision being viewed is locked or editable.
    » status string(enumeration) false none The status of the treatment definition.
    » eligibility object false none Represents the eligibility details for a treatment definition. This does not represent any of the top-level media types.
    »» ruleSetUri string false none The business rules URI that is related to eligibility.
    »» ruleSetName string false none The name of the eligibility rule set URI.
    »» startDate string(date-time) false none The date in which the treatment definition becomes eligible. The timestamp format yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of the time zone.
    »» endDate string(date-time) false none The date after which the treatment definition becomes ineligible. The timestamp yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of time zone.
    »» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» message string false none The message for the error.
    »»» id string false none The string ID for the error.
    »»» errorCode integer false none The numeric ID for the error.
    »»» httpStatusCode integer true none The HTTP status code for the error.
    »»» details [string] false none Messages that provide additional details about the cause of the error.
    »»» remediation string false none A message that describes how to resolve the error.
    »»» errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »»»» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »»»» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»»»» method string false none The HTTP method for the link.
    »»»»» rel string true none The relationship of the link to the resource.
    »»»»» uri string false none The relative URI for the link.
    »»»»» href string false none The URL for the link.
    »»»»» title string false none The title for the link.
    »»»»» type string false none The media type or link type for the link.
    »»»»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»»»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»»»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    »»» version integer true none The version number of the error representation. This representation is version 2.
    » attributes [object] false none An array of treatment definition attributes.
    »» Treatment Definition Attribute object false none Represents a treatment definition attribute. This does not represent any of the top-level media types.
    »»» id string false none The system-assigned unique ID for this object.
    »»» name string true none The treatment attribute name, which is unique within a treatment definition.
    »»» description string false none The treatment attribute description.
    »»» defaultValue any false none The default value for the attribute.

    anyOf

    Name Type Required Restrictions Description
    »»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»» valueConstraints object true none Represents the attribute value constraints for a treatment definition. This does not represent any of the top-level media types.
    »»»» dataType string(enumeration) true none The data type of this attribute value.
    »»»» format string(enumeration) false none The format of the attribute value.
    »»»» multiple boolean false none Whether the attribute value is a single value or list of values. Default is false.
    »»»» range boolean false none Whether the attribute value contains from and to values. Default is false.
    »»»» required boolean false none Whether the attribute value is required. Default is false.
    »»»» readOnly boolean false none Whether the attribute value can be changed from outside. Default is false.
    »»»» enum [anyOf] false none List of valid values for the attribute. Valid only for simple types with multiple=false and range=false. It is not valid for boolean data type.

    anyOf

    Name Type Required Restrictions Description
    »»»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»»» minimum object false none Minimum value for the attribute. Valid only for simple types with multiple=false and range=false. Valid types: decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime)
    »»»» maximum object false none Maximum value for the attribute. Only valid for simple types with multiple=false and range=false. Only valid for decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime).
    »»»» minLength integer false none Minimum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»»» maxLength integer false none Maximum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » folderType string false none Indicates the type of folder where the treatment definition is stored.
    » sourceRevisionUri string false none The URI of the treatment definition revision that the treatment definition is being created from.
    » copyTimeStamp string(date-time) false none The time stamp when the treatment definition revision was copied.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    » version integer false none This media type's schema version number. This representation is version 3.
    Enumerated Values
    Property Value
    status valid
    status error
    dataType string
    dataType number
    dataType boolean
    format date
    format datetime
    format url
    format decimal
    format integer

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Last-Modified string No description
    201 Location string No description
    201 ETag string The entity tag for the treatment definition.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get treatment definition summary

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitions/{definitionId}#summary \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitions/{definitionId}#summary',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitions/{definitionId}#summary', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitions/{definitionId}#summary", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitions/{definitionId}#summary

    Returns the summary representation of the specified treatment definition.

    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the treatment definition.

    Example responses

    Treatment definition with summary details.

    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "type": "treatmentDefinition",
      "name": "My Treatment Definition",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 2
    }
    
    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "type": "treatmentDefinition",
      "name": "My Treatment Definition",
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. resourceSummaryCollection/allOf/1/properties/items/items
    404 Not Found No treatment definition exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get a treatment definition

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitions/{definitionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.treatment.definition+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.treatment.definition+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitions/{definitionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.treatment.definition+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitions/{definitionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.treatment.definition+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitions/{definitionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitions/{definitionId}

    Returns the representation of the specified treatment definition.

    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the treatment definition.

    Example responses

    Treatment definition with full details.

    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "d39deb65-9e77-4340-a258-5a48f360954f",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "48cbcd9c-2517-4c1d-902a-28769751dff7",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "352b97bf-500f-435b-9358-855b5d4bb03a",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "ffabcac8-4f55-499f-b63d-5d8a52575547",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "8e67bc1d-a529-49dc-b704-9763549d43a3",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "d39deb65-9e77-4340-a258-5a48f360954f",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "48cbcd9c-2517-4c1d-902a-28769751dff7",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "352b97bf-500f-435b-9358-855b5d4bb03a",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "ffabcac8-4f55-499f-b63d-5d8a52575547",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "8e67bc1d-a529-49dc-b704-9763549d43a3",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No treatment definition exists at the requested path. Inline
    Response Schema

    Status Code 200

    Treatment Definition

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string true none The treatment definition name.
    » description string false none The treatment definition description.
    » createdBy string false none The user who created the treatment definition.
    » creationTimeStamp string(date-time) false none The date and time that the treatment definition was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the treatment definition.
    » modifiedTimeStamp string(date-time) false none The date and time that the treatment definition was last modified.
    » majorRevision integer false none Major version number of the revision being viewed of the treatment definition. 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.
    » minorRevision integer false none Minor version number of the current revision of the treatment definition. 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.
    » locked boolean false none Flag that indicates whether the content of the revision being viewed is locked or editable.
    » status string(enumeration) false none The status of the treatment definition.
    » eligibility object false none Represents the eligibility details for a treatment definition. This does not represent any of the top-level media types.
    »» ruleSetUri string false none The business rules URI that is related to eligibility.
    »» ruleSetName string false none The name of the eligibility rule set URI.
    »» startDate string(date-time) false none The date in which the treatment definition becomes eligible. The timestamp format yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of the time zone.
    »» endDate string(date-time) false none The date after which the treatment definition becomes ineligible. The timestamp yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of time zone.
    »» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» message string false none The message for the error.
    »»» id string false none The string ID for the error.
    »»» errorCode integer false none The numeric ID for the error.
    »»» httpStatusCode integer true none The HTTP status code for the error.
    »»» details [string] false none Messages that provide additional details about the cause of the error.
    »»» remediation string false none A message that describes how to resolve the error.
    »»» errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »»»» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »»»» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»»»» method string false none The HTTP method for the link.
    »»»»» rel string true none The relationship of the link to the resource.
    »»»»» uri string false none The relative URI for the link.
    »»»»» href string false none The URL for the link.
    »»»»» title string false none The title for the link.
    »»»»» type string false none The media type or link type for the link.
    »»»»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»»»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»»»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    »»» version integer true none The version number of the error representation. This representation is version 2.
    » attributes [object] false none An array of treatment definition attributes.
    »» Treatment Definition Attribute object false none Represents a treatment definition attribute. This does not represent any of the top-level media types.
    »»» id string false none The system-assigned unique ID for this object.
    »»» name string true none The treatment attribute name, which is unique within a treatment definition.
    »»» description string false none The treatment attribute description.
    »»» defaultValue any false none The default value for the attribute.

    anyOf

    Name Type Required Restrictions Description
    »»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»» valueConstraints object true none Represents the attribute value constraints for a treatment definition. This does not represent any of the top-level media types.
    »»»» dataType string(enumeration) true none The data type of this attribute value.
    »»»» format string(enumeration) false none The format of the attribute value.
    »»»» multiple boolean false none Whether the attribute value is a single value or list of values. Default is false.
    »»»» range boolean false none Whether the attribute value contains from and to values. Default is false.
    »»»» required boolean false none Whether the attribute value is required. Default is false.
    »»»» readOnly boolean false none Whether the attribute value can be changed from outside. Default is false.
    »»»» enum [anyOf] false none List of valid values for the attribute. Valid only for simple types with multiple=false and range=false. It is not valid for boolean data type.

    anyOf

    Name Type Required Restrictions Description
    »»»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»»» minimum object false none Minimum value for the attribute. Valid only for simple types with multiple=false and range=false. Valid types: decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime)
    »»»» maximum object false none Maximum value for the attribute. Only valid for simple types with multiple=false and range=false. Only valid for decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime).
    »»»» minLength integer false none Minimum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»»» maxLength integer false none Maximum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » folderType string false none Indicates the type of folder where the treatment definition is stored.
    » sourceRevisionUri string false none The URI of the treatment definition revision that the treatment definition is being created from.
    » copyTimeStamp string(date-time) false none The time stamp when the treatment definition revision was copied.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    » version integer false none This media type's schema version number. This representation is version 3.
    Enumerated Values
    Property Value
    status valid
    status error
    dataType string
    dataType number
    dataType boolean
    format date
    format datetime
    format url
    format decimal
    format integer

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Update a treatment definition

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/treatmentDefinitions/definitions/{definitionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.treatment.definition+json' \
      -H 'Accept: application/vnd.sas.treatment.definition+json' \
      -H 'If-Match: "kknyjgku"'
    
    
    const inputBody = '{
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.treatment.definition+json',
      'Accept':'application/vnd.sas.treatment.definition+json',
      'If-Match':'"kknyjgku"'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitions/{definitionId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.treatment.definition+json',
      'Accept': 'application/vnd.sas.treatment.definition+json',
      'If-Match': '"kknyjgku"'
    }
    
    r = requests.put('https://example.com/treatmentDefinitions/definitions/{definitionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.treatment.definition+json"},
            "Accept": []string{"application/vnd.sas.treatment.definition+json"},
            "If-Match": []string{""kknyjgku""},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/treatmentDefinitions/definitions/{definitionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /definitions/{definitionId}

    Updates the specified treatment definition based on the representation in the request body.

    Body parameter

    Treatment definition.

    {
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the treatment definition.
    If-Match header string true The entity tag obtained from the most recent ETag response header. Must match the current entity tag for the treatment definition.
    body body #/paths/~1definitions/post/requestBody/content/application~1vnd.sas.treatment.definition%2Bjson/schema true The representation of a treatment definition to use in update.

    Example responses

    Treatment definition with full details.

    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "d39deb65-9e77-4340-a258-5a48f360954f",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "48cbcd9c-2517-4c1d-902a-28769751dff7",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "352b97bf-500f-435b-9358-855b5d4bb03a",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "ffabcac8-4f55-499f-b63d-5d8a52575547",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "8e67bc1d-a529-49dc-b704-9763549d43a3",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "d39deb65-9e77-4340-a258-5a48f360954f",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "48cbcd9c-2517-4c1d-902a-28769751dff7",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "352b97bf-500f-435b-9358-855b5d4bb03a",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "ffabcac8-4f55-499f-b63d-5d8a52575547",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "8e67bc1d-a529-49dc-b704-9763549d43a3",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No treatment definition exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match precondition. Inline
    Response Schema

    Status Code 200

    Treatment Definition

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string true none The treatment definition name.
    » description string false none The treatment definition description.
    » createdBy string false none The user who created the treatment definition.
    » creationTimeStamp string(date-time) false none The date and time that the treatment definition was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the treatment definition.
    » modifiedTimeStamp string(date-time) false none The date and time that the treatment definition was last modified.
    » majorRevision integer false none Major version number of the revision being viewed of the treatment definition. 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.
    » minorRevision integer false none Minor version number of the current revision of the treatment definition. 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.
    » locked boolean false none Flag that indicates whether the content of the revision being viewed is locked or editable.
    » status string(enumeration) false none The status of the treatment definition.
    » eligibility object false none Represents the eligibility details for a treatment definition. This does not represent any of the top-level media types.
    »» ruleSetUri string false none The business rules URI that is related to eligibility.
    »» ruleSetName string false none The name of the eligibility rule set URI.
    »» startDate string(date-time) false none The date in which the treatment definition becomes eligible. The timestamp format yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of the time zone.
    »» endDate string(date-time) false none The date after which the treatment definition becomes ineligible. The timestamp yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of time zone.
    »» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» message string false none The message for the error.
    »»» id string false none The string ID for the error.
    »»» errorCode integer false none The numeric ID for the error.
    »»» httpStatusCode integer true none The HTTP status code for the error.
    »»» details [string] false none Messages that provide additional details about the cause of the error.
    »»» remediation string false none A message that describes how to resolve the error.
    »»» errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »»»» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »»»» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»»»» method string false none The HTTP method for the link.
    »»»»» rel string true none The relationship of the link to the resource.
    »»»»» uri string false none The relative URI for the link.
    »»»»» href string false none The URL for the link.
    »»»»» title string false none The title for the link.
    »»»»» type string false none The media type or link type for the link.
    »»»»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»»»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»»»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    »»» version integer true none The version number of the error representation. This representation is version 2.
    » attributes [object] false none An array of treatment definition attributes.
    »» Treatment Definition Attribute object false none Represents a treatment definition attribute. This does not represent any of the top-level media types.
    »»» id string false none The system-assigned unique ID for this object.
    »»» name string true none The treatment attribute name, which is unique within a treatment definition.
    »»» description string false none The treatment attribute description.
    »»» defaultValue any false none The default value for the attribute.

    anyOf

    Name Type Required Restrictions Description
    »»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»» valueConstraints object true none Represents the attribute value constraints for a treatment definition. This does not represent any of the top-level media types.
    »»»» dataType string(enumeration) true none The data type of this attribute value.
    »»»» format string(enumeration) false none The format of the attribute value.
    »»»» multiple boolean false none Whether the attribute value is a single value or list of values. Default is false.
    »»»» range boolean false none Whether the attribute value contains from and to values. Default is false.
    »»»» required boolean false none Whether the attribute value is required. Default is false.
    »»»» readOnly boolean false none Whether the attribute value can be changed from outside. Default is false.
    »»»» enum [anyOf] false none List of valid values for the attribute. Valid only for simple types with multiple=false and range=false. It is not valid for boolean data type.

    anyOf

    Name Type Required Restrictions Description
    »»»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»»» minimum object false none Minimum value for the attribute. Valid only for simple types with multiple=false and range=false. Valid types: decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime)
    »»»» maximum object false none Maximum value for the attribute. Only valid for simple types with multiple=false and range=false. Only valid for decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime).
    »»»» minLength integer false none Minimum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»»» maxLength integer false none Maximum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » folderType string false none Indicates the type of folder where the treatment definition is stored.
    » sourceRevisionUri string false none The URI of the treatment definition revision that the treatment definition is being created from.
    » copyTimeStamp string(date-time) false none The time stamp when the treatment definition revision was copied.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    » version integer false none This media type's schema version number. This representation is version 3.
    Enumerated Values
    Property Value
    status valid
    status error
    dataType string
    dataType number
    dataType boolean
    format date
    format datetime
    format url
    format decimal
    format integer

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    412 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    428 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a treatment definition

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/treatmentDefinitions/definitions/{definitionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/treatmentDefinitions/definitions/{definitionId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/treatmentDefinitions/definitions/{definitionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/treatmentDefinitions/definitions/{definitionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /definitions/{definitionId}

    Deletes the specified treatment definition.

    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the treatment definition.
    Responses
    Status Meaning Description Schema
    204 No Content The treatment definition was deleted. None
    Response Headers
    Status Header Type Format Description
    204 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Validate a new treatment definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/treatmentDefinitions/commons/validations/definitions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.treatment.definition+json' \
      -H 'Accept: application/vnd.sas.validation+json'
    
    
    const inputBody = '{
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.treatment.definition+json',
      'Accept':'application/vnd.sas.validation+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/commons/validations/definitions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.treatment.definition+json',
      'Accept': 'application/vnd.sas.validation+json'
    }
    
    r = requests.post('https://example.com/treatmentDefinitions/commons/validations/definitions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.treatment.definition+json"},
            "Accept": []string{"application/vnd.sas.validation+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/treatmentDefinitions/commons/validations/definitions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /commons/validations/definitions

    Determines whether a new treatment definition is valid.

    Body parameter

    Treatment definition.

    {
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    body body #/paths/~1definitions/post/requestBody/content/application~1vnd.sas.treatment.definition%2Bjson/schema true The treatment definition

    Example responses

    Validation result.

    {
      "valid": true,
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    Response Schema

    Status Code 200

    Validation Response

    Name Type Required Restrictions Description
    » version integer true none This media type's schema version number. This representation is version 1.
    » valid boolean true none true if and only if the validation was successful.
    » error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »» message string false none The message for the error.
    »» id string false none The string ID for the error.
    »» errorCode integer false none The numeric ID for the error.
    »» httpStatusCode integer true none The HTTP status code for the error.
    »» details [string] false none Messages that provide additional details about the cause of the error.
    »» remediation string false none A message that describes how to resolve the error.
    »» errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »»» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »» links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »»» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»»» method string false none The HTTP method for the link.
    »»»» rel string true none The relationship of the link to the resource.
    »»»» uri string false none The relative URI for the link.
    »»»» href string false none The URL for the link.
    »»»» title string false none The title for the link.
    »»»» type string false none The media type or link type for the link.
    »»»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    »» version integer true none The version number of the error representation. This representation is version 2.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none An array of links to related resources and actions.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Validate an update to treatment definition

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/treatmentDefinitions/commons/validations/definitions/{definitionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.treatment.definition+json' \
      -H 'Accept: application/vnd.sas.validation+json' \
      -H 'If-Match: "kknyjgku"'
    
    
    const inputBody = '{
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.treatment.definition+json',
      'Accept':'application/vnd.sas.validation+json',
      'If-Match':'"kknyjgku"'
    };
    
    fetch('https://example.com/treatmentDefinitions/commons/validations/definitions/{definitionId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.treatment.definition+json',
      'Accept': 'application/vnd.sas.validation+json',
      'If-Match': '"kknyjgku"'
    }
    
    r = requests.put('https://example.com/treatmentDefinitions/commons/validations/definitions/{definitionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.treatment.definition+json"},
            "Accept": []string{"application/vnd.sas.validation+json"},
            "If-Match": []string{""kknyjgku""},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/treatmentDefinitions/commons/validations/definitions/{definitionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /commons/validations/definitions/{definitionId}

    Determines whether an update to treatment definition is valid.

    Body parameter

    Treatment definition.

    {
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the treatment definition.
    If-Match header string true Etag value from when the originating object was retrieved.
    body body #/paths/~1definitions/post/requestBody/content/application~1vnd.sas.treatment.definition%2Bjson/schema true The treatment definition.

    Example responses

    Validation result.

    {
      "valid": true,
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    Response Schema

    Status Code 200

    Validation Response

    Name Type Required Restrictions Description
    » version integer true none This media type's schema version number. This representation is version 1.
    » valid boolean true none true if and only if the validation was successful.
    » error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »» message string false none The message for the error.
    »» id string false none The string ID for the error.
    »» errorCode integer false none The numeric ID for the error.
    »» httpStatusCode integer true none The HTTP status code for the error.
    »» details [string] false none Messages that provide additional details about the cause of the error.
    »» remediation string false none A message that describes how to resolve the error.
    »» errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »»» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »» links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »»» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»»» method string false none The HTTP method for the link.
    »»»» rel string true none The relationship of the link to the resource.
    »»»» uri string false none The relative URI for the link.
    »»»» href string false none The URL for the link.
    »»»» title string false none The title for the link.
    »»»» type string false none The media type or link type for the link.
    »»»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    »» version integer true none The version number of the error representation. This representation is version 2.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none An array of links to related resources and actions.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Validate delete of treatment definition

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/treatmentDefinitions/commons/validations/definitions/{definitionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.validation+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.validation+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/commons/validations/definitions/{definitionId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.validation+json'
    }
    
    r = requests.delete('https://example.com/treatmentDefinitions/commons/validations/definitions/{definitionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.validation+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/treatmentDefinitions/commons/validations/definitions/{definitionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /commons/validations/definitions/{definitionId}

    Determines whether treatment definition can be deleted

    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the treatment definition.

    Example responses

    Validation result.

    {
      "valid": true,
      "version": 1
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    Response Schema

    Status Code 200

    Validation Response

    Name Type Required Restrictions Description
    » version integer true none This media type's schema version number. This representation is version 1.
    » valid boolean true none true if and only if the validation was successful.
    » error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »» message string false none The message for the error.
    »» id string false none The string ID for the error.
    »» errorCode integer false none The numeric ID for the error.
    »» httpStatusCode integer true none The HTTP status code for the error.
    »» details [string] false none Messages that provide additional details about the cause of the error.
    »» remediation string false none A message that describes how to resolve the error.
    »» errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »»» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »» links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »»» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»»» method string false none The HTTP method for the link.
    »»»» rel string true none The relationship of the link to the resource.
    »»»» uri string false none The relative URI for the link.
    »»»» href string false none The URL for the link.
    »»»» title string false none The title for the link.
    »»»» type string false none The media type or link type for the link.
    »»»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    »» version integer true none The version number of the error representation. This representation is version 2.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none An array of links to related resources and actions.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Treatment Definition Revisions

    Contains operations to create and read treatment definition revisions.

    Get all revisions for a treatment definition

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.treatment.definition+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.treatment.definition+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.treatment.definition+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.treatment.definition+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitions/{definitionId}/revisions

    Retrieves a list of all revisions that exist for a treatment definition.

    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the treatment definition.
    Accept-Item header string(media-type) false Used for selecting desired item representation.
    start query integer false Returns the index of the first revision of the specified treatment definition.
    limit query integer false Returns the maximum number of revisions of the specified treatment definition.
    filter query string(filter-criteria) false The criteria for filtering the treatment definition revisions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the treatment definition revisions. See Sorting in REST APIs.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.treatment.definition+json
    Accept-Item application/vnd.sas.summary+json
    Accept-Item application/vnd.sas.dcm.summary+json

    Example responses

    Treatment definitions with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "treatmentDefinition",
          "name": "My Treatment Definition",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.treatment.definition",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "name": "My Treatment Definition",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "attributes": [
            {
              "id": "8ede1bcb-18c9-4dac-b767-e78aef25f8a4",
              "name": "foo",
              "valueConstraints": [
                {
                  "dataType": "string"
                },
                {
                  "required": false
                },
                {
                  "readonly": false
                },
                {
                  "multiple": false
                },
                {
                  "range": false
                }
              ]
            },
            {
              "id": "2d80a3d5-cd67-4fd2-97fb-8e7f45b90e1e",
              "name": "bar",
              "valueConstraints": [
                {
                  "dataType": "number"
                },
                {
                  "format": "decimal"
                },
                {
                  "required": false
                },
                {
                  "readonly": false
                },
                {
                  "multiple": false
                },
                {
                  "range": false
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "folderType": "folderType",
          "sourceRevisionUri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:05.406Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with revision summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.dcm.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "name": "My Treatment Definition",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:05.406Z",
          "folderType": "myFolder",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "type": "treatmentDefinition",
          "name": "My Treatment Definition",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.treatment.definition",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "name": "My Treatment Definition",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "attributes": [
            {
              "id": "8ede1bcb-18c9-4dac-b767-e78aef25f8a4",
              "name": "foo",
              "valueConstraints": [
                {
                  "dataType": "string"
                },
                {
                  "required": false
                },
                {
                  "readonly": false
                },
                {
                  "multiple": false
                },
                {
                  "range": false
                }
              ]
            },
            {
              "id": "2d80a3d5-cd67-4fd2-97fb-8e7f45b90e1e",
              "name": "bar",
              "valueConstraints": [
                {
                  "dataType": "number"
                },
                {
                  "format": "decimal"
                },
                {
                  "required": false
                },
                {
                  "readonly": false
                },
                {
                  "multiple": false
                },
                {
                  "range": false
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "folderType": "folderType",
          "sourceRevisionUri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:05.406Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definitions with revision summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitions?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitions",
          "uri": "/treatmentDefinitions/definitions",
          "type": "application/vnd.sas.treatment.definition",
          "responseType": "application/vnd.sas.treatment.definition"
        }
      ],
      "name": "treatmentDefinitions",
      "accept": "application/vnd.sas.dcm.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:45:05.406Z",
          "modifiedTimeStamp": "2021-09-15T18:45:05.406Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "name": "My Treatment Definition",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:05.406Z",
          "folderType": "myFolder",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions",
              "uri": "/treatmentDefinitions/definitions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "type": "vnd.sas.treatment.definition",
              "responseType": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No treatment definition exists at the requested path. Inline
    Response Schema
    Enumerated Values
    Property Value
    status valid
    status error
    dataType string
    dataType number
    dataType boolean
    format date
    format datetime
    format url
    format decimal
    format integer

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create revision of a treatment definition

    Code samples

    # You can also use wget
    curl -X POST https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.treatment.definition+json' \
      -H 'Accept: application/vnd.sas.treatment.definition+json'
    
    
    const inputBody = '{
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.treatment.definition+json',
      'Accept':'application/vnd.sas.treatment.definition+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.treatment.definition+json',
      'Accept': 'application/vnd.sas.treatment.definition+json'
    }
    
    r = requests.post('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.treatment.definition+json"},
            "Accept": []string{"application/vnd.sas.treatment.definition+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /definitions/{definitionId}/revisions

    Creates a new revision of a treatment definition based on the representation in the request body.

    Body parameter

    Treatment definition.

    {
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the treatment definition.
    revisionType query string false 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 treatment 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.
    fromRevisionUri query string false This value specifies the URI of the treatment definition revision this new treatment definition revision is being created from.This property allows for the lineage of a treatment definition to be traced. The valid format for this parameter is '/treatmentDefinitions/definitions/${definitionId}/revisions/${revisionId}'
    body body #/paths/~1definitions/post/requestBody/content/application~1vnd.sas.treatment.definition%2Bjson/schema true Treatment definition details that need to be created as revision.
    Enumerated Values
    Parameter Value
    revisionType major
    revisionType minor

    Example responses

    Treatment definition revision with full details.

    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "9ce585d7-898d-47d9-9441-00e2628e204f",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 1,
      "locked": false,
      "attributes": [
        {
          "id": "7955490c-a631-4326-9620-93e9627d95d0",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "a4f30206-453f-47a0-81d1-dccc840f2a55",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "7aaac9d2-1ef9-4f76-bca8-4e9f39be292f",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2cc0956b-2a0c-4d41-8829-45ed273a05f5",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2f9141df-96d3-473a-a3f6-6279c29e63a1",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "5b2743aa-374c-428c-96eb-5e4e22ba7e28",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.summary"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "9ce585d7-898d-47d9-9441-00e2628e204f",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 1,
      "locked": false,
      "attributes": [
        {
          "id": "7955490c-a631-4326-9620-93e9627d95d0",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "a4f30206-453f-47a0-81d1-dccc840f2a55",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "7aaac9d2-1ef9-4f76-bca8-4e9f39be292f",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2cc0956b-2a0c-4d41-8829-45ed273a05f5",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2f9141df-96d3-473a-a3f6-6279c29e63a1",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "5b2743aa-374c-428c-96eb-5e4e22ba7e28",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.summary"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A revision of a treatment was created. Inline
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No treatment definition exists at the requested path. Inline
    Response Schema

    Status Code 201

    Treatment Definition

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string true none The treatment definition name.
    » description string false none The treatment definition description.
    » createdBy string false none The user who created the treatment definition.
    » creationTimeStamp string(date-time) false none The date and time that the treatment definition was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the treatment definition.
    » modifiedTimeStamp string(date-time) false none The date and time that the treatment definition was last modified.
    » majorRevision integer false none Major version number of the revision being viewed of the treatment definition. 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.
    » minorRevision integer false none Minor version number of the current revision of the treatment definition. 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.
    » locked boolean false none Flag that indicates whether the content of the revision being viewed is locked or editable.
    » status string(enumeration) false none The status of the treatment definition.
    » eligibility object false none Represents the eligibility details for a treatment definition. This does not represent any of the top-level media types.
    »» ruleSetUri string false none The business rules URI that is related to eligibility.
    »» ruleSetName string false none The name of the eligibility rule set URI.
    »» startDate string(date-time) false none The date in which the treatment definition becomes eligible. The timestamp format yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of the time zone.
    »» endDate string(date-time) false none The date after which the treatment definition becomes ineligible. The timestamp yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of time zone.
    »» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» message string false none The message for the error.
    »»» id string false none The string ID for the error.
    »»» errorCode integer false none The numeric ID for the error.
    »»» httpStatusCode integer true none The HTTP status code for the error.
    »»» details [string] false none Messages that provide additional details about the cause of the error.
    »»» remediation string false none A message that describes how to resolve the error.
    »»» errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »»»» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »»»» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»»»» method string false none The HTTP method for the link.
    »»»»» rel string true none The relationship of the link to the resource.
    »»»»» uri string false none The relative URI for the link.
    »»»»» href string false none The URL for the link.
    »»»»» title string false none The title for the link.
    »»»»» type string false none The media type or link type for the link.
    »»»»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»»»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»»»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    »»» version integer true none The version number of the error representation. This representation is version 2.
    » attributes [object] false none An array of treatment definition attributes.
    »» Treatment Definition Attribute object false none Represents a treatment definition attribute. This does not represent any of the top-level media types.
    »»» id string false none The system-assigned unique ID for this object.
    »»» name string true none The treatment attribute name, which is unique within a treatment definition.
    »»» description string false none The treatment attribute description.
    »»» defaultValue any false none The default value for the attribute.

    anyOf

    Name Type Required Restrictions Description
    »»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»» valueConstraints object true none Represents the attribute value constraints for a treatment definition. This does not represent any of the top-level media types.
    »»»» dataType string(enumeration) true none The data type of this attribute value.
    »»»» format string(enumeration) false none The format of the attribute value.
    »»»» multiple boolean false none Whether the attribute value is a single value or list of values. Default is false.
    »»»» range boolean false none Whether the attribute value contains from and to values. Default is false.
    »»»» required boolean false none Whether the attribute value is required. Default is false.
    »»»» readOnly boolean false none Whether the attribute value can be changed from outside. Default is false.
    »»»» enum [anyOf] false none List of valid values for the attribute. Valid only for simple types with multiple=false and range=false. It is not valid for boolean data type.

    anyOf

    Name Type Required Restrictions Description
    »»»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»»» minimum object false none Minimum value for the attribute. Valid only for simple types with multiple=false and range=false. Valid types: decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime)
    »»»» maximum object false none Maximum value for the attribute. Only valid for simple types with multiple=false and range=false. Only valid for decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime).
    »»»» minLength integer false none Minimum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»»» maxLength integer false none Maximum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » folderType string false none Indicates the type of folder where the treatment definition is stored.
    » sourceRevisionUri string false none The URI of the treatment definition revision that the treatment definition is being created from.
    » copyTimeStamp string(date-time) false none The time stamp when the treatment definition revision was copied.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    » version integer false none This media type's schema version number. This representation is version 3.
    Enumerated Values
    Property Value
    status valid
    status error
    dataType string
    dataType number
    dataType boolean
    format date
    format datetime
    format url
    format decimal
    format integer

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Last-Modified string The timestamp when the revision of the specified treatment definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    201 Location string The URI of the revision of the specified treatment definition.
    201 ETag string The entity tag for the treatment definition revision.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get revision of treatment definition

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}#summary \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}#summary',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}#summary', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}#summary", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitions/{definitionId}/revisions/{revisionId}#summary

    Returns the summary representation of the revision of the specified treatment definition.

    Parameters
    Name In Type Required Description
    definitionId path string true The unique identifier for the treatment definition.
    revisionId path string true The unique identifier for the revision of the specified treatment definition. Delegate @current can be used to get the current revision.

    Example responses

    Treatment definition with summary details.

    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "7955490c-a631-4326-9620-93e9627d95d0",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "a4f30206-453f-47a0-81d1-dccc840f2a55",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "7aaac9d2-1ef9-4f76-bca8-4e9f39be292f",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2cc0956b-2a0c-4d41-8829-45ed273a05f5",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2f9141df-96d3-473a-a3f6-6279c29e63a1",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "5b2743aa-374c-428c-96eb-5e4e22ba7e28",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "type": "application/vnd.sas.summary"
        }
      ],
      "folderType": "myFolder",
      "sourceRevisionUri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
      "copyTimeStamp": "2021-09-15T18:45:18.114Z",
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "7955490c-a631-4326-9620-93e9627d95d0",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "a4f30206-453f-47a0-81d1-dccc840f2a55",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "7aaac9d2-1ef9-4f76-bca8-4e9f39be292f",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2cc0956b-2a0c-4d41-8829-45ed273a05f5",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2f9141df-96d3-473a-a3f6-6279c29e63a1",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "5b2743aa-374c-428c-96eb-5e4e22ba7e28",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "type": "application/vnd.sas.summary"
        }
      ],
      "folderType": "myFolder",
      "sourceRevisionUri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
      "copyTimeStamp": "2021-09-15T18:45:18.114Z",
      "version": 3,
      "status": "valid"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. resourceSummaryCollection/allOf/1/properties/items/items
    404 Not Found No treatment definition revision exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the revision of the specified treatment definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get revision of specified treatment definition

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.treatment.definition+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.treatment.definition+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.treatment.definition+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.treatment.definition+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitions/{definitionId}/revisions/{revisionId}

    Returns the representation of the specified treatment definition revision.

    Parameters
    Name In Type Required Description
    definitionId path string true Identifier for the treatment definition.
    revisionId path string true Identifier for the treatment definition revision.

    Example responses

    Treatment definition revision with full details.

    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "9ce585d7-898d-47d9-9441-00e2628e204f",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 1,
      "locked": false,
      "attributes": [
        {
          "id": "7955490c-a631-4326-9620-93e9627d95d0",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "a4f30206-453f-47a0-81d1-dccc840f2a55",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "7aaac9d2-1ef9-4f76-bca8-4e9f39be292f",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2cc0956b-2a0c-4d41-8829-45ed273a05f5",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2f9141df-96d3-473a-a3f6-6279c29e63a1",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "5b2743aa-374c-428c-96eb-5e4e22ba7e28",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.summary"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Treatment definition resource summary.

    {
      "creationTimeStamp": "2021-09-15T18:45:18.114Z",
      "modifiedTimeStamp": "2021-09-15T18:45:18.114Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "26fcf4ca-d37e-4613-8b75-bf09add09003",
      "name": "Treatment_4",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "a7ebea09-da95-4fd0-bbc7-934006e21aa1",
          "name": "foo",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "type": "application/vnd.sas.summary"
        }
      ],
      "folderType": "myFolder",
      "sourceRevisionUri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
      "copyTimeStamp": "2021-09-15T18:45:18.114Z",
      "version": 3,
      "status": "valid"
    }
    

    Treatment definition revision summary.

    {
      "creationTimeStamp": "2021-09-15T18:45:18.114Z",
      "modifiedTimeStamp": "2021-09-15T18:45:18.114Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "26fcf4ca-d37e-4613-8b75-bf09add09003",
      "name": "Treatment_4",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "attributes": [
        {
          "id": "a7ebea09-da95-4fd0-bbc7-934006e21aa1",
          "name": "foo",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
          "type": "application/vnd.sas.summary"
        }
      ],
      "folderType": "myFolder",
      "sourceRevisionUri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
      "copyTimeStamp": "2021-09-15T18:45:18.114Z",
      "version": 3,
      "status": "valid"
    }
    

    Treatment definition revision with full details.

    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "9ce585d7-898d-47d9-9441-00e2628e204f",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 1,
      "locked": false,
      "attributes": [
        {
          "id": "7955490c-a631-4326-9620-93e9627d95d0",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "a4f30206-453f-47a0-81d1-dccc840f2a55",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "7aaac9d2-1ef9-4f76-bca8-4e9f39be292f",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2cc0956b-2a0c-4d41-8829-45ed273a05f5",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2f9141df-96d3-473a-a3f6-6279c29e63a1",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "5b2743aa-374c-428c-96eb-5e4e22ba7e28",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.summary"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No revision of the specified treatment definition exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the revision of the specified treatment definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition revision.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a treatment definition revision

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/treatmentDefinitions/definitions/{definitionId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /definitions/{definitionId}/revisions/{revisionId}

    Deletes the specified treatment definition revision.

    Parameters
    Name In Type Required Description
    definitionId path string true Identifier for the treatment definition.
    revisionId path string true Identifier for the treatment definition revision.
    Responses
    Status Meaning Description Schema
    204 No Content The treatment definition revision was deleted. None
    Response Headers
    Status Header Type Format Description
    204 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Treatment Definition Groups

    Contains operations to create, read, update, and delete treatment definition groups.

    Get a list of all treatment definition groups

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.treatment.definition.group+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.treatment.definition.group+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.treatment.definition.group+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.treatment.definition.group+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups

    Returns a resource collection of all treatment definition groups.

    Parameters
    Name In Type Required Description
    start query integer false The starting index of the first item in a page. The index is 0-based.
    limit query integer false The maximum number of items to return in this page of results. The actual number of returned items might be less if the collection has been exhausted.
    filter query string(filter-criteria) false The criteria for filtering the treatment definitions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the treatment definitions. See Sorting in REST APIs.
    Accept-Item header string(media-type) false Used for selecting the desired item representation.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.treatment.definition.group+json
    Accept-Item application/vnd.sas.summary+json
    Accept-Item application/vnd.sas.dcm.summary+json

    Example responses

    Treatment definition groups with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:34:43.865Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "treatmentGroup",
          "name": "My Treatment Definition Group",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "last",
          "href": "/treatmentDefinitions/definitionGroups?start=5&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=5&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.treatment.definition.group",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:32.293Z",
          "modifiedTimeStamp": "2021-09-16T18:35:00.765Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "2a772249-b4d5-4f39-bbad-b39562a090fb",
          "name": "Treatment_Group_3",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "members": [
            {
              "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
              "definitionName": "Treatment_2",
              "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
              "definitionRevisionName": "1.0"
            },
            {
              "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
              "definitionName": "Treatment_1",
              "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "definitionRevisionName": "1.0",
              "attributeValueMappings": [
                {
                  "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
                  "attributeName": "rate",
                  "mappingType": "variable",
                  "value": "rate"
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "folderType": "myFolder",
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/6b6c3b00-97ec-4f26-8921-5c26e06a437d/revisions/7e8223e2-08fa-45ea-ba54-317328f112a5",
          "copyTimeStamp": "2021-09-16T18:34:32.293Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with revision summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.dcm.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:35:11.585Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
          "name": "Treatment_Group_4",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
          "copyTimeStamp": "2021-09-16T18:34:43.865Z",
          "folderType": "myFolder",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:34:43.865Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "treatmentGroup",
          "name": "My Treatment Definition Group",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "last",
          "href": "/treatmentDefinitions/definitionGroups?start=5&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=5&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.treatment.definition.group",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:32.293Z",
          "modifiedTimeStamp": "2021-09-16T18:35:00.765Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "2a772249-b4d5-4f39-bbad-b39562a090fb",
          "name": "Treatment_Group_3",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "members": [
            {
              "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
              "definitionName": "Treatment_2",
              "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
              "definitionRevisionName": "1.0"
            },
            {
              "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
              "definitionName": "Treatment_1",
              "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "definitionRevisionName": "1.0",
              "attributeValueMappings": [
                {
                  "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
                  "attributeName": "rate",
                  "mappingType": "variable",
                  "value": "rate"
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "folderType": "myFolder",
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/6b6c3b00-97ec-4f26-8921-5c26e06a437d/revisions/7e8223e2-08fa-45ea-ba54-317328f112a5",
          "copyTimeStamp": "2021-09-16T18:34:32.293Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with revision summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.dcm.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:35:11.585Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
          "name": "Treatment_Group_4",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
          "copyTimeStamp": "2021-09-16T18:34:43.865Z",
          "folderType": "myFolder",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema
    Enumerated Values
    Property Value
    activationStatus active
    activationStatus inactive
    activationStatus pending
    activationStatus running
    activationStatus cancelled
    activationStatus timedOut
    activationStatus failed
    status valid
    status error
    mappingType variable
    mappingType constant

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new treatment definition group

    Code samples

    # You can also use wget
    curl -X POST https://example.com/treatmentDefinitions/definitionGroups \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.treatment.definition.group+json' \
      -H 'Accept: application/vnd.sas.treatment.definition.group+json'
    
    
    const inputBody = '{
      "name": "My Treatment Definition Group",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1"
        },
        {
          "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692",
          "definitionRevisionId": "f813702e-dff8-443e-a7af-727ab027fb7e",
          "attributeValueMappings": [
            {
              "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "7c17cbaf-dd3d-4288-b6a9-54ae7c7c91c6",
              "mappingType": "constant",
              "value": "Samsung"
            },
            {
              "attributeId": "a0a3b4d4-fc28-4194-84dd-fe2dc3286009",
              "mappingType": "variable",
              "value": "Clicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
              "aliasName": "Discount ID"
            }
          ]
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.treatment.definition.group+json',
      'Accept':'application/vnd.sas.treatment.definition.group+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.treatment.definition.group+json',
      'Accept': 'application/vnd.sas.treatment.definition.group+json'
    }
    
    r = requests.post('https://example.com/treatmentDefinitions/definitionGroups', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.treatment.definition.group+json"},
            "Accept": []string{"application/vnd.sas.treatment.definition.group+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/treatmentDefinitions/definitionGroups", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /definitionGroups

    Creates a new treatment definition group based on the provided content

    Body parameter

    Treatment definition group.

    {
      "name": "My Treatment Definition Group",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1"
        },
        {
          "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692",
          "definitionRevisionId": "f813702e-dff8-443e-a7af-727ab027fb7e",
          "attributeValueMappings": [
            {
              "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "7c17cbaf-dd3d-4288-b6a9-54ae7c7c91c6",
              "mappingType": "constant",
              "value": "Samsung"
            },
            {
              "attributeId": "a0a3b4d4-fc28-4194-84dd-fe2dc3286009",
              "mappingType": "variable",
              "value": "Clicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
              "aliasName": "Discount ID"
            }
          ]
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    fromRevisionUri query string(/treatmentDefinitions/definitionGroups/{definitionId}/revisions/{revisionId}) false This value specifies the URI of the treatment definition revision from which the new treatment definition is being created. This property enables you to trace the lineage of a treatment definition.
    body body treatmentDefinitionGroupCollection true Treatment definition group details that need to be created.

    Example responses

    Treatment definition group with full details.

    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.094Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "625e99fd-4d8a-4ee2-b201-4fd3c062169f",
      "name": "My Treatment Definition Group",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0"
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "a6d2bfda-6fd3-4549-8613-e9b1d192b39b",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
              "attributeName": "Discount",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "d39deb65-9e77-4340-a258-5a48f360954f",
              "attributeName": "Product",
              "mappingType": "variable",
              "value": "Product"
            },
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "mappingType": "variable",
              "value": "Offertext"
            },
            {
              "attributeId": "352b97bf-500f-435b-9358-855b5d4bb03a",
              "attributeName": "Budget",
              "mappingType": "variable",
              "value": "Budget"
            },
            {
              "attributeId": "ffabcac8-4f55-499f-b63d-5d8a52575547",
              "attributeName": "Goal",
              "mappingType": "variable",
              "value": "Goal"
            },
            {
              "attributeId": "8e67bc1d-a529-49dc-b704-9763549d43a3",
              "attributeName": "TimesClicked",
              "mappingType": "variable",
              "value": "TimesClicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "aliasName": "Offer Text"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.094Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "625e99fd-4d8a-4ee2-b201-4fd3c062169f",
      "name": "My Treatment Definition Group",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0"
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "a6d2bfda-6fd3-4549-8613-e9b1d192b39b",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
              "attributeName": "Discount",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "d39deb65-9e77-4340-a258-5a48f360954f",
              "attributeName": "Product",
              "mappingType": "variable",
              "value": "Product"
            },
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "mappingType": "variable",
              "value": "Offertext"
            },
            {
              "attributeId": "352b97bf-500f-435b-9358-855b5d4bb03a",
              "attributeName": "Budget",
              "mappingType": "variable",
              "value": "Budget"
            },
            {
              "attributeId": "ffabcac8-4f55-499f-b63d-5d8a52575547",
              "attributeName": "Goal",
              "mappingType": "variable",
              "value": "Goal"
            },
            {
              "attributeId": "8e67bc1d-a529-49dc-b704-9763549d43a3",
              "attributeName": "TimesClicked",
              "mappingType": "variable",
              "value": "TimesClicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "aliasName": "Offer Text"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A treatment definition group was created. treatmentDefinitionGroupCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Last-Modified string The timestamp when the treatment definition group was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    201 Location string The URI of the treatment definition group.
    201 ETag string The entity tag for the treatment definition group.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get treatment definition group summary

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups/{groupId}#summary \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}#summary',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups/{groupId}#summary', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}#summary", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups/{groupId}#summary

    Returns the summary representation of the specified treatment definition group.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.

    Example responses

    Treatment definition group with summary details.

    {
      "creationTimeStamp": "2021-09-16T18:34:43.865Z",
      "modifiedTimeStamp": "2021-09-16T18:35:11.585Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
      "name": "My Treatment Group",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": 1
        },
        {
          "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
          "definitionName": "Treatment_1",
          "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "definitionRevisionName": 1,
          "attributeValueMappings": [
            {
              "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
              "attributeName": "rate",
              "mappingType": "variable",
              "value": "rate"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "folderType": "myFolder",
      "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
      "copyTimeStamp": "2021-09-16T18:34:43.865Z",
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-16T18:34:43.865Z",
      "modifiedTimeStamp": "2021-09-16T18:35:11.585Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
      "name": "My Treatment Group",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": 1
        },
        {
          "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
          "definitionName": "Treatment_1",
          "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "definitionRevisionName": 1,
          "attributeValueMappings": [
            {
              "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
              "attributeName": "rate",
              "mappingType": "variable",
              "value": "rate"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "folderType": "myFolder",
      "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
      "copyTimeStamp": "2021-09-16T18:34:43.865Z",
      "version": 3,
      "status": "valid"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. resourceSummaryCollection/allOf/1/properties/items/items
    404 Not Found No treatment definition group exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition group.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get a treatment definition group

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups/{groupId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.treatment.definition.group+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.treatment.definition.group+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.treatment.definition.group+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups/{groupId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.treatment.definition.group+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups/{groupId}

    Returns the representation of the specified treatment definition group.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.

    Example responses

    Treatment definition group with full details.

    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.094Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "625e99fd-4d8a-4ee2-b201-4fd3c062169f",
      "name": "My Treatment Definition Group",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0"
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "a6d2bfda-6fd3-4549-8613-e9b1d192b39b",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
              "attributeName": "Discount",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "d39deb65-9e77-4340-a258-5a48f360954f",
              "attributeName": "Product",
              "mappingType": "variable",
              "value": "Product"
            },
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "mappingType": "variable",
              "value": "Offertext"
            },
            {
              "attributeId": "352b97bf-500f-435b-9358-855b5d4bb03a",
              "attributeName": "Budget",
              "mappingType": "variable",
              "value": "Budget"
            },
            {
              "attributeId": "ffabcac8-4f55-499f-b63d-5d8a52575547",
              "attributeName": "Goal",
              "mappingType": "variable",
              "value": "Goal"
            },
            {
              "attributeId": "8e67bc1d-a529-49dc-b704-9763549d43a3",
              "attributeName": "TimesClicked",
              "mappingType": "variable",
              "value": "TimesClicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "aliasName": "Offer Text"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.094Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "625e99fd-4d8a-4ee2-b201-4fd3c062169f",
      "name": "My Treatment Definition Group",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0"
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "a6d2bfda-6fd3-4549-8613-e9b1d192b39b",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
              "attributeName": "Discount",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "d39deb65-9e77-4340-a258-5a48f360954f",
              "attributeName": "Product",
              "mappingType": "variable",
              "value": "Product"
            },
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "mappingType": "variable",
              "value": "Offertext"
            },
            {
              "attributeId": "352b97bf-500f-435b-9358-855b5d4bb03a",
              "attributeName": "Budget",
              "mappingType": "variable",
              "value": "Budget"
            },
            {
              "attributeId": "ffabcac8-4f55-499f-b63d-5d8a52575547",
              "attributeName": "Goal",
              "mappingType": "variable",
              "value": "Goal"
            },
            {
              "attributeId": "8e67bc1d-a529-49dc-b704-9763549d43a3",
              "attributeName": "TimesClicked",
              "mappingType": "variable",
              "value": "TimesClicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "aliasName": "Offer Text"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. treatmentDefinitionGroupCollection
    404 Not Found No treatment definition group exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatmentDefinitionGroup was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition group.

    Update a treatment definition group

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/treatmentDefinitions/definitionGroups/{groupId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.treatment.definition.group+json' \
      -H 'Accept: application/vnd.sas.treatment.definition.group+json' \
      -H 'If-Match: "kknyjgku"'
    
    
    const inputBody = '{
      "name": "My Treatment Definition Group",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1"
        },
        {
          "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692",
          "definitionRevisionId": "f813702e-dff8-443e-a7af-727ab027fb7e",
          "attributeValueMappings": [
            {
              "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "7c17cbaf-dd3d-4288-b6a9-54ae7c7c91c6",
              "mappingType": "constant",
              "value": "Samsung"
            },
            {
              "attributeId": "a0a3b4d4-fc28-4194-84dd-fe2dc3286009",
              "mappingType": "variable",
              "value": "Clicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
              "aliasName": "Discount ID"
            }
          ]
        }
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.treatment.definition.group+json',
      'Accept':'application/vnd.sas.treatment.definition.group+json',
      'If-Match':'"kknyjgku"'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.treatment.definition.group+json',
      'Accept': 'application/vnd.sas.treatment.definition.group+json',
      'If-Match': '"kknyjgku"'
    }
    
    r = requests.put('https://example.com/treatmentDefinitions/definitionGroups/{groupId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.treatment.definition.group+json"},
            "Accept": []string{"application/vnd.sas.treatment.definition.group+json"},
            "If-Match": []string{""kknyjgku""},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /definitionGroups/{groupId}

    Updates the specified treatment definition group based on the representation in the request body.

    Body parameter

    Treatment definition group.

    {
      "name": "My Treatment Definition Group",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1"
        },
        {
          "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692",
          "definitionRevisionId": "f813702e-dff8-443e-a7af-727ab027fb7e",
          "attributeValueMappings": [
            {
              "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "7c17cbaf-dd3d-4288-b6a9-54ae7c7c91c6",
              "mappingType": "constant",
              "value": "Samsung"
            },
            {
              "attributeId": "a0a3b4d4-fc28-4194-84dd-fe2dc3286009",
              "mappingType": "variable",
              "value": "Clicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
              "aliasName": "Discount ID"
            }
          ]
        }
      ]
    }
    
    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    If-Match header string true Etag of content payload that was updated.
    body body treatmentDefinitionGroupCollection true The representation of a treatment definition group.

    Example responses

    Treatment definition group with full details.

    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.094Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "625e99fd-4d8a-4ee2-b201-4fd3c062169f",
      "name": "My Treatment Definition Group",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0"
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "a6d2bfda-6fd3-4549-8613-e9b1d192b39b",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
              "attributeName": "Discount",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "d39deb65-9e77-4340-a258-5a48f360954f",
              "attributeName": "Product",
              "mappingType": "variable",
              "value": "Product"
            },
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "mappingType": "variable",
              "value": "Offertext"
            },
            {
              "attributeId": "352b97bf-500f-435b-9358-855b5d4bb03a",
              "attributeName": "Budget",
              "mappingType": "variable",
              "value": "Budget"
            },
            {
              "attributeId": "ffabcac8-4f55-499f-b63d-5d8a52575547",
              "attributeName": "Goal",
              "mappingType": "variable",
              "value": "Goal"
            },
            {
              "attributeId": "8e67bc1d-a529-49dc-b704-9763549d43a3",
              "attributeName": "TimesClicked",
              "mappingType": "variable",
              "value": "TimesClicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "aliasName": "Offer Text"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.094Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "625e99fd-4d8a-4ee2-b201-4fd3c062169f",
      "name": "My Treatment Definition Group",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": false,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0"
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "a6d2bfda-6fd3-4549-8613-e9b1d192b39b",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
              "attributeName": "Discount",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "d39deb65-9e77-4340-a258-5a48f360954f",
              "attributeName": "Product",
              "mappingType": "variable",
              "value": "Product"
            },
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "mappingType": "variable",
              "value": "Offertext"
            },
            {
              "attributeId": "352b97bf-500f-435b-9358-855b5d4bb03a",
              "attributeName": "Budget",
              "mappingType": "variable",
              "value": "Budget"
            },
            {
              "attributeId": "ffabcac8-4f55-499f-b63d-5d8a52575547",
              "attributeName": "Goal",
              "mappingType": "variable",
              "value": "Goal"
            },
            {
              "attributeId": "8e67bc1d-a529-49dc-b704-9763549d43a3",
              "attributeName": "TimesClicked",
              "mappingType": "variable",
              "value": "TimesClicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
              "attributeName": "Offertext",
              "aliasName": "Offer Text"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "revisions",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. treatmentDefinitionGroupCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No treatment definition group exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition group was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition group.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    412 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    428 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a treatment definition group

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/treatmentDefinitions/definitionGroups/{groupId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/treatmentDefinitions/definitionGroups/{groupId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /definitionGroups/{groupId}

    Deletes the specified treatment definition group.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    Responses
    Status Meaning Description Schema
    204 No Content The treatment definition group was deleted. None
    Response Headers
    Status Header Type Format Description
    204 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Treatment Definition Group Revisions

    Contains operations to create and read treatment definition group revisions.

    Get revisions across treatment definitions

    Code samples

    # You can also use wget
    curl -X POST https://example.com/treatmentDefinitions/definitionRevisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.selection+json' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.treatment.definition+json'
    
    
    const inputBody = '{
      "type": "id",
      "resources": [
        "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
        "26fcf4ca-d37e-4613-8b75-bf09add09003"
      ],
      "version": 1
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.selection+json',
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.treatment.definition+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionRevisions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.selection+json',
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.treatment.definition+json'
    }
    
    r = requests.post('https://example.com/treatmentDefinitions/definitionRevisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.selection+json"},
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.treatment.definition+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/treatmentDefinitions/definitionRevisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /definitionRevisions

    Returns a list of the treatment definition revisions based on the list of resource IDs.

    Body parameter

    Treatment definition with selection.

    {
      "type": "id",
      "resources": [
        "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
        "26fcf4ca-d37e-4613-8b75-bf09add09003"
      ],
      "version": 1
    }
    
    Parameters
    Name In Type Required Description
    Accept-Item header string(media-type) false Used for selecting desired item representation.
    start query integer false Returns the index of the first revision of the specified treatment definition.
    limit query integer false Returns the maximum number of revisions of the specified treatment definition.
    body body #/paths/~1definitionRevisions/post/requestBody/content/application~1vnd.sas.selection%2Bjson/schema true Select resource IDs for which details of the treatment definition are to be found.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.treatment.definition+json
    Accept-Item application/vnd.sas.summary+json
    Accept-Item application/vnd.sas.dcm.summary+json

    Example responses

    Treatment definition revision selection.

    {
      "links": [
        {
          "method": "POST",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionRevisions",
          "uri": "/treatmentDefinitions/definitionRevisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionRevisions?start=0&limit=10",
          "uri": "/treatmentDefinitions/definitionRevisions?start=0&limit=10",
          "type": "application/vnd.sas.collection",
          "name": "treatmentDefinitionRevisions"
        }
      ],
      "accept": "application/vnd.sas.treatment.definition",
      "start": 0,
      "count": 2,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:17:53.758Z",
          "modifiedTimeStamp": "2021-09-15T18:17:53.758Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "name": "Treatment_1",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "attributes": [
            {
              "id": "3064402c-b83f-4c43-baa7-e68c28028e2a",
              "name": "foo",
              "valueConstraints": {
                "dataType": "string",
                "required": false,
                "readOnly": false,
                "multiple": false,
                "range": false
              }
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions",
              "uri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "uri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "uri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "type": "application/vnd.sas.summary"
            }
          ],
          "folderType": "myFolder",
          "version": 3,
          "status": "valid"
        },
        {
          "creationTimeStamp": "2021-09-15T18:45:18.114Z",
          "modifiedTimeStamp": "2021-09-15T18:45:18.114Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "26fcf4ca-d37e-4613-8b75-bf09add09003",
          "name": "Treatment_4",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "attributes": [
            {
              "id": "a7ebea09-da95-4fd0-bbc7-934006e21aa1",
              "name": "foo",
              "valueConstraints": {
                "dataType": "string",
                "required": false,
                "readOnly": false,
                "multiple": false,
                "range": false
              }
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
              "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
              "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
              "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
              "type": "application/vnd.sas.summary"
            }
          ],
          "folderType": "myFolder",
          "sourceRevisionUri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:18.114Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 10,
      "version": 2
    }
    
    {
      "links": [
        {
          "method": "POST",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionRevisions",
          "uri": "/treatmentDefinitions/definitionRevisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionRevisions?start=0&limit=10",
          "uri": "/treatmentDefinitions/definitionRevisions?start=0&limit=10",
          "type": "application/vnd.sas.collection",
          "name": "treatmentDefinitionRevisions"
        }
      ],
      "accept": "application/vnd.sas.treatment.definition",
      "start": 0,
      "count": 2,
      "items": [
        {
          "creationTimeStamp": "2021-09-15T18:17:53.758Z",
          "modifiedTimeStamp": "2021-09-15T18:17:53.758Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "name": "Treatment_1",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "attributes": [
            {
              "id": "3064402c-b83f-4c43-baa7-e68c28028e2a",
              "name": "foo",
              "valueConstraints": {
                "dataType": "string",
                "required": false,
                "readOnly": false,
                "multiple": false,
                "range": false
              }
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions",
              "uri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "uri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "uri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "type": "application/vnd.sas.summary"
            }
          ],
          "folderType": "myFolder",
          "version": 3,
          "status": "valid"
        },
        {
          "creationTimeStamp": "2021-09-15T18:45:18.114Z",
          "modifiedTimeStamp": "2021-09-15T18:45:18.114Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "26fcf4ca-d37e-4613-8b75-bf09add09003",
          "name": "Treatment_4",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "attributes": [
            {
              "id": "a7ebea09-da95-4fd0-bbc7-934006e21aa1",
              "name": "foo",
              "valueConstraints": {
                "dataType": "string",
                "required": false,
                "readOnly": false,
                "multiple": false,
                "range": false
              }
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
              "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
              "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
              "type": "application/vnd.sas.treatment.definition"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
              "uri": "/treatmentDefinitions/definitions/cf5a5a55-052b-4f58-83e5-8a10d3d86bfd/revisions/26fcf4ca-d37e-4613-8b75-bf09add09003",
              "type": "application/vnd.sas.summary"
            }
          ],
          "folderType": "myFolder",
          "sourceRevisionUri": "/treatmentDefinitions/definitions/8c21e6e2-a2e7-4296-a11a-ad19d2c40852/revisions/b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "copyTimeStamp": "2021-09-15T18:45:18.114Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 10,
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema
    Enumerated Values
    Property Value
    status valid
    status error
    dataType string
    dataType number
    dataType boolean
    format date
    format datetime
    format url
    format decimal
    format integer

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get all revisions for a treatment definition group

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups/{groupId}/revisions

    Retrieves a list of all revisions that exist for a treatment definition group.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    Accept-Item header string(media-type) false Used for selecting the desired item representation.
    start query integer false Returns the index of the first revision of the specified treatment definition group.
    limit query integer false Returns the maximum number of revisions of the specified treatment definition group.
    filter query string(filter-criteria) false The criteria for filtering the treatment definition group revisions. See Filtering in REST APIs.
    sortBy query string(sort-criteria) false The criteria for sorting the treatment definition group revisions. See Sorting in REST APIs.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.treatment.definition.group+json
    Accept-Item application/vnd.sas.summary+json
    Accept-Item application/vnd.sas.dcm.summary+json

    Example responses

    Treatment definition groups with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:34:43.865Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "treatmentGroup",
          "name": "My Treatment Definition Group",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "last",
          "href": "/treatmentDefinitions/definitionGroups?start=5&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=5&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.treatment.definition.group",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:32.293Z",
          "modifiedTimeStamp": "2021-09-16T18:35:00.765Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "2a772249-b4d5-4f39-bbad-b39562a090fb",
          "name": "Treatment_Group_3",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "members": [
            {
              "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
              "definitionName": "Treatment_2",
              "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
              "definitionRevisionName": "1.0"
            },
            {
              "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
              "definitionName": "Treatment_1",
              "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "definitionRevisionName": "1.0",
              "attributeValueMappings": [
                {
                  "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
                  "attributeName": "rate",
                  "mappingType": "variable",
                  "value": "rate"
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "folderType": "myFolder",
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/6b6c3b00-97ec-4f26-8921-5c26e06a437d/revisions/7e8223e2-08fa-45ea-ba54-317328f112a5",
          "copyTimeStamp": "2021-09-16T18:34:32.293Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with revision summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.dcm.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:35:11.585Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
          "name": "Treatment_Group_4",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
          "copyTimeStamp": "2021-09-16T18:34:43.865Z",
          "folderType": "myFolder",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with resource summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=2&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=name&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=name&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:34:43.865Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
          "type": "treatmentGroup",
          "name": "My Treatment Definition Group",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 2
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with full details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "last",
          "href": "/treatmentDefinitions/definitionGroups?start=5&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?start=5&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.treatment.definition.group",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:32.293Z",
          "modifiedTimeStamp": "2021-09-16T18:35:00.765Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "2a772249-b4d5-4f39-bbad-b39562a090fb",
          "name": "Treatment_Group_3",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "members": [
            {
              "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
              "definitionName": "Treatment_2",
              "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
              "definitionRevisionName": "1.0"
            },
            {
              "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
              "definitionName": "Treatment_1",
              "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "definitionRevisionName": "1.0",
              "attributeValueMappings": [
                {
                  "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
                  "attributeName": "rate",
                  "mappingType": "variable",
                  "value": "rate"
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/2a772249-b4d5-4f39-bbad-b39562a090fb/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "folderType": "myFolder",
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/6b6c3b00-97ec-4f26-8921-5c26e06a437d/revisions/7e8223e2-08fa-45ea-ba54-317328f112a5",
          "copyTimeStamp": "2021-09-16T18:34:32.293Z",
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Treatment definition groups with revision summary details.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=2&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=2&limit=1",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "first",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=0&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=0&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "prev",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=1&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=1&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=3&limit=1",
          "uri": "/treatmentDefinitions/definitionGroups?sortBy=modifiedTimeStamp:descending&start=3&limit=1",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.dcm.summary"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/treatmentDefinitions/definitionGroups",
          "uri": "/treatmentDefinitions/definitionGroups",
          "type": "application/vnd.sas.treatment.definition.group",
          "responseType": "application/vnd.sas.treatment.definition.group"
        }
      ],
      "name": "treatmentDefinitionGroups",
      "accept": "application/vnd.sas.dcm.summary",
      "start": 2,
      "count": 5,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:35:11.585Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "d738c763-6d1f-4980-a3ec-b57dda234179",
          "name": "Treatment_Group_4",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
          "copyTimeStamp": "2021-09-16T18:34:43.865Z",
          "folderType": "myFolder",
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups",
              "uri": "/treatmentDefinitions/definitionGroups",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.summary"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179",
              "type": "application/vnd.sas.treatment.definition.group",
              "responseType": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "revisions",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            }
          ],
          "version": 1
        }
      ],
      "limit": 1,
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema
    Enumerated Values
    Property Value
    activationStatus active
    activationStatus inactive
    activationStatus pending
    activationStatus running
    activationStatus cancelled
    activationStatus timedOut
    activationStatus failed
    status valid
    status error
    mappingType variable
    mappingType constant

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new revision of a treatment definition group

    Code samples

    # You can also use wget
    curl -X POST https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.treatment.definition.group+json' \
      -H 'Accept: application/vnd.sas.treatment.definition.group+json'
    
    
    const inputBody = '{
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.treatment.definition.group+json',
      'Accept':'application/vnd.sas.treatment.definition.group+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.treatment.definition.group+json',
      'Accept': 'application/vnd.sas.treatment.definition.group+json'
    }
    
    r = requests.post('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.treatment.definition.group+json"},
            "Accept": []string{"application/vnd.sas.treatment.definition.group+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /definitionGroups/{groupId}/revisions

    Creates a new revision of a treatment definition group based on the representation in the request body.

    Body parameter

    Treatment definition.

    {
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer"
          }
        }
      ],
      "version": 2
    }
    
    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    revisionType query string false 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 treatment definition group 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.
    fromRevisionUri query string false This value specifies the URI of the treatment definition group revision this new treatment definition group revision is being created from. This property allows for the lineage of a treatment definition group to be traced. The valid format for this parameter is '/treatmentDefinitions/definitionGroups/${groupId}/revisions/${revisionId}'
    body body treatmentDefinitionGroupCollection true Treatment definition group details that must be created as a revision.
    Enumerated Values
    Parameter Value
    revisionType major
    revisionType minor

    Example responses

    Treatment definition revision with full details.

    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "9ce585d7-898d-47d9-9441-00e2628e204f",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 1,
      "locked": false,
      "attributes": [
        {
          "id": "7955490c-a631-4326-9620-93e9627d95d0",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "a4f30206-453f-47a0-81d1-dccc840f2a55",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "7aaac9d2-1ef9-4f76-bca8-4e9f39be292f",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2cc0956b-2a0c-4d41-8829-45ed273a05f5",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2f9141df-96d3-473a-a3f6-6279c29e63a1",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "5b2743aa-374c-428c-96eb-5e4e22ba7e28",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.summary"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-15T20:52:08.565Z",
      "modifiedTimeStamp": "2021-09-15T20:52:08.567Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "9ce585d7-898d-47d9-9441-00e2628e204f",
      "name": "My Treatment Definition",
      "majorRevision": 1,
      "minorRevision": 1,
      "locked": false,
      "attributes": [
        {
          "id": "7955490c-a631-4326-9620-93e9627d95d0",
          "name": "Discount",
          "defaultValue": 30,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "a4f30206-453f-47a0-81d1-dccc840f2a55",
          "name": "Product",
          "defaultValue": "iPhone",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false,
            "enum": [
              "iPhone",
              "Samsung"
            ]
          }
        },
        {
          "id": "7aaac9d2-1ef9-4f76-bca8-4e9f39be292f",
          "name": "Offertext",
          "defaultValue": "Get a new IPhone now and get 30% off iPad",
          "valueConstraints": {
            "dataType": "string",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2cc0956b-2a0c-4d41-8829-45ed273a05f5",
          "name": "Budget",
          "defaultValue": 500,
          "valueConstraints": {
            "dataType": "number",
            "format": "decimal",
            "required": false,
            "readOnly": true,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "2f9141df-96d3-473a-a3f6-6279c29e63a1",
          "name": "Goal",
          "defaultValue": "2018-07-13",
          "valueConstraints": {
            "dataType": "string",
            "format": "date",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        },
        {
          "id": "5b2743aa-374c-428c-96eb-5e4e22ba7e28",
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "number",
            "format": "integer",
            "required": false,
            "readOnly": false,
            "multiple": false,
            "range": false
          }
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.treatment.definition"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "uri": "/treatmentDefinitions/definitions/da85cd3c-7c7a-437c-acac-eca2819c9a6d/revisions/9ce585d7-898d-47d9-9441-00e2628e204f",
          "type": "application/vnd.sas.summary"
        }
      ],
      "version": 3,
      "status": "valid"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A revision of a treatment definition group was created. treatmentDefinitionGroupCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    201 Last-Modified string The timestamp when the revision of the specified treatment definition group was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    201 Location string The URI of the revision of the specified treatment definition group.
    201 ETag string The entity tag for the treatment definition revision.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get revisions across treatment definition groups

    Code samples

    # You can also use wget
    curl -X POST https://example.com/treatmentDefinitions/definitionGroupRevisions \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.selection+json' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.treatment.definition.group+json'
    
    
    const inputBody = '{
      "type": "id",
      "resources": [
        "5083819a-b690-43eb-a676-5130c465435c",
        "273a4794-bf9e-47bd-b437-f02575337479"
      ],
      "version": 1
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.selection+json',
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.treatment.definition.group+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroupRevisions',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.selection+json',
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.treatment.definition.group+json'
    }
    
    r = requests.post('https://example.com/treatmentDefinitions/definitionGroupRevisions', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.selection+json"},
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.treatment.definition.group+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/treatmentDefinitions/definitionGroupRevisions", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /definitionGroupRevisions

    Returns a list of the treatment definition group revisions based on the list of resource IDs.

    Body parameter

    Treatment definition group with selection.

    {
      "type": "id",
      "resources": [
        "5083819a-b690-43eb-a676-5130c465435c",
        "273a4794-bf9e-47bd-b437-f02575337479"
      ],
      "version": 1
    }
    
    Parameters
    Name In Type Required Description
    Accept-Item header string(media-type) false Used for selecting desired item representation.
    start query integer false Returns the index of the first revision of the specified treatment definition.
    limit query integer false Returns the maximum number of revisions of the specified treatment definition.
    body body #/paths/~1definitionRevisions/post/requestBody/content/application~1vnd.sas.selection%2Bjson/schema true Select resource IDs for which details of the treatment definition are to be found.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.treatment.definition.group+json
    Accept-Item application/vnd.sas.summary+json
    Accept-Item application/vnd.sas.dcm.summary+json

    Example responses

    Treatment definition group revision with selection.

    {
      "links": [
        {
          "method": "POST",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroupRevisions",
          "uri": "/treatmentDefinitions/definitionGroupRevisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroupRevisions?start=0&limit=10",
          "uri": "/treatmentDefinitions/definitionGroupRevisions?start=0&limit=10",
          "type": "application/vnd.sas.collection"
        }
      ],
      "name": "treatmentDefinitionGroupRevisions",
      "accept": "application/vnd.sas.treatment.definition.group",
      "start": 0,
      "count": 2,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:34:43.865Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "5083819a-b690-43eb-a676-5130c465435c",
          "name": "My Treatment Definition Group",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "members": [
            {
              "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
              "definitionName": "Treatment_2",
              "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
              "definitionRevisionName": 1
            },
            {
              "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
              "definitionName": "Treatment_1",
              "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "definitionRevisionName": 1,
              "attributeValueMappings": [
                {
                  "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
                  "attributeName": "foo",
                  "mappingType": "variable",
                  "value": "foo"
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
              "type": "application/vnd.sas.summary"
            }
          ],
          "folderType": "myFolder",
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
          "copyTimeStamp": "2021-09-16T18:34:43.865Z",
          "version": 3,
          "status": "valid"
        },
        {
          "creationTimeStamp": "2021-09-16T20:55:26.275Z",
          "modifiedTimeStamp": "2021-09-16T20:55:26.275Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "273a4794-bf9e-47bd-b437-f02575337479",
          "name": "My Treatment Definition Group 2",
          "majorRevision": 1,
          "minorRevision": 2,
          "locked": false,
          "members": [
            {
              "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
              "definitionName": "Treatment_2",
              "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
              "definitionRevisionName": 1
            },
            {
              "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "definitionName": "My Treatment Definition",
              "definitionRevisionId": "a6d2bfda-6fd3-4549-8613-e9b1d192b39b",
              "definitionRevisionName": 1,
              "attributeValueMappings": [
                {
                  "attributeId": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
                  "attributeName": "Discount",
                  "mappingType": "variable",
                  "value": "Discount"
                },
                {
                  "attributeId": "d39deb65-9e77-4340-a258-5a48f360954f",
                  "attributeName": "Product",
                  "mappingType": "variable",
                  "value": "Product"
                },
                {
                  "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
                  "attributeName": "Offertext",
                  "mappingType": "variable",
                  "value": "Offertext"
                },
                {
                  "attributeId": "352b97bf-500f-435b-9358-855b5d4bb03a",
                  "attributeName": "Budget",
                  "mappingType": "variable",
                  "value": "Budget"
                },
                {
                  "attributeId": "ffabcac8-4f55-499f-b63d-5d8a52575547",
                  "attributeName": "Goal",
                  "mappingType": "variable",
                  "value": "Goal"
                },
                {
                  "attributeId": "8e67bc1d-a529-49dc-b704-9763549d43a3",
                  "attributeName": "TimesClicked",
                  "mappingType": "variable",
                  "value": "TimesClicked"
                }
              ],
              "attributeNameAliases": [
                {
                  "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
                  "attributeName": "Offertext",
                  "aliasName": "Offer Text"
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/273a4794-bf9e-47bd-b437-f02575337479",
              "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/273a4794-bf9e-47bd-b437-f02575337479",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/273a4794-bf9e-47bd-b437-f02575337479",
              "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/273a4794-bf9e-47bd-b437-f02575337479",
              "type": "application/vnd.sas.summary"
            }
          ],
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 10,
      "version": 2
    }
    
    {
      "links": [
        {
          "method": "POST",
          "rel": "collection",
          "href": "/treatmentDefinitions/definitionGroupRevisions",
          "uri": "/treatmentDefinitions/definitionGroupRevisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "POST",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroupRevisions?start=0&limit=10",
          "uri": "/treatmentDefinitions/definitionGroupRevisions?start=0&limit=10",
          "type": "application/vnd.sas.collection"
        }
      ],
      "name": "treatmentDefinitionGroupRevisions",
      "accept": "application/vnd.sas.treatment.definition.group",
      "start": 0,
      "count": 2,
      "items": [
        {
          "creationTimeStamp": "2021-09-16T18:34:43.865Z",
          "modifiedTimeStamp": "2021-09-16T18:34:43.865Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "5083819a-b690-43eb-a676-5130c465435c",
          "name": "My Treatment Definition Group",
          "majorRevision": 1,
          "minorRevision": 0,
          "locked": false,
          "members": [
            {
              "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
              "definitionName": "Treatment_2",
              "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
              "definitionRevisionName": 1
            },
            {
              "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
              "definitionName": "Treatment_1",
              "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
              "definitionRevisionName": 1,
              "attributeValueMappings": [
                {
                  "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
                  "attributeName": "foo",
                  "mappingType": "variable",
                  "value": "foo"
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
              "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
              "type": "application/vnd.sas.summary"
            }
          ],
          "folderType": "myFolder",
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
          "copyTimeStamp": "2021-09-16T18:34:43.865Z",
          "version": 3,
          "status": "valid"
        },
        {
          "creationTimeStamp": "2021-09-16T20:55:26.275Z",
          "modifiedTimeStamp": "2021-09-16T20:55:26.275Z",
          "createdBy": "bob",
          "modifiedBy": "bob",
          "id": "273a4794-bf9e-47bd-b437-f02575337479",
          "name": "My Treatment Definition Group 2",
          "majorRevision": 1,
          "minorRevision": 2,
          "locked": false,
          "members": [
            {
              "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
              "definitionName": "Treatment_2",
              "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
              "definitionRevisionName": 1
            },
            {
              "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
              "definitionName": "My Treatment Definition",
              "definitionRevisionId": "a6d2bfda-6fd3-4549-8613-e9b1d192b39b",
              "definitionRevisionName": 1,
              "attributeValueMappings": [
                {
                  "attributeId": "a2ba0939-4b65-4508-ad43-c4d371c6b5eb",
                  "attributeName": "Discount",
                  "mappingType": "variable",
                  "value": "Discount"
                },
                {
                  "attributeId": "d39deb65-9e77-4340-a258-5a48f360954f",
                  "attributeName": "Product",
                  "mappingType": "variable",
                  "value": "Product"
                },
                {
                  "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
                  "attributeName": "Offertext",
                  "mappingType": "variable",
                  "value": "Offertext"
                },
                {
                  "attributeId": "352b97bf-500f-435b-9358-855b5d4bb03a",
                  "attributeName": "Budget",
                  "mappingType": "variable",
                  "value": "Budget"
                },
                {
                  "attributeId": "ffabcac8-4f55-499f-b63d-5d8a52575547",
                  "attributeName": "Goal",
                  "mappingType": "variable",
                  "value": "Goal"
                },
                {
                  "attributeId": "8e67bc1d-a529-49dc-b704-9763549d43a3",
                  "attributeName": "TimesClicked",
                  "mappingType": "variable",
                  "value": "TimesClicked"
                }
              ],
              "attributeNameAliases": [
                {
                  "attributeId": "48cbcd9c-2517-4c1d-902a-28769751dff7",
                  "attributeName": "Offertext",
                  "aliasName": "Offer Text"
                }
              ]
            }
          ],
          "links": [
            {
              "method": "GET",
              "rel": "up",
              "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
              "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
              "type": "application/vnd.sas.collection"
            },
            {
              "method": "GET",
              "rel": "self",
              "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/273a4794-bf9e-47bd-b437-f02575337479",
              "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/273a4794-bf9e-47bd-b437-f02575337479",
              "type": "application/vnd.sas.treatment.definition.group"
            },
            {
              "method": "GET",
              "rel": "alternate",
              "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/273a4794-bf9e-47bd-b437-f02575337479",
              "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/273a4794-bf9e-47bd-b437-f02575337479",
              "type": "application/vnd.sas.summary"
            }
          ],
          "version": 3,
          "status": "valid"
        }
      ],
      "limit": 10,
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema
    Enumerated Values
    Property Value
    activationStatus active
    activationStatus inactive
    activationStatus pending
    activationStatus running
    activationStatus cancelled
    activationStatus timedOut
    activationStatus failed
    status valid
    status error
    mappingType variable
    mappingType constant

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get a revision of a specified treatment definition group

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}#summary \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}#summary',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}#summary', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}#summary", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups/{groupId}/revisions/{revisionId}#summary

    Returns the summary representation of the revision of the specified treatment definition group.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    revisionId path string true The unique identifier for the revision of the specified treatment definition group. Delegate @current can be used to get the current revision. Delegate @active can be used to get the active revision.

    Example responses

    Treatment definition group with summary details.

    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.092Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "178c8c19-8493-46b4-8004-94cf73ba5b9e",
      "name": "My Treatment Definition Group 2",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "activatedTimeStamp": "2021-09-16T19:47:39.340Z",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": 1,
          "attributeValueMappings": [
            {
              "attributeId": "08089b8a-73fd-4ea7-9da9-5a6b5809aeb0",
              "attributeName": "foo",
              "mappingType": "variable",
              "value": "foo"
            }
          ]
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "9ce585d7-898d-47d9-9441-00e2628e204f",
          "definitionRevisionName": "1.1"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e"
        }
      ],
      "activationStatus": "active",
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.092Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "178c8c19-8493-46b4-8004-94cf73ba5b9e",
      "name": "My Treatment Definition Group 2",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "activatedTimeStamp": "2021-09-16T19:47:39.340Z",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": 1,
          "attributeValueMappings": [
            {
              "attributeId": "08089b8a-73fd-4ea7-9da9-5a6b5809aeb0",
              "attributeName": "foo",
              "mappingType": "variable",
              "value": "foo"
            }
          ]
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "9ce585d7-898d-47d9-9441-00e2628e204f",
          "definitionRevisionName": "1.1"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e"
        }
      ],
      "activationStatus": "active",
      "version": 3,
      "status": "valid"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. resourceSummaryCollection/allOf/1/properties/items/items
    404 Not Found No treatment definition group revision exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Get revision of specified treatment definition group

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.treatment.definition.group+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.treatment.definition.group+json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.treatment.definition.group+json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.treatment.definition.group+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups/{groupId}/revisions/{revisionId}

    Returns the representation of the specified treatment definition group revision.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    revisionId path string true The unique identifier for the revision of the specified treatment definition group. Delegate @current can be used to get the current revision. Delegate @active can be used to get the active revision.

    Example responses

    Treatment definition group revision with full details.

    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.092Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "178c8c19-8493-46b4-8004-94cf73ba5b9e",
      "name": "My Treatment Definition Group 2",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "activatedTimeStamp": "2021-09-16T19:47:39.340Z",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "08089b8a-73fd-4ea7-9da9-5a6b5809aeb0",
              "attributeName": "foo",
              "mappingType": "variable",
              "value": "foo"
            }
          ]
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "9ce585d7-898d-47d9-9441-00e2628e204f",
          "definitionRevisionName": "1.1"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e"
        }
      ],
      "activationStatus": "active",
      "version": 3,
      "status": "valid"
    }
    

    Treatment definition group revision resource summary.

    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.092Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "178c8c19-8493-46b4-8004-94cf73ba5b9e",
      "name": "My Treatment Definition Group",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "activatedTimeStamp": "2021-09-16T19:47:39.340Z",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": 1,
          "attributeValueMappings": [
            {
              "attributeId": "08089b8a-73fd-4ea7-9da9-5a6b5809aeb0",
              "attributeName": "foo",
              "mappingType": "variable",
              "value": "foo"
            }
          ]
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "9ce585d7-898d-47d9-9441-00e2628e204f",
          "definitionRevisionName": "1.1"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e"
        }
      ],
      "activationStatus": "active",
      "version": 3,
      "status": "valid"
    }
    

    Treatment definition group revision summary.

    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.092Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "178c8c19-8493-46b4-8004-94cf73ba5b9e",
      "name": "My Treatment Definition Group 2",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "activatedTimeStamp": "2021-09-16T19:47:39.340Z",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": 1,
          "attributeValueMappings": [
            {
              "attributeId": "08089b8a-73fd-4ea7-9da9-5a6b5809aeb0",
              "attributeName": "foo",
              "mappingType": "variable",
              "value": "foo"
            }
          ]
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "9ce585d7-898d-47d9-9441-00e2628e204f",
          "definitionRevisionName": "1.1"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e"
        }
      ],
      "activationStatus": "active",
      "version": 3,
      "status": "valid"
    }
    

    Treatment definition group revision with full details.

    {
      "creationTimeStamp": "2021-09-16T19:18:12.092Z",
      "modifiedTimeStamp": "2021-09-16T19:18:12.092Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "178c8c19-8493-46b4-8004-94cf73ba5b9e",
      "name": "My Treatment Definition Group 2",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "activatedTimeStamp": "2021-09-16T19:47:39.340Z",
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "08089b8a-73fd-4ea7-9da9-5a6b5809aeb0",
              "attributeName": "foo",
              "mappingType": "variable",
              "value": "foo"
            }
          ]
        },
        {
          "definitionId": "da85cd3c-7c7a-437c-acac-eca2819c9a6d",
          "definitionName": "My Treatment Definition",
          "definitionRevisionId": "9ce585d7-898d-47d9-9441-00e2628e204f",
          "definitionRevisionName": "1.1"
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e",
          "uri": "/treatmentDefinitions/definitionGroups/625e99fd-4d8a-4ee2-b201-4fd3c062169f/revisions/178c8c19-8493-46b4-8004-94cf73ba5b9e"
        }
      ],
      "activationStatus": "active",
      "version": 3,
      "status": "valid"
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. treatmentDefinitionGroupCollection
    404 Not Found No revision of the specified v exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the revision of the specified treatment definition group was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment group revision.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a treatment definition group version

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /definitionGroups/{groupId}/revisions/{revisionId}

    Deletes the specified treatment definition group version.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    revisionId path string true The unique identifier for the revision of the specified treatment definition group.
    Responses
    Status Meaning Description Schema
    204 No Content The treatment definition group version was deleted. None
    Response Headers
    Status Header Type Format Description
    204 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Activate revision of a treatment definition group

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/treatmentDefinitions/definitionGroups/{groupId}/active \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.treatment.definition.group+json' \
      -H 'If-Match: "kknyjgku"'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.treatment.definition.group+json',
      'If-Match':'"kknyjgku"'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/active',
    {
      method: 'PUT',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.treatment.definition.group+json',
      'If-Match': '"kknyjgku"'
    }
    
    r = requests.put('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/active', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.treatment.definition.group+json"},
            "If-Match": []string{""kknyjgku""},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/active", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /definitionGroups/{groupId}/active

    Activate a locked revision of the specified treatment definition group.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    If-Match header string true Etag value from when the originating object was retrieved.

    Example responses

    Treatment definition group pending activation

    {
      "creationTimeStamp": "2021-09-16T18:34:43.865Z",
      "modifiedTimeStamp": "2021-09-16T18:34:43.865Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "5083819a-b690-43eb-a676-5130c465435c",
      "name": "Treatment_Group_4",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0"
        },
        {
          "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
          "definitionName": "Treatment_1",
          "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
              "attributeName": "foo",
              "mappingType": "variable",
              "value": "foo"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c"
        }
      ],
      "activationStatus": "pending",
      "folderType": "myFolder",
      "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
      "copyTimeStamp": "2021-09-16T18:34:43.865Z",
      "version": 3,
      "status": "valid"
    }
    
    {
      "creationTimeStamp": "2021-09-16T18:34:43.865Z",
      "modifiedTimeStamp": "2021-09-16T18:34:43.865Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "5083819a-b690-43eb-a676-5130c465435c",
      "name": "Treatment_Group_4",
      "majorRevision": 1,
      "minorRevision": 0,
      "locked": true,
      "members": [
        {
          "definitionId": "81b5f14a-f131-4a2c-a84f-62175b27a9a1",
          "definitionName": "Treatment_2",
          "definitionRevisionId": "ac372328-9220-44c1-8ee5-d2d75607bc87",
          "definitionRevisionName": "1.0"
        },
        {
          "definitionId": "8c21e6e2-a2e7-4296-a11a-ad19d2c40852",
          "definitionName": "Treatment_1",
          "definitionRevisionId": "b9be29ad-557a-4c20-a70e-0cdb49d998e4",
          "definitionRevisionName": "1.0",
          "attributeValueMappings": [
            {
              "attributeId": "3064402c-b83f-4c43-baa7-e68c28028e2a",
              "attributeName": "foo",
              "mappingType": "variable",
              "value": "foo"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "up",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions",
          "type": "application/vnd.sas.collection"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "type": "application/vnd.sas.treatment.definition.group"
        },
        {
          "method": "GET",
          "rel": "alternate",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "type": "application/vnd.sas.summary"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c",
          "uri": "/treatmentDefinitions/definitionGroups/d738c763-6d1f-4980-a3ec-b57dda234179/revisions/5083819a-b690-43eb-a676-5130c465435c"
        }
      ],
      "activationStatus": "pending",
      "folderType": "myFolder",
      "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/bc0aa316-0d1d-4e8d-8251-87bf18220518/revisions/8a7cf41f-b327-4957-91b2-3fc8dce816af",
      "copyTimeStamp": "2021-09-16T18:34:43.865Z",
      "version": 3,
      "status": "valid"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. treatmentDefinitionGroupCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No treatment definition group revision exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag. Inline
    428 Precondition Required The request headers did not include a If-Match precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition group was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.
    200 ETag string The entity tag for the treatment definition group.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    412 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    428 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Code

    Contains operations for generating code.

    Get treatment definition group code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups/{groupId}/ds2Code \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    
    const headers = {
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/ds2Code',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/ds2Code', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/ds2Code", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups/{groupId}/ds2Code

    Returns the DS2 code for the specified treatment definition group.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    populateCode query boolean false Indicates whether to populate DS2 code in the output.
    codeTarget query string false Target where the generated DS2 code will be deployed.
    variableAssignmentTrace query boolean false Determines if variable assignment trace logging is added to the generated DS2 code.
    Enumerated Values
    Parameter Value
    codeTarget others
    codeTarget microAnalyticService

    Example responses

    Treatment definition group DS2 code.

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    404 Not Found No treatment definition group exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition group was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Get treatment definition group decision step code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups/{groupId}/decisionStepCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/decisionStepCode',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/decisionStepCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/decisionStepCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups/{groupId}/decisionStepCode

    Returns the decision step code for the specified treatment definition group.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    populateCode query boolean false Indicates whether to populate DS2 code in the output.
    codeTarget query string false Target where the DS2 code is deployed.
    variableAssignmentTrace query boolean false Determines if variable assignment trace logging is added to the generated DS2 code.
    Enumerated Values
    Parameter Value
    codeTarget others
    codeTarget microAnalyticService

    Example responses

    Treatment definition group decision step code.

    {
      "type": "treatmentGroup",
      "name": "My Treatment Definition Group",
      "signature": [
        {
          "name": "foo",
          "dataType": "string",
          "direction": "input",
          "length": 32767,
          "generateDataGridColumns": false
        },
        {
          "name": "dgout",
          "dataType": "dataGrid",
          "direction": "output",
          "dataGridExtension": [
            {
              "name": "treatment_definition_group_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_group_revision_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_revision_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_name",
              "dataType": "string",
              "length": 250,
              "autoPopulate": false
            },
            {
              "name": "Budget",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "Discount",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "foo",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "Goal",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "Offertext",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "Product",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "TimesClicked",
              "dataType": "decimal",
              "autoPopulate": false
            }
          ],
          "generateDataGridColumns": false
        }
      ],
      "version": 1
    }
    
    {
      "type": "treatmentGroup",
      "name": "My Treatment Definition Group",
      "signature": [
        {
          "name": "foo",
          "dataType": "string",
          "direction": "input",
          "length": 32767,
          "generateDataGridColumns": false
        },
        {
          "name": "dgout",
          "dataType": "dataGrid",
          "direction": "output",
          "dataGridExtension": [
            {
              "name": "treatment_definition_group_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_group_revision_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_revision_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_name",
              "dataType": "string",
              "length": 250,
              "autoPopulate": false
            },
            {
              "name": "Budget",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "Discount",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "foo",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "Goal",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "Offertext",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "Product",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "TimesClicked",
              "dataType": "decimal",
              "autoPopulate": false
            }
          ],
          "generateDataGridColumns": false
        }
      ],
      "version": 1
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No treatment definition group exists at the requested path. Inline
    Response Schema

    Status Code 200

    Decision Step Code

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string false none The name of the object used in decision step.
    » description string false none The description of the object used in decision step.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » code string false none The code of the object used in the decision step.
    » type string false none The object type of the object used in the decision step.
    » signature [any] false none Signature variables of the object used in the decision step.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition group was last modified. The timestamp is in the format EEE, dd MMM yyyy HH:mm:ss GMT.

    Get treatment definition group revision code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}/ds2Code \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/vnd.sas.source.ds2'
    
    
    
    const headers = {
      'Accept':'text/vnd.sas.source.ds2'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}/ds2Code',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/vnd.sas.source.ds2'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}/ds2Code', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/vnd.sas.source.ds2"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}/ds2Code", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups/{groupId}/revisions/{revisionId}/ds2Code

    Returns the DS2 code for the specified treatment definition group revision.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier for the treatment definition group.
    revisionId path string true The unique identifier for the revision of the specified treatment definition group. Delegate @current can be used to get the current revision. Delegate @active can be used to get the active revision.
    codeTarget query string false Target where the generated DS2 code is deployed.
    variableAssignmentTrace query boolean false Determines if variable assignment trace logging is added to the generated DS2 code.
    Enumerated Values
    Parameter Value
    codeTarget others
    codeTarget microAnalyticService

    Example responses

    Treatment definition group DS2 code.

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. string
    404 Not Found No treatment definition group revision exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string No description

    Get treatment definition group revision decision step code

    Code samples

    # You can also use wget
    curl -X GET https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}/decisionStepCode \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/json'
    
    
    
    const headers = {
      'Accept':'application/json'
    };
    
    fetch('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}/decisionStepCode',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/json'
    }
    
    r = requests.get('https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}/decisionStepCode', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/treatmentDefinitions/definitionGroups/{groupId}/revisions/{revisionId}/decisionStepCode", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /definitionGroups/{groupId}/revisions/{revisionId}/decisionStepCode

    Returns the decision step code for the specified treatment definition group revision.

    Parameters
    Name In Type Required Description
    groupId path string true The unique identifier of the group.
    revisionId path string true The unique identifier for the revision of the specified treatment definition group. Delegate @current can be used to get the current revision. Delegate @active can be used to get the active revision.
    populateCode query boolean false Indicates whether to populate DS2 code in the output.
    codeTarget query string false Target where the generated DS2 code is deployed.
    variableAssignmentTrace query boolean false Determines if variable assignment trace logging is added to the generated DS2 code.
    Enumerated Values
    Parameter Value
    codeTarget others
    codeTarget microAnalyticService

    Example responses

    Treatment definition group decision step code.

    {
      "type": "treatmentGroup",
      "name": "My Treatment Definition Group",
      "signature": [
        {
          "name": "foo",
          "dataType": "string",
          "direction": "input",
          "length": 32767,
          "generateDataGridColumns": false
        },
        {
          "name": "dgout",
          "dataType": "dataGrid",
          "direction": "output",
          "dataGridExtension": [
            {
              "name": "treatment_definition_group_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_group_revision_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_revision_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_name",
              "dataType": "string",
              "length": 250,
              "autoPopulate": false
            },
            {
              "name": "Budget",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "Discount",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "foo",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "Goal",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "Offertext",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "Product",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "TimesClicked",
              "dataType": "decimal",
              "autoPopulate": false
            }
          ],
          "generateDataGridColumns": false
        }
      ],
      "version": 1
    }
    
    {
      "type": "treatmentGroup",
      "name": "My Treatment Definition Group",
      "signature": [
        {
          "name": "foo",
          "dataType": "string",
          "direction": "input",
          "length": 32767,
          "generateDataGridColumns": false
        },
        {
          "name": "dgout",
          "dataType": "dataGrid",
          "direction": "output",
          "dataGridExtension": [
            {
              "name": "treatment_definition_group_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_group_revision_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_revision_id",
              "dataType": "string",
              "length": 36,
              "autoPopulate": false
            },
            {
              "name": "treatment_definition_name",
              "dataType": "string",
              "length": 250,
              "autoPopulate": false
            },
            {
              "name": "Budget",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "Discount",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "foo",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "Goal",
              "dataType": "decimal",
              "autoPopulate": false
            },
            {
              "name": "Offertext",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "Product",
              "dataType": "string",
              "length": 32767,
              "autoPopulate": false
            },
            {
              "name": "TimesClicked",
              "dataType": "decimal",
              "autoPopulate": false
            }
          ],
          "generateDataGridColumns": false
        }
      ],
      "version": 1
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. Inline
    404 Not Found No treatmentDefinitionGroup exists at the requested path. Inline
    Response Schema

    Status Code 200

    Decision Step Code

    Name Type Required Restrictions Description
    » id string false none The system-assigned unique ID for this object.
    » name string false none The name of the object used in decision step.
    » description string false none The description of the object used in decision step.
    » createdBy string false none The user who created the object used in decision step.
    » creationTimeStamp string(date-time) false none The date and time that the object used in the decision step was created.
    » modifiedBy string false none The user ID of the authenticated user who last updated the object used in the decision step.
    » modifiedTimeStamp string(date-time) false none The date and time that the object used in the decision step was last modified.
    » code string false none The code of the object used in the decision step.
    » type string false none The object type of the object used in the decision step.
    » signature [any] false none Signature variables of the object used in the decision step.
    »» Decision Step Code Signature Term object false none Terms that are a part of the signature for the object that is used in a decision step.
    »»» name string true none The name of the object used in a decision step.
    »»» dataType string true none Data type of the term.
    »»» direction string true none Direction of the term.
    »»» length integer false none Length of the term.
    »»» dataGridExtension [any] false none Metadata information about data grid columns.
    »»»» Decision Step Code Signature Term DataGrid Extension object false none Decision Step Code Signature Term DataGrid Extension is used to store the column information of a DataGrid variable.
    »»»»» name string true none Name of the dataGrid column.
    »»»»» length integer false none Length of the value in the dataGrid column. Valid for dataType string.
    »»»»» dataType string(enumeration) true none Data type of the dataGrid column.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none This media type's schema version number. This representation is version 1.
    Enumerated Values
    Property Value
    dataType string
    dataType decimal
    dataType integer
    dataType dataGrid
    dataType date
    dataType datetime
    dataType unknown
    dataType string
    dataType decimal
    dataType integer
    dataType date
    dataType datetime

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the error.
    »» Link resourceSummaryCollection/allOf/0/properties/links/items false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    200 Last-Modified string The timestamp when the treatment definition group was last modified. The timestamp is in the format EEE, dd MMM yyyy H:mm:ss GMT.

    Schemas

    resourceSummaryCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "type": "string",
          "description": "string",
          "typeDefName": "string",
          "iconUri": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    
    

    Resource Summary Collection

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [object] false none The links that apply to the collection.
    »» Link object false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [object] true none Array consisting of one page of the objects as summary resources.
    »» Resource Summary object false none The summarized representation of a resource. Often used in collection responses when more specific details aren't needed.
    »»» id string true none The unique identifier for the resource.
    »»» name string false none The name of the resource.
    »»» type string false none The type of the resource.
    »»» description string false none The description of the resource.
    »»» typeDefName string false none (version 2) The name of the type definition that describes the contents of this resource.
    »»» iconUri string false none (version 2) The URI of an icon assigned to this resource, overrides default icons for the type.
    »»» createdBy string false none The user who created the resource.
    »»» creationTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was created.
    »»» modifiedBy string false none The user who most recently modified the resource.
    »»» modifiedTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was last modified.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] true none The links that apply to the resource.
    »»» version integer true none The version number of the resource. This representation is version 2.

    revisionSummaryCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "name": "string",
          "description": "string",
          "createdBy": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "majorRevision": 0,
          "minorRevision": 0,
          "locked": true,
          "sourceRevisionUri": "string",
          "copyTimeStamp": "2019-08-24T14:15:22Z",
          "folderType": "string",
          "properties": {
            "property1": "string",
            "property2": "string"
          },
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ],
          "version": 0
        }
      ]
    }
    
    

    Revision Summary Collection

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous resourceSummaryCollection/allOf/0 false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [any] true none Array consisting of one page of the objects as summary resources.
    »» Revision Resource Summary object false none The summarized representation of a decisioning revision resource.
    »»» id string false none The unique identifier for the resource.
    »»» name string false none The name of the resource.
    »»» description string false none The description of the resource.
    »»» createdBy string false none The user who created the resource.
    »»» creationTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was created.
    »»» modifiedBy string false none The user who most recently modified the resource.
    »»» modifiedTimeStamp string(date-time) false none The timestamp in YYYY-MM-DDThh:mm:ss.sssZ format when the resource was last modified.
    »»» majorRevision integer false none Major version number of the revision being viewed of a resource.
    »»» minorRevision integer false none Minor version number of the current revision of a resource.
    »»» locked boolean false none Flag which indicates if the content being viewed is locked or editable.
    »»» sourceRevisionUri string false none The URI of a resource revision this resource is being created from.
    »»» copyTimeStamp string(date-time) false none The time stamp when the resource revision was copied.
    »»» folderType string false none Indicates the kind of folder where the resource is housed.
    »»» properties object false none Properties associated with the revision.
    »»»» additionalProperties string false none none
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none The links that apply to the resource.
    »»» version integer false none The version number of the resource. This representation is version 1.

    treatmentDefinitionCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "My Treatment Definition",
          "checkout": false,
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitions/6b53e248-1afb-4147-b17a-13e75b8c759b/revisions/0340f630-3ee6-4058-ad36-744619c141d5",
          "copyTimeStamp": "2020-06-17T13:37:01.750Z",
          "attributes": [
            {
              "name": "Discount",
              "valueConstraints": {
                "dataType": "number",
                "format": "decimal"
              },
              "defaultValue": 30
            },
            {
              "name": "Product",
              "valueConstraints": {
                "dataType": "string",
                "enum": [
                  "iPhone",
                  "Samsung"
                ]
              },
              "defaultValue": "iPhone"
            },
            {
              "name": "Offertext",
              "valueConstraints": {
                "dataType": "string"
              },
              "defaultValue": "Get a new iPhone now and get 30% off iPad"
            },
            {
              "name": "Budget",
              "valueConstraints": {
                "dataType": "number",
                "format": "decimal",
                "readOnly": true
              },
              "defaultValue": 500
            },
            {
              "name": "Goal",
              "valueConstraints": {
                "dataType": "string",
                "format": "date"
              },
              "defaultValue": "2018-07-13"
            },
            {
              "name": "TimesClicked",
              "valueConstraints": {
                "dataType": "number",
                "format": "integer"
              }
            }
          ]
        }
      ]
    }
    
    

    Treatment Definition Collection

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous resourceSummaryCollection/allOf/0 false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [object] true none Array consisting of one page of the treatment resources.
    »» Treatment Definition object false none The representation of a treatment definition.
    »»» id string false none The system-assigned unique ID for this object.
    »»» name string true none The treatment definition name.
    »»» description string false none The treatment definition description.
    »»» createdBy string false none The user who created the treatment definition.
    »»» creationTimeStamp string(date-time) false none The date and time that the treatment definition was created.
    »»» modifiedBy string false none The user ID of the authenticated user who last updated the treatment definition.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the treatment definition was last modified.
    »»» majorRevision integer false none Major version number of the revision being viewed of the treatment definition. 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.
    »»» minorRevision integer false none Minor version number of the current revision of the treatment definition. 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.
    »»» checkout boolean false none Flag that indicates that the treatment definition is a user's working copy of another treatment definition.
    »»» locked boolean false none Flag that indicates whether the content of the revision being viewed is locked or editable.
    »»» status string(enumeration) false none The status of the treatment definition.
    »»» eligibility object false none Represents the eligibility details for a treatment definition. This does not represent any of the top-level media types.
    »»»» ruleSetUri string false none The business rules URI that is related to eligibility.
    »»»» ruleSetName string false none The name of the eligibility rule set URI.
    »»»» startDate string(date-time) false none The date in which the treatment definition becomes eligible. The timestamp format yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of the time zone.
    »»»» endDate string(date-time) false none The date after which the treatment definition becomes ineligible. The timestamp yyyy-MM-dd HH:mm.ss.SSS is used for this, which is independent of time zone.
    »»»» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» attributes [object] false none An array of treatment definition attributes.
    »»»» Treatment Definition Attribute object false none Represents a treatment definition attribute. This does not represent any of the top-level media types.
    »»»»» id string false none The system-assigned unique ID for this object.
    »»»»» name string true none The treatment attribute name, which is unique within a treatment definition.
    »»»»» description string false none The treatment attribute description.
    »»»»» defaultValue any false none The default value for the attribute.

    anyOf

    Name Type Required Restrictions Description
    »»»»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»»»» valueConstraints object true none Represents the attribute value constraints for a treatment definition. This does not represent any of the top-level media types.
    »»»»»» dataType string(enumeration) true none The data type of this attribute value.
    »»»»»» format string(enumeration) false none The format of the attribute value.
    »»»»»» multiple boolean false none Whether the attribute value is a single value or list of values. Default is false.
    »»»»»» range boolean false none Whether the attribute value contains from and to values. Default is false.
    »»»»»» required boolean false none Whether the attribute value is required. Default is false.
    »»»»»» readOnly boolean false none Whether the attribute value can be changed from outside. Default is false.
    »»»»»» enum [anyOf] false none List of valid values for the attribute. Valid only for simple types with multiple=false and range=false. It is not valid for boolean data type.

    anyOf

    Name Type Required Restrictions Description
    »»»»»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»»»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»»»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»»»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»»»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»»»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»»»»» minimum object false none Minimum value for the attribute. Valid only for simple types with multiple=false and range=false. Valid types: decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime)
    »»»»»» maximum object false none Maximum value for the attribute. Only valid for simple types with multiple=false and range=false. Only valid for decimal(dataType=number, format=decimal), integer(dataType=number, format=integer), date(dataType=string, format=date), datetime(dataType=string, format=datetime).
    »»»»»» minLength integer false none Minimum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»»»»» maxLength integer false none Maximum length of the attribute value. Used only by string data type and simple types with multiple=false and range=false.
    »»»»» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» folderType string false none Indicates the type of folder where the treatment definition is stored.
    »»» sourceRevisionUri string false none The URI of the treatment definition revision that the treatment definition is being created from.
    »»» copyTimeStamp string(date-time) false none The time stamp when the treatment definition revision was copied.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 4.
    Enumerated Values
    Property Value
    status valid
    status error
    dataType string
    dataType number
    dataType boolean
    format date
    format datetime
    format url
    format decimal
    format integer

    treatmentDefinitionGroupCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "name": "My Treatment Definition Group",
          "locked": false,
          "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/6b53e248-1afb-4147-b17a-13e75b8c759b/revisions/0340f630-3ee6-4058-ad36-744619c141d5",
          "copyTimeStamp": "2020-06-17T13:37:01.750Z",
          "members": [
            {
              "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692"
            },
            {
              "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692",
              "definitionRevisionId": "f813702e-dff8-443e-a7af-727ab027fb7e",
              "attributeValueMappings": [
                {
                  "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
                  "mappingType": "variable",
                  "value": "Discount"
                },
                {
                  "attributeId": "7c17cbaf-dd3d-4288-b6a9-54ae7c7c91c6",
                  "mappingType": "constant",
                  "value": "Samsung"
                },
                {
                  "attributeId": "a0a3b4d4-fc28-4194-84dd-fe2dc3286009",
                  "mappingType": "variable",
                  "value": "Clicked"
                }
              ],
              "attributeNameAliases": [
                {
                  "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
                  "aliasName": "Discount ID"
                }
              ]
            }
          ]
        }
      ]
    }
    
    

    Treatment Definition Group Collection

    Properties
    Name Type Required Restrictions Description
    Treatment Definition Group Collection any false none One page of the treatment definition group representations, with optional links to first, prev, next, and last page of the list.

    allOf

    Name Type Required Restrictions Description
    anonymous resourceSummaryCollection/allOf/0 false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [object] true none Array consisting of one page of the treatment definition group resources.
    »» Treatment Definition Group object false none The representation of a treatment definition group.
    »»» id string false none The system-assigned unique ID for this object
    »»» name string true none The treatment definition group name.
    »»» description string false none The treatment definition group description.
    »»» createdBy string false none The user who created the treatment definition group.
    »»» creationTimeStamp string(date-time) false none The date and time that the treatment definition group was created.
    »»» modifiedBy string false none The userId of the authenticated user who last updated the treatment definition group.
    »»» modifiedTimeStamp string(date-time) false none The date and time that the treatment definition group was last modified.
    »»» majorRevision integer false none Major version number of the revision being viewed of the treatment definition group. 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 which is generated on POST.
    »»» minorRevision integer false none Minor version number of the current revision of the treatment definition group. 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 which is generated on POST.
    »»» locked boolean false none Flag which indicates if the content of the revision being viewed is locked or editable.
    »»» activationStatus string(enumeration) false none Status of the activation.
    »»» activationError #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» activatedTimeStamp string(date-time) false none The date and time that the treatment definition group revision was activated.
    »»» status string(enumeration) false none Status of the treatment definition.
    »»» members [object] false none The group of treatment definition members.
    »»»» Treatment Definition Group Member object false none A treatment definition that belongs to a treatment definition group. This doesn't represent any top-level media type.
    »»»»» definitionId string true none Unique ID for a treatment definition.
    »»»»» definitionName string false none Name of the treatment definition.
    »»»»» definitionRevisionId string false none Unique ID for a treatment definition revision. The default value is the most recent revision of the treatment definition referenced by definitionId.
    »»»»» definitionRevisionName string false none Name of the treatment definition revision.
    »»»»» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»»»» attributeValueMappings [object] false none Array of mappings between treatment definition group variables and treatment definition attributes.
    »»»»»» Treatment Definition Group Attribute Value Mapping object false none Represents the mapping of treatment definition attributes and source of its value. This doesn't represent any top-level media type.
    »»»»»»» attributeId string true none The system-assigned unique ID for this attribute.
    »»»»»»» attributeName string false none Name of an attribute of the treatment definition.
    »»»»»»» mappingType string(enumeration) true none The mapping type.
    »»»»»»» value any false none For constant mapping type it is a literal value and for variable mapping type it is the name of the variable of treatment definition group. It is required when mappingType is variable. When mappingType is constant it can be null.

    anyOf

    Name Type Required Restrictions Description
    »»»»»»»» anonymous integer false none none

    or

    Name Type Required Restrictions Description
    »»»»»»»» anonymous number false none none

    or

    Name Type Required Restrictions Description
    »»»»»»»» anonymous array false none none

    or

    Name Type Required Restrictions Description
    »»»»»»»» anonymous boolean false none none

    or

    Name Type Required Restrictions Description
    »»»»»»»» anonymous object false none none

    or

    Name Type Required Restrictions Description
    »»»»»»»» anonymous string false none none

    continued

    Name Type Required Restrictions Description
    »»»»»»» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»»»» attributeNameAliases [object] false none Array of attribute name and its alias name.
    »»»»»» Treatment Definition Group Attribute Name Alias object false none Represents the treatment definition attribute name and its alias name. This doesn't represent any top-level media type.
    »»»»»»» attributeId string true none The system-assigned unique ID for this attribute.
    »»»»»»» attributeName string false none Name of an attribute of the treatment definition.
    »»»»»»» aliasName string true none Alias name of the attribute.
    »»»»»»» error #/paths/~1definitions/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    »»» folderType string false none Indicates the kind of folder where the treatment definition group is housed.
    »»» sourceRevisionUri string false none The URI of the treatment definition group revision this treatment definition group is being created from.
    »»» copyTimeStamp string(date-time) false none The time stamp when the treatment definition group revision was copied.
    »»» links [resourceSummaryCollection/allOf/0/properties/links/items] false none Zero or more links to related resources or operations.
    »»» version integer false none This media type's schema version number. This representation is version 3.
    Enumerated Values
    Property Value
    activationStatus active
    activationStatus inactive
    activationStatus pending
    activationStatus running
    activationStatus cancelled
    activationStatus timedOut
    activationStatus failed
    status valid
    status error
    mappingType variable
    mappingType constant

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    application/vnd.sas.treatment.definition

    Contains details like attributes, eligibility rule.

    The schema is at treatmentDefinition.

    application/vnd.sas.treatment.definition+json

    Here is an example of the JSON representation for this media type.

    
     {
      "name": "My Treatment Definition",
      "attributes": [
        {
          "name": "Discount",
          "valueConstraints": {
            "dataType": "numeric"
          },
          "defaultValue": 30
        },
        {
          "name": "Product",
          "valueConstraints": {
            "dataType": "string",
            "enum": [
              "iPhone",
              "Samsung"
            ]
          },
          "defaultValue": "iPhone"
        },
        {
          "name": "Offertext",
          "valueConstraints": {
            "dataType": "string"
          },
          "defaultValue": "Get a new IPhone now and get 30% off iPad"
        },
        {
          "name": "Budget",
          "valueConstraints": {
            "dataType": "numeric",
            "readOnly": true
          },
          "defaultValue": 500
        },
        {
          "name": "Goal",
          "valueConstraints": {
            "dataType": "string",
            "format": "date"
          },
          "defaultValue": "2018-07-13"
        },
        {
          "name": "TimesClicked",
          "valueConstraints": {
            "dataType": "numeric"
          }
        }
      ]
    }
    
    application/vnd.sas.treatment.definition.group

    Contains treatment definitions, attribute value mappings, and attribute name aliases.

    The schema is at treatmentDefinitionGroup.

    application/vnd.sas.treatment.definition.group+json

    Here is an example of the JSON representation for this media type.

    
     {
      "name": "My Treatment Definition Group",
      "members": [
        {
          "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692"
        },
        {
          "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692",
          "definitionRevisionId": "f813702e-dff8-443e-a7af-727ab027fb7e",
          "attributeValueMappings": [
            {
              "attributeId": "4482c7f8-5e32-4ee2-9253-45738856e9b2",
              "mappingType": "variable",
              "value": "Discount"
            },
            {
              "attributeId": "6f9e1fba-1870-4753-858a-a5454b04924e",
              "mappingType": "constant",
              "value": "Samsung"
            },
            {
              "attributeId": "bdd8f873-d169-4915-bef0-ad7fd5ac02f0",
              "mappingType": "variable",
              "value": "Clicked"
            }
          ],
          "attributeNameAliases": [
            {
              "attributeId": "4482c7f8-5e32-4ee2-9253-45738856e9b2",
              "aliasName": "Discount ID"
            }
          ]
        }
      ]
    }
    
    application/vnd.sas.summary

    Provides summary information for the treatment definition.

    The schema is at summary.

    Resource Relationships

    Resource relationship diagram

    NOTE: The treatment definition group can contain multiple treatment definitions. A treatment definition can be part of more than one treatment definition group.

    Root

    Path: /

    The root of the API. This resource contains links to the top-level resources in the API. The response uses the application/vnd.sas.api media type.

    The GET / response includes the following links.

    Relation Method Description
    treatmentDefinitions GET Returns the first page of the collection of treatment definitions.
    Response type: application/vnd.sas.collection.
    createTreatmentDefinition POST Creates a new treatment definition.
    Request type: application/vnd.sas.treatment.definition.
    Response type: application/vnd.sas.treatment.definition.
    treatmentDefinitionGroups GET Returns the first page of the collection of treatment definition group.
    Response type: application/vnd.sas.collection.
    createTreatmentDefinitionGroup POST Creates a new treatment definition group.
    Request type: application/vnd.sas.treatment.definition.group.
    Response type: application/vnd.sas.treatment.definition.group.
    Treatment Definitions

    Path: /definitions

    Path: /definitions/{definitionId}/revisions

    Path: /definitionRevisions

    This API provides a collection of the treatment definitions.

    Default page size is 10.

    The treatmentDefinitions collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.treatment.definition resources or application/vnd.sas.summary. (These types apply to the response for the self, collection, prev, next, first, and last links below.)

    Responses include the following links for the paths /definitions and /definitions/{definitionId}/revisions.

    Relation Method Description
    create POST Creates a new treatment definition in the collection.
    This link is available only when the requester has authorization to create a new treatment definition.
    Request type: application/vnd.sas.treatment.definition
    Response type: application/vnd.sas.treatment.definition
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.

    Responses include the following links for the path /definitionRevisions.

    Relation Method Description
    self POST Returns the current page of the collection.
    Response type: application/vnd.sas.collection.
    prev POST Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next POST Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first POST Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last POST Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters for the paths /definitions and /definitions/{definitionId}/revisions.

    Filtering and sorting can use the following members of the treatmentDefinition:

    Treatment Definition

    Path: /definitions/{definitionId}

    Path: /definitions/{definitionId}/revisions/{revisionId}

    This API provides the treatment definition.

    The treatmentDefinition representation is application/vnd.sas.treatment.definition.

    Responses include the following links.

    Relation Method Description
    up GET Gets the list of treatment definitions to which this treatment definition belongs.
    Response type: application/vnd.sas.collection.
    self GET Returns the treatment definition by ID.
    Response type: application/vnd.sas.treatment.definition.
    alternate GET Returns the treatment definition summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the treatment definition by ID.
    update PUT Updates a treatment definition.
    Request type: application/vnd.sas.treatment.definition.
    Response type: application/vnd.sas.treatment.definition.
    Treatment Definition Summary

    Path: /definitions/{definitionId}

    Path: /definitions/{definitionId}/revisions/{revisionId}

    This API provides the treatment definition summary.

    The treatmentDefinitionSummary representation is application/vnd.sas.summary.

    Responses include the following links.

    Relation Method Description
    up GET Gets the list of treatment definitions to which this treatment definition belongs.
    Response type: application/vnd.sas.collection.
    self GET Returns the treatment definition by ID.
    Response type: application/vnd.sas.treatment.definition.
    alternate GET Returns the treatment definition summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the treatment definition by ID.
    update PUT Updates a treatment.
    Request type: application/vnd.sas.treatment.definition.
    Response type: application/vnd.sas.treatment.definition.
    Treatment Definition Groups

    Path: /definitionGroups

    Path: /definitionGroups/{groupId}/revisions

    Path: /definitionGroupRevisions

    This API provides a collection of the treatmentDefinitionGroup.

    Default page size is 10.

    The treatmentDefinitionGroup collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.treatment.definition.group resources or application/vnd.sas.summary. (These types apply to the response for the self, collection, prev, next, first, and last links below.)

    Responses include the following links for the paths /definitionGroups and /definitionGroups/{groupId}/revisions.

    Relation Method Description
    create POST Creates a new treatmentDefinitionGroup in the collection.
    This link is available only when the requester has authorization to create a new treatmentDefinitionGroup.
    Request type: application/vnd.sas.treatment.definition.group
    Response type: application/vnd.sas.treatment.definition.group
    self GET Returns the current page of the collection.
    Response type: application/vnd.sas.collection.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    Response type: application/vnd.sas.collection.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.

    Responses include the following links for the path /definitionGroupRevisions.

    Relation Method Description
    self POST Returns the current page of the collection.
    Response type: application/vnd.sas.collection.
    prev POST Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    next POST Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page of the collection.
    Response type: application/vnd.sas.collection.
    first POST Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    Response type: application/vnd.sas.collection.
    last POST Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    Response type: application/vnd.sas.collection.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters for the paths /definitionGroups and /definitionGroups/{groupId}/revisions.

    Filtering and sorting can use the following members of the treatmentDefinitionGroup:

    Treatment Definition Group

    Path: /definitionGroups/{groupId}

    Path: /definitionGroups/{groupId}/revisions/{revisionId}

    This API provides the treatmentDefinitionGroup.

    The treatmentDefinitionGroup representation is application/vnd.sas.treatment.definition.group.

    Responses include the following links.

    Relation Method Description
    up GET Gets the list of treatmentDefinitionGroup to which this treatmentDefinitionGroup belongs.
    Response type: application/vnd.sas.collection.
    self GET Returns the treatmentDefinitionGroup by ID.
    Response type: application/vnd.sas.treatment.definition.group.
    alternate GET Returns the treatmentDefinitionGroup summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the treatmentDefinitionGroup by ID.
    update PUT Updates a treatmentDefinitionGroup.
    Request type: application/vnd.sas.treatment.definition.group.
    Response type: application/vnd.sas.treatment.definition.group.
    Treatment Definition Group Summary

    Path: /definitionGroups/{groupId}

    Path: /definitionGroups/{groupId}/revisions/{revisionId}

    This API provides the treatmentDefinitionGroup summary.

    The treatmentDefinitionGroupSummary representation is application/vnd.sas.summary.

    Responses include the following links.

    Relation Method Description
    up GET Gets the list of treatmentDefinitionGroup to which this treatmentDefinitionGroup belongs.
    Response type: application/vnd.sas.collection.
    self GET Returns the treatmentDefinitionGroup by ID.
    Response type: application/vnd.sas.treatment.definition.group.
    alternate GET Returns the treatmentDefinitionGroup summary by ID.
    Response type: application/vnd.sas.summary.
    delete DELETE Deletes the treatmentDefinitionGroup by ID.
    update PUT Updates a treatmentDefinitionGroup.
    Request type: application/vnd.sas.treatment.definition.group.
    Response type: application/vnd.sas.treatment.definition.group.

    Subject Contacts

    Base URLs:

    Terms of service Email: SAS Developers Web: SAS Developers

    Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

    The Subject Contacts API records contacts to subjects and records documents that are produced when executing decisions and business rules.

    Usage Notes

    Overview

    You can use the Subject Contacts API to record a subject's response to a contact that consists of marketing offers. This information can be useful when making decisions about future marketing offers.

    The Subject Contacts API can be used in the following workflow:

    You can also use the Subject Contacts API to record text that is produced when executing a decision.

    Security

    Please see Security in SAS REST APIs for details about authentication and authorization.

    Authorization rules for the treatment histories:

    Terminology

    attribute alias

    an alternative name that can be assigned to an attribute within a treatment group. The alternative name can be the name of another attribute or a custom name.

    contact

    a communication sent to an individual. In this context, the content of the communication deals with treatments.

    contact history

    the record of information that has been presented to the subject, and if available, the subject’s response. Contact history might include treatments, analysis data, and individual values of variables.

    contact rule

    rules that determine whether it is appropriate to contact a subject at this time. Frequency of contact is usually a factor. Another factor might be if and how the subject responded to previous contacts.

    response

    the reaction that a customer has to a treatment.

    subject

    a person, household, organization, or other entity that represents a potential customer.

    subject ID

    the identifier of a subject.

    subject level

    a string that describes the subject type. For example, a potential subject can be an individual, a household, an account of an organization etc.

    trace

    a block of text that records the variables in a decision and how the values of those variables change from the start step of the decision to the end step. There are two types of traces: a decision step boundary and a variable assignment.

    trace - decision step boundary

    a decision step boundary trace records only the change of variable values when a decision step is entered and exited. Decision step variables explicitly identified as inputs or outputs are traced.

    trace - variable assignment

    a variable assignment trace records the change of variable values at the times when assignments are made. As such, each decision variable's value, even intermediate values, or the values of temporary variables are recorded.

    trace report

    a processed version of the trace.

    treatment

    an offer that is returned by a decision and can be sent to a subject.

    treatment attribute

    a user-defined piece of information that is part of a treatment, such as the text that is displayed to the customer, a discount rate, or the model number of a product.

    treatment definition

    the set of eligibility rules and attributes that define an offer.

    treatment definition group

    a set of treatment definitions, customized attribute values, and additional data that can be added to a decision.

    treatment presented

    a treatment is presented to a subject if the subject receives it directly or is told of it by an agent.

    Operations

    Root

    Contains the operations for the root resource.

    Code samples

    # You can also use wget
    curl -X GET https://example.com/subjectContacts/ \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.api+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.api+json'
    };
    
    fetch('https://example.com/subjectContacts/',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.api+json'
    }
    
    r = requests.get('https://example.com/subjectContacts/', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.api+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/subjectContacts/", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /

    Returns a list of links to the top-level resources in this API.

    Example responses

    SubjectContacts root content.

    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "contacts",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "createContact",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.business.rule.set",
          "responseType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    
    {
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "contacts",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "createContact",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.business.rule.set",
          "responseType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. Inline

    Status Code 200

    API

    Name Type Required Restrictions Description
    » version integer true none The version number of the API representation. This is version 1.
    » links [link] true none The API's top-level links.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Contacts

    Contains the operations for the contacts resource.

    Get all contacts

    Code samples

    # You can also use wget
    curl -X GET https://example.com/subjectContacts/contacts \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.collection+json' \
      -H 'Accept-Item: application/vnd.sas.summary+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.collection+json',
      'Accept-Item':'application/vnd.sas.summary+json'
    };
    
    fetch('https://example.com/subjectContacts/contacts',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.collection+json',
      'Accept-Item': 'application/vnd.sas.summary+json'
    }
    
    r = requests.get('https://example.com/subjectContacts/contacts', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.collection+json"},
            "Accept-Item": []string{"application/vnd.sas.summary+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/subjectContacts/contacts", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /contacts

    Returns a collection of information about each contact made. Each item also contains the presentation, and the response to that contact.

    Parameters
    Name In Type Required Description
    start query integer false The starting index of the first item on a page. The index is 0-based. The default index is 0.
    limit query integer false 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.
    sortBy query string(sort-criteria) false The sorting criteria for the returned contacts. The default sort order is creationTimeStamp:descending.
    filter query string(filter-criteria) false The filter criteria for the returned contacts. All fields of application/vnd.sas.decision.subject.contact can be used in the filter.
    Accept-Item header string false Select the desired item representation.
    Enumerated Values
    Parameter Value
    Accept-Item application/vnd.sas.decision.subject.contact+json
    Accept-Item application/vnd.sas.search.indexable.data+json
    Accept-Item application/vnd.sas.summary+json

    Example responses

    Subject contact collection.

    {
      "name": "contacts",
      "accept": "application/vnd.sas.decision.subject.contact",
      "count": 2,
      "start": 0,
      "limit": 5,
      "items": [
        {
          "creationTimeStamp": "2018-05-13T15:02:40.719Z",
          "modifiedTimeStamp": "2018-05-13T18:32:40.719Z",
          "createdBy": "joeMarket",
          "modifiedBy": "joeMarket",
          "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
          "subjectId": "Francis.Albert.Bacon.19195313421",
          "subjectLevel": "household",
          "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
          "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
          "objectType": "decision",
          "objectVariables": [
            {
              "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
              "name": "ov1",
              "value": "A",
              "dataType": "string"
            },
            {
              "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
              "name": "ov2",
              "value": "B",
              "dataType": "string"
            }
          ],
          "treatmentsForConsideration": [
            {
              "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
              "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
              "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
              "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
              "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
              "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
              "presented": true,
              "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
              "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
            },
            {
              "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
              "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
              "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
              "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
              "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
              "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
              "presented": true,
              "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
              "responseValue": "accepted",
              "responseType": "rt_1",
              "respondedTimeStamp": "2018-05-13T18:11:10.687Z",
              "responseChannel": "web",
              "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
            },
            {
              "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
              "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
              "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
              "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
              "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
              "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
              "presented": true,
              "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
              "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
            }
          ],
          "ruleFired": "00010",
          "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
          "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
          "receiverId": "Francis.Albert.Bacon.19195313421",
          "receiverRole": "customer",
          "excludeFromContactRule": false,
          "channel": "web",
          "conclusionResponseValue": "",
          "conclusionResponseType": "crt_x",
          "version": 1,
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "type": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "POST",
              "rel": "create",
              "href": "/subjectContacts/contacts",
              "uri": "/subjectContacts/contacts",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "PATCH",
              "rel": "patch",
              "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
            },
            {
              "method": "GET",
              "rel": "up",
              "href": "/subjectContacts/contacts",
              "uri": "/subjectContacts/contacts",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.subject.contact"
            }
          ]
        },
        {
          "creationTimeStamp": "2018-05-13T18:01:01.203Z",
          "modifiedTimeStamp": "2018-05-13T18:01:01.203Z",
          "createdBy": "joeMarket",
          "modifiedBy": "joeMarket",
          "id": "39657793-736b-462f-8d37-31c04b680657",
          "objectUri": "/decisions/flows/525b199b-9073-4359-a521-ff1bc8a59145",
          "objectRevisionId": "e4728fe2-35ce-4ac6-84e0-fd0cad3f0e80",
          "objectType": "decision",
          "objectVariables": [
            {
              "name": "ov1",
              "value": "A",
              "dataType": "string"
            },
            {
              "name": "ov2",
              "value": "B",
              "dataType": "string"
            }
          ],
          "subjectId": "Francis.Albert.Bacon.19195313421",
          "subjectLevel": "household",
          "ruleFired": "111101",
          "pathTraversed": "/ddc3f087-e313-4f63-8404-45a51257df0b/5cb79bb7-1ba2-4c1d-a17c-5d0894ebc046/1111ee7e-7135-4397-bb1d-2aa0a680b9aa",
          "responseTrackingCode": "BigSaver.08c3f2f6-2d1f-45ed-9cd4-511fa7b40054",
          "receiverId": "CallCenter.71.310",
          "receiverRole": "agent",
          "conclusionResponseValue": "",
          "conclusionResponseType": "crt_x",
          "treatmentsForConsideration": [
            {
              "id": "7b34d631-2f16-4d7a-ac55-3cbe9a661a6c",
              "subjectContactId": "39657793-736b-462f-8d37-31c04b680657",
              "treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086",
              "treatmentRevisionId": "efb511c1-ad37-4a3d-8a8f-e259d8dc2812",
              "treatmentGroupId": "82d4e377-16ab-4165-a923-c38c45cd3a01",
              "treatmentGroupRevisionId": "2c72fe78-09df-44ff-9039-23f1272390b9",
              "objectNodeId": "3670f308-fe1a-46b0-96de-b97a09db0be5",
              "presented": false
            }
          ],
          "excludeFromContactRule": false,
          "channel": "phone",
          "version": 1,
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "uri": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "type": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "uri": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "POST",
              "rel": "create",
              "href": "/subjectContacts/contacts",
              "uri": "/subjectContacts/contacts",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "PATCH",
              "rel": "patch",
              "href": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "uri": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "uri": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657"
            },
            {
              "method": "GET",
              "rel": "up",
              "href": "/subjectContacts/contacts",
              "uri": "/subjectContacts/contacts",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.subject.contact"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts?limit=5&filter=and(eq(subjectId,'Francis.Albert.Bacon.19195313421'),eq(subjectLevel,'household'))&sortBy=creationTimeStamp:ascending&start=0",
          "uri": "/subjectContacts/contacts?limit=5&filter=and(eq(subjectId,'Francis.Albert.Bacon.19195313421'),eq(subjectLevel,'household'))&sortBy=creationTimeStamp:ascending&start=0",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/",
          "uri": "/subjectContacts/",
          "type": "application/vnd.sas.api"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        }
      ],
      "version": 2
    }
    
    {
      "name": "contacts",
      "accept": "application/vnd.sas.decision.subject.contact",
      "count": 2,
      "start": 0,
      "limit": 5,
      "items": [
        {
          "creationTimeStamp": "2018-05-13T15:02:40.719Z",
          "modifiedTimeStamp": "2018-05-13T18:32:40.719Z",
          "createdBy": "joeMarket",
          "modifiedBy": "joeMarket",
          "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
          "subjectId": "Francis.Albert.Bacon.19195313421",
          "subjectLevel": "household",
          "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
          "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
          "objectType": "decision",
          "objectVariables": [
            {
              "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
              "name": "ov1",
              "value": "A",
              "dataType": "string"
            },
            {
              "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
              "name": "ov2",
              "value": "B",
              "dataType": "string"
            }
          ],
          "treatmentsForConsideration": [
            {
              "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
              "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
              "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
              "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
              "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
              "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
              "presented": true,
              "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
              "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
            },
            {
              "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
              "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
              "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
              "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
              "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
              "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
              "presented": true,
              "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
              "responseValue": "accepted",
              "responseType": "rt_1",
              "respondedTimeStamp": "2018-05-13T18:11:10.687Z",
              "responseChannel": "web",
              "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
            },
            {
              "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
              "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
              "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
              "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
              "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
              "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
              "presented": true,
              "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
              "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
            }
          ],
          "ruleFired": "00010",
          "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
          "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
          "receiverId": "Francis.Albert.Bacon.19195313421",
          "receiverRole": "customer",
          "excludeFromContactRule": false,
          "channel": "web",
          "conclusionResponseValue": "",
          "conclusionResponseType": "crt_x",
          "version": 1,
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "type": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "POST",
              "rel": "create",
              "href": "/subjectContacts/contacts",
              "uri": "/subjectContacts/contacts",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "PATCH",
              "rel": "patch",
              "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
              "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
            },
            {
              "method": "GET",
              "rel": "up",
              "href": "/subjectContacts/contacts",
              "uri": "/subjectContacts/contacts",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.subject.contact"
            }
          ]
        },
        {
          "creationTimeStamp": "2018-05-13T18:01:01.203Z",
          "modifiedTimeStamp": "2018-05-13T18:01:01.203Z",
          "createdBy": "joeMarket",
          "modifiedBy": "joeMarket",
          "id": "39657793-736b-462f-8d37-31c04b680657",
          "objectUri": "/decisions/flows/525b199b-9073-4359-a521-ff1bc8a59145",
          "objectRevisionId": "e4728fe2-35ce-4ac6-84e0-fd0cad3f0e80",
          "objectType": "decision",
          "objectVariables": [
            {
              "name": "ov1",
              "value": "A",
              "dataType": "string"
            },
            {
              "name": "ov2",
              "value": "B",
              "dataType": "string"
            }
          ],
          "subjectId": "Francis.Albert.Bacon.19195313421",
          "subjectLevel": "household",
          "ruleFired": "111101",
          "pathTraversed": "/ddc3f087-e313-4f63-8404-45a51257df0b/5cb79bb7-1ba2-4c1d-a17c-5d0894ebc046/1111ee7e-7135-4397-bb1d-2aa0a680b9aa",
          "responseTrackingCode": "BigSaver.08c3f2f6-2d1f-45ed-9cd4-511fa7b40054",
          "receiverId": "CallCenter.71.310",
          "receiverRole": "agent",
          "conclusionResponseValue": "",
          "conclusionResponseType": "crt_x",
          "treatmentsForConsideration": [
            {
              "id": "7b34d631-2f16-4d7a-ac55-3cbe9a661a6c",
              "subjectContactId": "39657793-736b-462f-8d37-31c04b680657",
              "treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086",
              "treatmentRevisionId": "efb511c1-ad37-4a3d-8a8f-e259d8dc2812",
              "treatmentGroupId": "82d4e377-16ab-4165-a923-c38c45cd3a01",
              "treatmentGroupRevisionId": "2c72fe78-09df-44ff-9039-23f1272390b9",
              "objectNodeId": "3670f308-fe1a-46b0-96de-b97a09db0be5",
              "presented": false
            }
          ],
          "excludeFromContactRule": false,
          "channel": "phone",
          "version": 1,
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "uri": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "type": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "PUT",
              "rel": "update",
              "href": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "uri": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "POST",
              "rel": "create",
              "href": "/subjectContacts/contacts",
              "uri": "/subjectContacts/contacts",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "PATCH",
              "rel": "patch",
              "href": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "uri": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "type": "application/vnd.sas.decision.subject.contact",
              "responseType": "application/vnd.sas.decision.subject.contact"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657",
              "uri": "/subjectContacts/contacts/39657793-736b-462f-8d37-31c04b680657"
            },
            {
              "method": "GET",
              "rel": "up",
              "href": "/subjectContacts/contacts",
              "uri": "/subjectContacts/contacts",
              "type": "application/vnd.sas.collection",
              "itemType": "application/vnd.sas.decision.subject.contact"
            }
          ]
        }
      ],
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts?limit=5&filter=and(eq(subjectId,'Francis.Albert.Bacon.19195313421'),eq(subjectLevel,'household'))&sortBy=creationTimeStamp:ascending&start=0",
          "uri": "/subjectContacts/contacts?limit=5&filter=and(eq(subjectId,'Francis.Albert.Bacon.19195313421'),eq(subjectLevel,'household'))&sortBy=creationTimeStamp:ascending&start=0",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/",
          "uri": "/subjectContacts/",
          "type": "application/vnd.sas.api"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        }
      ],
      "version": 2
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. subjectContactCollection
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create a new contact record

    Code samples

    # You can also use wget
    curl -X POST https://example.com/subjectContacts/contacts \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.subject.contact+json' \
      -H 'Accept: application/vnd.sas.decision.subject.contact+json'
    
    
    const inputBody = '{
      "subjectId": "string",
      "subjectLevel": "string",
      "objectUri": "string",
      "objectRevisionId": "string",
      "objectType": "string",
      "objectVariables": [
        {
          "name": "string",
          "value": "string",
          "dataType": "boolean"
        }
      ],
      "treatmentsForConsideration": [
        {
          "treatmentId": "string",
          "treatmentRevisionId": "string",
          "treatmentGroupId": "string",
          "treatmentGroupRevisionId": "string",
          "objectNodeId": "string",
          "presented": true,
          "presentedTimeStamp": "2019-08-24T14:15:22Z",
          "respondedTimeStamp": "2019-08-24T14:15:22Z",
          "responseValue": "string",
          "responseType": "string",
          "responseChannel": "string",
          "subjectContactId": "string"
        }
      ],
      "ruleFired": "string",
      "pathTraversed": "string",
      "responseTrackingCode": "string",
      "receiverId": "string",
      "receiverRole": "string",
      "channel": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "conclusionResponseValue": "string",
      "conclusionResponseType": "string",
      "excludeFromContactRule": true
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.subject.contact+json',
      'Accept':'application/vnd.sas.decision.subject.contact+json'
    };
    
    fetch('https://example.com/subjectContacts/contacts',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.subject.contact+json',
      'Accept': 'application/vnd.sas.decision.subject.contact+json'
    }
    
    r = requests.post('https://example.com/subjectContacts/contacts', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.subject.contact+json"},
            "Accept": []string{"application/vnd.sas.decision.subject.contact+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/subjectContacts/contacts", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /contacts

    The contact and response are recorded. If the presentation is configured to be recorded, it can be recorded at this time or deferred to a future update. The PATCH action can be used with the responseTrackingCode property to make the update and record the response to the treatment. If the operation is to be fulfilled asynchronously by using asynchronous=true, a resource ID is issued without waiting for the completion of the operation. The endpoint returns a URI for retrieving the resource in the Location response header. An HTTP status of 202 is returned.

    Body parameter

    {
      "subjectId": "string",
      "subjectLevel": "string",
      "objectUri": "string",
      "objectRevisionId": "string",
      "objectType": "string",
      "objectVariables": [
        {
          "name": "string",
          "value": "string",
          "dataType": "boolean"
        }
      ],
      "treatmentsForConsideration": [
        {
          "treatmentId": "string",
          "treatmentRevisionId": "string",
          "treatmentGroupId": "string",
          "treatmentGroupRevisionId": "string",
          "objectNodeId": "string",
          "presented": true,
          "presentedTimeStamp": "2019-08-24T14:15:22Z",
          "respondedTimeStamp": "2019-08-24T14:15:22Z",
          "responseValue": "string",
          "responseType": "string",
          "responseChannel": "string",
          "subjectContactId": "string"
        }
      ],
      "ruleFired": "string",
      "pathTraversed": "string",
      "responseTrackingCode": "string",
      "receiverId": "string",
      "receiverRole": "string",
      "channel": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "conclusionResponseValue": "string",
      "conclusionResponseType": "string",
      "excludeFromContactRule": true
    }
    
    Parameters
    Name In Type Required Description
    asynchronous query boolean false Whether the operation is to be carried out asynchronously or not. The default is false.
    body body subjectContact true The contact and response representation.

    Example responses

    Subject contact full representation.

    {
      "creationTimeStamp": "2018-05-13T15:02:40.719Z",
      "modifiedTimeStamp": "2018-05-13T15:02:40.719Z",
      "createdBy": "joeMarket",
      "modifiedBy": "joeMarket",
      "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
      "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
      "objectType": "decision",
      "objectVariables": [
        {
          "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "treatmentsForConsideration": [
        {
          "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
          "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
          "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
          "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
          "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
          "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
          "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
          "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
          "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
          "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        }
      ],
      "ruleFired": "00010",
      "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
      "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
      "receiverId": "Francis.Albert.Bacon.19195313421",
      "receiverRole": "customer",
      "channel": "web",
      "excludeFromContactRule": false,
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PATCH",
          "rel": "patch",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2018-05-13T15:02:40.719Z",
      "modifiedTimeStamp": "2018-05-13T15:02:40.719Z",
      "createdBy": "joeMarket",
      "modifiedBy": "joeMarket",
      "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
      "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
      "objectType": "decision",
      "objectVariables": [
        {
          "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "treatmentsForConsideration": [
        {
          "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
          "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
          "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
          "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
          "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
          "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
          "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
          "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
          "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
          "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        }
      ],
      "ruleFired": "00010",
      "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
      "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
      "receiverId": "Francis.Albert.Bacon.19195313421",
      "receiverRole": "customer",
      "channel": "web",
      "excludeFromContactRule": false,
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PATCH",
          "rel": "patch",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    

    Subject contact recorded asynchronously.

    {
      "id": "39657793-736b-462f-8d37-31c04b680657",
      "objectUri": "/decisions/flows/525b199b-9073-4359-a521-ff1bc8a59145",
      "objectRevisionId": "e4728fe2-35ce-4ac6-84e0-fd0cad3f0e80",
      "objectType": "decision",
      "objectVariables": [
        {
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "ruleFired": "111101",
      "pathTraversed": "/ddc3f087-e313-4f63-8404-45a51257df0b/5cb79bb7-1ba2-4c1d-a17c-5d0894ebc046/1111ee7e-7135-4397-bb1d-2aa0a680b9aa",
      "responseTrackingCode": "BigSaver.08c3f2f6-2d1f-45ed-9cd4-511fa7b40054",
      "receiverId": "CallCenter.71.310",
      "receiverRole": "agent",
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "treatmentsForConsideration": [
        {
          "treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086",
          "treatmentRevisionId": "efb511c1-ad37-4a3d-8a8f-e259d8dc2812",
          "treatmentGroupId": "82d4e377-16ab-4165-a923-c38c45cd3a01",
          "treatmentGroupRevisionId": "2c72fe78-09df-44ff-9039-23f1272390b9",
          "objectNodeId": "3670f308-fe1a-46b0-96de-b97a09db0be5",
          "presented": false
        }
      ],
      "excludeFromContactRule": false,
      "channel": "phone"
    }
    
    {
      "id": "39657793-736b-462f-8d37-31c04b680657",
      "objectUri": "/decisions/flows/525b199b-9073-4359-a521-ff1bc8a59145",
      "objectRevisionId": "e4728fe2-35ce-4ac6-84e0-fd0cad3f0e80",
      "objectType": "decision",
      "objectVariables": [
        {
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "ruleFired": "111101",
      "pathTraversed": "/ddc3f087-e313-4f63-8404-45a51257df0b/5cb79bb7-1ba2-4c1d-a17c-5d0894ebc046/1111ee7e-7135-4397-bb1d-2aa0a680b9aa",
      "responseTrackingCode": "BigSaver.08c3f2f6-2d1f-45ed-9cd4-511fa7b40054",
      "receiverId": "CallCenter.71.310",
      "receiverRole": "agent",
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "treatmentsForConsideration": [
        {
          "treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086",
          "treatmentRevisionId": "efb511c1-ad37-4a3d-8a8f-e259d8dc2812",
          "treatmentGroupId": "82d4e377-16ab-4165-a923-c38c45cd3a01",
          "treatmentGroupRevisionId": "2c72fe78-09df-44ff-9039-23f1272390b9",
          "objectNodeId": "3670f308-fe1a-46b0-96de-b97a09db0be5",
          "presented": false
        }
      ],
      "excludeFromContactRule": false,
      "channel": "phone"
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    201 Created A resource was created. subjectContact
    202 Accepted The asynchronous request is accepted for processing, but the processing has not been completed. subjectContact
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    201 Location string The URI of the contact.
    201 ETag string A tag that identifies this contact.
    202 Location string The URI of the contact.

    Export contact records

    Code samples

    # You can also use wget
    curl -X GET https://example.com/subjectContacts/contacts#multiples \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/csv' \
      -H 'Accept: text/csv, application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'text/csv',
      'Accept':'text/csv, application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/subjectContacts/contacts#multiples',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/csv',
      'Accept': 'text/csv, application/vnd.sas.error+json'
    }
    
    r = requests.get('https://example.com/subjectContacts/contacts#multiples', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/csv"},
            "Accept": []string{"text/csv, application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/subjectContacts/contacts#multiples", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /contacts#multiples

    Exports contacts as CSV text. A filter can be used to select the contacts. If a filter is not used, all contacts are returned. The output is not pageable nor sortable. A header is not returned by default. To add a header, add the header=present option to the text/csv media type. The columns are:

    Parameters
    Name In Type Required Description
    Accept header string true In addition to text/csv, also include application/vnd.sas.error+json in the Accept header. The two media types are separated by a comma. If there is a processing error, the error is reported in a JSON error object. In that case, without this arrangement, since the client is expecting only a response of text/csv type, the server uses Http status of 406 to tell the client that it cannot match the expectation because a JSON error object cannot be mapped into a text/csv response. By also accepting application/vnd.sas.error+json, this is avoided.
    filter query string(filter-criteria) false The filter criteria for the returned contacts. All fields of application/vnd.sas.decision.subject.contact can be used in the filter. If a filter is not used, all the contacts are returned.
    Enumerated Values
    Parameter Value
    Accept text/csv, application/vnd.sas.error+json

    Example responses

    Subject contact records exported as CSV.

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Not acceptable.

    {
      "httpStatusCode": 406,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. The export was successful. string
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    406 Not Acceptable The media type is incompatible. Occurs when there is an error but the error response media type is not compatible with the text/csv media type. The server returns this status error instead. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 406

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    406 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Create contact records from CSV

    Code samples

    # You can also use wget
    curl -X POST https://example.com/subjectContacts/contacts#multiples \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: text/csv' \
      -H 'Accept: multipart/mixed' \
      -H 'Accept: multipart/mixed, application/vnd.sas.error+json' \
      -H 'If-Unmodified-Since: string'
    
    
    const inputBody = 'string';
    const headers = {
      'Content-Type':'text/csv',
      'Accept':'multipart/mixed',
      'Accept':'multipart/mixed, application/vnd.sas.error+json',
      'If-Unmodified-Since':'string'
    };
    
    fetch('https://example.com/subjectContacts/contacts#multiples',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'text/csv',
      'Accept': 'multipart/mixed',
      'Accept': 'multipart/mixed, application/vnd.sas.error+json',
      'If-Unmodified-Since': 'string'
    }
    
    r = requests.post('https://example.com/subjectContacts/contacts#multiples', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"text/csv"},
            "Accept": []string{"multipart/mixed"},
            "Accept": []string{"multipart/mixed, application/vnd.sas.error+json"},
            "If-Unmodified-Since": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/subjectContacts/contacts#multiples", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /contacts#multiples

    Creates contact records from a CSV file. It imports the CSV text with a header row that specifies the order of these required columns:

    A contact might require one or more rows of CSV text to describe it. There is one row for each treatment to be considered. A contact can include more than one treatment. The information in the columns from responseTrackingCode to pathTraversed are repeated. The columns from treatmentId to responseChannel contain unique information per row.

    CSV text that is obtained by the counterpart GET action can be used here. The GET action includes an ID column in the output. The import ignores the ID value and a new ID is generated for each contact. Importing the CSV text that is obtained by CSV exporting on the same deployment is not successful because there is a uniqueness constraint violation in the response tracking code value.

    In the objectVariables column, each name, value, dataType tuple in the array is represented as a triple tilde separated string and each tuple is separated by a semicolon. The strings cannot contain semicolons.

    The responseTrackingCode column cannot be blank.

    If the contact already exists, the unique information columns on the rows are used to update the contact. The other columns must carry information identical to what is already recorded. If this condition is not met, the update is rejected.

    These are the immutable columns:

    The input CSV is processed in the order it is received. All contiguous rows with the same responseTrackingCode are considered one section. Those rows are processed according to the description above. It is possible to have the same responseTrackingCode in non-consecutive sections. In that case, the subsequent section is considered updating the contact from the previous section. The service tries to process as many rows as possible.

    The output is a multipart/mixed response body. The boundary string of each part is identified in the Content-Type response header. There are three parts in this response.

    The first part is for the accepted CSV (header Content-ID: Accepted-CSV). Each contact that was successfully processed is included here. As soon as a contact is created, its rows are streamed back.

    The second part is for the rejected CSV (header Content-ID:Rejected-CSV). Each contact that failed processing is identified here. It is in CSV format with the following column order: record number in the entire CSV input, the columns from the input row, and error message. If one line of text has error, all the lines for that contact are rejected. This API prints the first line of the rejected text.

    The third part is for global issues (header Content-ID: Global-Issue). It is in CSV format with the following column order: responseTrackingCode or the asterisk value (i.e wildcard for all contacts), global error message that conveys the error that prevents any CSV processing. An example would be the lack of permissions.

    Body parameter

    Parameters
    Name In Type Required Description
    Accept header string true In addition to multipart/mixed, also include application/vnd.sas.error+json in the Accept header. The two media types are separated by a comma. If there is a processing error, the error is reported in a JSON error object. In that case, without this arrangement, since the client is expecting only a response of multipart/mixed type, the server uses Http status of 406 to tell the client that it cannot match the expectation because a JSON error object cannot be mapped into a multipart/mixed response. By also accepting application/vnd.sas.error+json, this is avoided.
    If-Unmodified-Since header string false Checks to see whether the existing subject contacts identified in the CSV have not been modified since the time specified in the value. If this is not true, the update is not performed. This header is not required when CSV text is used to create contact records. However, this header is required when the CSV text is used to update existing contact records. The value is a timestamp. An appropriate value might be a timestamp that marks a point past the last update of the records to be updated.
    body body string true The CSV that contains a header row.
    Enumerated Values
    Parameter Value
    Accept multipart/mixed, application/vnd.sas.error+json

    Example responses

    Subject contacts recorded using CSV text.

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Not acceptable.

    {
      "httpStatusCode": 406,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. One or more contacts were created. Check the response for any errors. Inline
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    406 Not Acceptable The media type is incompatible. Occurs when there is an error but the error response media type is not compatible with the multipart/mixed media type. The server returns this status error instead. Inline
    412 Precondition Failed The If-Unmodified-Since request header did not match the resource's last modified timestamp. The resource has changed. The "If-Match" header is not appropriate here because multiple records are included. Inline
    428 Precondition Required The 'If-Unmodified-Since' header was not sent. The "If-Match" header is not appropriate here because multiple records are included. Inline
    Response Schema

    Status Code 200

    Name Type Required Restrictions Description
    » part1 object false none Accepted response
    »» contentType string false none none
    »» contentId string false none none
    »» body string false none none
    » part2 object false none Rejected response
    »» contentType string false none none
    »» contentId string false none none
    »» body string false none none
    » part3 object false none Global issues
    »» contentType string false none none
    »» contentId string false none none
    »» body string false none none

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 406

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Location string The URI for retrieving the contacts that were created.

    Get a contact

    Code samples

    # You can also use wget
    curl -X GET https://example.com/subjectContacts/contacts/{contactId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.decision.subject.contact+json' \
      -H 'Accept: application/vnd.sas.decision.subject.contact+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.decision.subject.contact+json',
      'Accept':'application/vnd.sas.decision.subject.contact+json'
    };
    
    fetch('https://example.com/subjectContacts/contacts/{contactId}',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.decision.subject.contact+json',
      'Accept': 'application/vnd.sas.decision.subject.contact+json'
    }
    
    r = requests.get('https://example.com/subjectContacts/contacts/{contactId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.decision.subject.contact+json"},
            "Accept": []string{"application/vnd.sas.decision.subject.contact+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/subjectContacts/contacts/{contactId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /contacts/{contactId}

    Returns information about the contact.

    Parameters
    Name In Type Required Description
    contactId path string true The resource identifier of a contact.
    Accept header string false Selects the desired item representation.
    Enumerated Values
    Parameter Value
    Accept application/vnd.sas.decision.subject.contact+json
    Accept application/vnd.sas.summary+json

    Example responses

    Subject contact full representation.

    {
      "creationTimeStamp": "2018-05-13T15:02:40.719Z",
      "modifiedTimeStamp": "2018-05-13T15:02:40.719Z",
      "createdBy": "joeMarket",
      "modifiedBy": "joeMarket",
      "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
      "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
      "objectType": "decision",
      "objectVariables": [
        {
          "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "treatmentsForConsideration": [
        {
          "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
          "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
          "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
          "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
          "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
          "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
          "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
          "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
          "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
          "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        }
      ],
      "ruleFired": "00010",
      "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
      "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
      "receiverId": "Francis.Albert.Bacon.19195313421",
      "receiverRole": "customer",
      "channel": "web",
      "excludeFromContactRule": false,
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PATCH",
          "rel": "patch",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    

    Subject contact summary representation.

    {
      "creationTimeStamp": "2023-01-19T22:20:44.844Z",
      "modifiedTimeStamp": "2023-01-19T22:20:44.844Z",
      "createdBy": "bob",
      "modifiedBy": "bob",
      "id": "f178fe4a-be95-40c7-aed1-06bcfaa45518",
      "type": "subjectContact",
      "name": "fd220146-bc31-3148-8329-3347439a4792",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/f178fe4a-be95-40c7-aed1-06bcfaa45518",
          "uri": "/subjectContacts/contacts/f178fe4a-be95-40c7-aed1-06bcfaa45518",
          "type": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/subjectContacts/contacts/f178fe4a-be95-40c7-aed1-06bcfaa45518",
          "uri": "/subjectContacts/contacts/f178fe4a-be95-40c7-aed1-06bcfaa45518"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.summary"
        }
      ],
      "version": 2
    }
    

    Subject contact full representation.

    {
      "creationTimeStamp": "2018-05-13T15:02:40.719Z",
      "modifiedTimeStamp": "2018-05-13T15:02:40.719Z",
      "createdBy": "joeMarket",
      "modifiedBy": "joeMarket",
      "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
      "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
      "objectType": "decision",
      "objectVariables": [
        {
          "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "treatmentsForConsideration": [
        {
          "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
          "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
          "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
          "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
          "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
          "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
          "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
          "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
          "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
          "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        }
      ],
      "ruleFired": "00010",
      "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
      "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
      "receiverId": "Francis.Albert.Bacon.19195313421",
      "receiverRole": "customer",
      "channel": "web",
      "excludeFromContactRule": false,
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PATCH",
          "rel": "patch",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. subjectContact
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 ETag string A tag that identifies this contact.

    Update a contact record

    Code samples

    # You can also use wget
    curl -X PUT https://example.com/subjectContacts/contacts/{contactId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.subject.contact+json' \
      -H 'Accept: application/vnd.sas.decision.subject.contact+json' \
      -H 'If-Match: string' \
      -H 'If-Unmodified-Since: string'
    
    
    const inputBody = '{
      "subjectId": "string",
      "subjectLevel": "string",
      "objectUri": "string",
      "objectRevisionId": "string",
      "objectType": "string",
      "objectVariables": [
        {
          "name": "string",
          "value": "string",
          "dataType": "boolean"
        }
      ],
      "treatmentsForConsideration": [
        {
          "treatmentId": "string",
          "treatmentRevisionId": "string",
          "treatmentGroupId": "string",
          "treatmentGroupRevisionId": "string",
          "objectNodeId": "string",
          "presented": true,
          "presentedTimeStamp": "2019-08-24T14:15:22Z",
          "respondedTimeStamp": "2019-08-24T14:15:22Z",
          "responseValue": "string",
          "responseType": "string",
          "responseChannel": "string",
          "subjectContactId": "string"
        }
      ],
      "ruleFired": "string",
      "pathTraversed": "string",
      "responseTrackingCode": "string",
      "receiverId": "string",
      "receiverRole": "string",
      "channel": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "conclusionResponseValue": "string",
      "conclusionResponseType": "string",
      "excludeFromContactRule": true
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.subject.contact+json',
      'Accept':'application/vnd.sas.decision.subject.contact+json',
      'If-Match':'string',
      'If-Unmodified-Since':'string'
    };
    
    fetch('https://example.com/subjectContacts/contacts/{contactId}',
    {
      method: 'PUT',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.subject.contact+json',
      'Accept': 'application/vnd.sas.decision.subject.contact+json',
      'If-Match': 'string',
      'If-Unmodified-Since': 'string'
    }
    
    r = requests.put('https://example.com/subjectContacts/contacts/{contactId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.subject.contact+json"},
            "Accept": []string{"application/vnd.sas.decision.subject.contact+json"},
            "If-Match": []string{"string"},
            "If-Unmodified-Since": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PUT", "https://example.com/subjectContacts/contacts/{contactId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PUT /contacts/{contactId}

    Updates the contact record by replacing it. Use this endpoint to update the presentation or the response of the treatments in the contact. Presentation and responses can be updated multiple times. For example, a subject clicking a treatment link is one type of response and subsequent engagement (for example, taking the next step in a commercial flow) is another response. Depending on how the merchant wants to track responses, it can be multiple updates or just one update of the final response. Although some members of the contact record have changed, the full contact object is required for this action. Since some members are immutable, an error occurs if you attempt to change them. Furthermore, if a member is an array, it is an error to change the number of entries in the array. These are the immutable first and second-level members of the record:

    Do not alter the members that should not be changed. An alternative is to use the PATCH action, which requires only sending in members to be changed together with the response tracking code.

    At the successful completion of the PUT action, the full updated record is sent in the response.

    Body parameter

    {
      "subjectId": "string",
      "subjectLevel": "string",
      "objectUri": "string",
      "objectRevisionId": "string",
      "objectType": "string",
      "objectVariables": [
        {
          "name": "string",
          "value": "string",
          "dataType": "boolean"
        }
      ],
      "treatmentsForConsideration": [
        {
          "treatmentId": "string",
          "treatmentRevisionId": "string",
          "treatmentGroupId": "string",
          "treatmentGroupRevisionId": "string",
          "objectNodeId": "string",
          "presented": true,
          "presentedTimeStamp": "2019-08-24T14:15:22Z",
          "respondedTimeStamp": "2019-08-24T14:15:22Z",
          "responseValue": "string",
          "responseType": "string",
          "responseChannel": "string",
          "subjectContactId": "string"
        }
      ],
      "ruleFired": "string",
      "pathTraversed": "string",
      "responseTrackingCode": "string",
      "receiverId": "string",
      "receiverRole": "string",
      "channel": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "conclusionResponseValue": "string",
      "conclusionResponseType": "string",
      "excludeFromContactRule": true
    }
    
    Parameters
    Name In Type Required Description
    contactId path string true The resource identifier for a contact.
    If-Match header string false The ETag value that was returned from a GET, POST, or PATCH of the resource. If the ETag value does not match the ETag value of the resource, the update cannot be completed. This is preferred over the If-Unmodified-Since header.
    If-Unmodified-Since header string false The value of the last modified timestamp of the resource. If the resource has been updated since this time, the update cannot be completed.
    body body subjectContact true The full contact record.

    Example responses

    Subject contact full representation.

    {
      "creationTimeStamp": "2018-05-13T15:02:40.719Z",
      "modifiedTimeStamp": "2018-05-13T15:02:40.719Z",
      "createdBy": "joeMarket",
      "modifiedBy": "joeMarket",
      "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
      "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
      "objectType": "decision",
      "objectVariables": [
        {
          "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "treatmentsForConsideration": [
        {
          "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
          "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
          "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
          "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
          "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
          "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
          "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
          "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
          "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
          "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        }
      ],
      "ruleFired": "00010",
      "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
      "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
      "receiverId": "Francis.Albert.Bacon.19195313421",
      "receiverRole": "customer",
      "channel": "web",
      "excludeFromContactRule": false,
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PATCH",
          "rel": "patch",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2018-05-13T15:02:40.719Z",
      "modifiedTimeStamp": "2018-05-13T15:02:40.719Z",
      "createdBy": "joeMarket",
      "modifiedBy": "joeMarket",
      "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
      "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
      "objectType": "decision",
      "objectVariables": [
        {
          "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "treatmentsForConsideration": [
        {
          "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
          "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
          "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
          "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
          "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
          "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
          "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
          "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
          "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
          "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        }
      ],
      "ruleFired": "00010",
      "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
      "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
      "receiverId": "Francis.Albert.Bacon.19195313421",
      "receiverRole": "customer",
      "channel": "web",
      "excludeFromContactRule": false,
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PATCH",
          "rel": "patch",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. subjectContact
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    428 Precondition Required The request headers did not include a If-Match or 'If-Unmodified-Since' precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Location string The URI of the contact.
    200 ETag string A tag that identifies this contact.

    Patch a contact record

    Code samples

    # You can also use wget
    curl -X PATCH https://example.com/subjectContacts/contacts/{contactId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.subject.contact+json' \
      -H 'Accept: application/vnd.sas.decision.subject.contact+json' \
      -H 'If-Match: string' \
      -H 'If-Unmodified-Since: string'
    
    
    const inputBody = '{
      "subjectId": "string",
      "subjectLevel": "string",
      "objectUri": "string",
      "objectRevisionId": "string",
      "objectType": "string",
      "objectVariables": [
        {
          "name": "string",
          "value": "string",
          "dataType": "boolean"
        }
      ],
      "treatmentsForConsideration": [
        {
          "treatmentId": "string",
          "treatmentRevisionId": "string",
          "treatmentGroupId": "string",
          "treatmentGroupRevisionId": "string",
          "objectNodeId": "string",
          "presented": true,
          "presentedTimeStamp": "2019-08-24T14:15:22Z",
          "respondedTimeStamp": "2019-08-24T14:15:22Z",
          "responseValue": "string",
          "responseType": "string",
          "responseChannel": "string",
          "subjectContactId": "string"
        }
      ],
      "ruleFired": "string",
      "pathTraversed": "string",
      "responseTrackingCode": "string",
      "receiverId": "string",
      "receiverRole": "string",
      "channel": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "conclusionResponseValue": "string",
      "conclusionResponseType": "string",
      "excludeFromContactRule": true
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.subject.contact+json',
      'Accept':'application/vnd.sas.decision.subject.contact+json',
      'If-Match':'string',
      'If-Unmodified-Since':'string'
    };
    
    fetch('https://example.com/subjectContacts/contacts/{contactId}',
    {
      method: 'PATCH',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.subject.contact+json',
      'Accept': 'application/vnd.sas.decision.subject.contact+json',
      'If-Match': 'string',
      'If-Unmodified-Since': 'string'
    }
    
    r = requests.patch('https://example.com/subjectContacts/contacts/{contactId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.subject.contact+json"},
            "Accept": []string{"application/vnd.sas.decision.subject.contact+json"},
            "If-Match": []string{"string"},
            "If-Unmodified-Since": []string{"string"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("PATCH", "https://example.com/subjectContacts/contacts/{contactId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    PATCH /contacts/{contactId}

    Patches a contact record by sending a partial representation of the contact record, which includes a key field and the fields that are to be changed. The full object is sent in the response. If a field in the partial representation has the 'null' value, it is interpreted to mean that a value is not sent rather than having the value in the field erased.

    Body parameter

    {
      "subjectId": "string",
      "subjectLevel": "string",
      "objectUri": "string",
      "objectRevisionId": "string",
      "objectType": "string",
      "objectVariables": [
        {
          "name": "string",
          "value": "string",
          "dataType": "boolean"
        }
      ],
      "treatmentsForConsideration": [
        {
          "treatmentId": "string",
          "treatmentRevisionId": "string",
          "treatmentGroupId": "string",
          "treatmentGroupRevisionId": "string",
          "objectNodeId": "string",
          "presented": true,
          "presentedTimeStamp": "2019-08-24T14:15:22Z",
          "respondedTimeStamp": "2019-08-24T14:15:22Z",
          "responseValue": "string",
          "responseType": "string",
          "responseChannel": "string",
          "subjectContactId": "string"
        }
      ],
      "ruleFired": "string",
      "pathTraversed": "string",
      "responseTrackingCode": "string",
      "receiverId": "string",
      "receiverRole": "string",
      "channel": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "conclusionResponseValue": "string",
      "conclusionResponseType": "string",
      "excludeFromContactRule": true
    }
    
    Parameters
    Name In Type Required Description
    contactId path string true The resource identifier for a contact. Alternatively, use the delegate resource identifier @deriveFromContent. When this delegate resource identifier is used, the service looks into the request body for an identifier of the resource. In this case, it is the responseTrackingCode member of the partial contact record. This identifier is to be used in lieu of the actual resource identifier.
    If-Match header string false The ETag value that was returned from a GET, POST, or PATCH of the resource. If the ETag value does not match the ETag value of the resource, the update is not completed. This is preferred over the If-Unmodified-Since header.
    If-Unmodified-Since header string false The value of the last modified timestamp of the resource. If the resource has been updated since this time, the update cannot be completed.
    body body subjectContact true The contact and response representation.

    Example responses

    Subject contact full representation.

    {
      "creationTimeStamp": "2018-05-13T15:02:40.719Z",
      "modifiedTimeStamp": "2018-05-13T15:02:40.719Z",
      "createdBy": "joeMarket",
      "modifiedBy": "joeMarket",
      "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
      "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
      "objectType": "decision",
      "objectVariables": [
        {
          "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "treatmentsForConsideration": [
        {
          "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
          "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
          "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
          "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
          "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
          "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
          "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
          "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
          "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
          "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        }
      ],
      "ruleFired": "00010",
      "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
      "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
      "receiverId": "Francis.Albert.Bacon.19195313421",
      "receiverRole": "customer",
      "channel": "web",
      "excludeFromContactRule": false,
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PATCH",
          "rel": "patch",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    
    {
      "creationTimeStamp": "2018-05-13T15:02:40.719Z",
      "modifiedTimeStamp": "2018-05-13T15:02:40.719Z",
      "createdBy": "joeMarket",
      "modifiedBy": "joeMarket",
      "id": "5195ceb6-228e-439d-b3df-307197f1e7a7",
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
      "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
      "objectType": "decision",
      "objectVariables": [
        {
          "id": "a4722451-fb6f-4c9a-8bb8-4cf1eaba73c0",
          "name": "ov1",
          "value": "A",
          "dataType": "string"
        },
        {
          "id": "395aebd9-1646-4d84-9c05-d8e80efe72b7",
          "name": "ov2",
          "value": "B",
          "dataType": "string"
        }
      ],
      "treatmentsForConsideration": [
        {
          "id": "f025ee1f-a60a-4bb5-8236-0c697562653e",
          "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
          "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
          "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
          "treatmentGroupRevisionId": "9d2fccaa-428a-4604-a242-4f259ab8a553",
          "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "383bebdf-9378-4ed9-a2f3-127f53acfd22",
          "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
          "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "id": "23c1ebb8-7df8-4555-92d7-226ad88ad734",
          "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
          "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
          "presented": true,
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "subjectContactId": "5195ceb6-228e-439d-b3df-307197f1e7a7"
        }
      ],
      "ruleFired": "00010",
      "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
      "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
      "receiverId": "Francis.Albert.Bacon.19195313421",
      "receiverRole": "customer",
      "channel": "web",
      "excludeFromContactRule": false,
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "version": 1,
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PUT",
          "rel": "update",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "PATCH",
          "rel": "patch",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "type": "application/vnd.sas.decision.subject.contact",
          "responseType": "application/vnd.sas.decision.subject.contact"
        },
        {
          "method": "DELETE",
          "rel": "delete",
          "href": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7",
          "uri": "/subjectContacts/contacts/5195ceb6-228e-439d-b3df-307197f1e7a7"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/contacts",
          "uri": "/subjectContacts/contacts",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    

    The request conflicts with the current state.

    {
      "httpStatusCode": 409,
      "version": 2
    }
    

    Pre-condition failed.

    {
      "httpStatusCode": 412,
      "version": 2
    }
    

    Pre-condition required.

    {
      "httpStatusCode": 422,
      "version": 2
    }
    
    {
      "httpStatusCode": 428,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. subjectContact
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline
    409 Conflict The presentation has already been set and cannot be updated. Inline
    412 Precondition Failed The If-Match request header did not match the resource's entity tag, or the If-Unmodified-Since request header did not match the resource's last modified timestamp. Inline
    422 Unprocessable Entity The server understands the request but was unable to process the contained instructions. There are inconsistencies between members of the contact records as a result of the operation. An example is changing the respondedTimeStamp to a value earlier than the stored presentedTimeStamp. Inline
    428 Precondition Required The request header did not include a If-Match or 'If-Unmodified-Since' precondition. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 409

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 412

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 422

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 428

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Location string The URI of the contact.
    200 ETag string A tag that identifies this contact.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    412 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    422 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    428 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Delete a contact record

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/subjectContacts/contacts/{contactId} \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: application/vnd.sas.error+json'
    
    
    
    const headers = {
      'Accept':'application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/subjectContacts/contacts/{contactId}',
    {
      method: 'DELETE',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'application/vnd.sas.error+json'
    }
    
    r = requests.delete('https://example.com/subjectContacts/contacts/{contactId}', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/subjectContacts/contacts/{contactId}", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /contacts/{contactId}

    Deletes a contact record.

    Parameters
    Name In Type Required Description
    contactId path string true The identifier for a contact.

    Example responses

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    204 No Content The contact was deleted. None
    404 Not Found No resource exists at the requested path. Inline
    Response Schema

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    404 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Aggregations

    Contains the operations for the aggregations resource.

    Code samples

    # You can also use wget
    curl -X POST https://example.com/subjectContacts/aggregations \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/vnd.sas.decision.subject.contact.aggregation.specification+json' \
      -H 'Accept: application/vnd.sas.decision.subject.contact.aggregation.treatment+json'
    
    
    const inputBody = '{
      "subjectId": "string",
      "subjectLevel": "string",
      "beginAggregationTimeStamp": "2019-08-24T14:15:22Z",
      "endAggregationTimeStamp": "2019-08-24T14:15:22Z",
      "timeAggregationUnits": [
        "string"
      ],
      "contactChannels": [
        "string"
      ],
      "responseChannels": [
        "string"
      ]
    }';
    const headers = {
      'Content-Type':'application/vnd.sas.decision.subject.contact.aggregation.specification+json',
      'Accept':'application/vnd.sas.decision.subject.contact.aggregation.treatment+json'
    };
    
    fetch('https://example.com/subjectContacts/aggregations',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/vnd.sas.decision.subject.contact.aggregation.specification+json',
      'Accept': 'application/vnd.sas.decision.subject.contact.aggregation.treatment+json'
    }
    
    r = requests.post('https://example.com/subjectContacts/aggregations', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/vnd.sas.decision.subject.contact.aggregation.specification+json"},
            "Accept": []string{"application/vnd.sas.decision.subject.contact.aggregation.treatment+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/subjectContacts/aggregations", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /aggregations

    Returns information about the treatments. In anticipating queries like how many times a subject has been contacted in the last N time-units through X channels for different values of N, for multiple time units, for different channel values X, this endpoint allows the user to provide the parameters so that these queries can be answered at once by aggregating the results of multiple queries. This is done by combining different values of time, time unit, contact channel and response channel.

    The aggregation period is divided into widening sub-periods. The unit of division, such as hour, is provided in the aggregation specification. The first sub-period covers the endTimeStamp back to the start of the closest unit. The second sub-period adds one unit to the length. The last element of the array covers the entire aggregation period.

    If the excludeFromContactRule field of a contact record is true, the record is excluded from the aggregation.

    Body parameter

    {
      "subjectId": "string",
      "subjectLevel": "string",
      "beginAggregationTimeStamp": "2019-08-24T14:15:22Z",
      "endAggregationTimeStamp": "2019-08-24T14:15:22Z",
      "timeAggregationUnits": [
        "string"
      ],
      "contactChannels": [
        "string"
      ],
      "responseChannels": [
        "string"
      ]
    }
    
    Name In Type Required Description
    body body aggregationSpecification true The aggregation parameters.

    Example responses

    Subject contact treatment aggregation.

    {
      "subjectId": "string",
      "subjectLevel": "string",
      "beginTimeStamp": "2019-08-24T14:15:22Z",
      "endTimeStamp": "2019-08-24T14:15:22Z",
      "contactedTimeStampAggregation": [
        {
          "periodLength": "string",
          "periodUnit": "hour",
          "timeStampType": "contacted",
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "channels": [
            {
              "name": "string",
              "channelType": "contact",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ],
      "respondedTimeStampAggregation": [
        {
          "periodLength": "string",
          "periodUnit": "hour",
          "timeStampType": "contacted",
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "channels": [
            {
              "name": "string",
              "channelType": "contact",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ],
      "contactChannelAggregation": [
        {
          "name": "string",
          "channelType": "contact",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "periods": [
            {
              "periodLength": "string",
              "periodUnit": "hour",
              "timeStampType": "contacted",
              "beginTimeStamp": "2019-08-24T14:15:22Z",
              "endTimeStamp": "2019-08-24T14:15:22Z",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ],
      "responseChannelAggregation": [
        {
          "name": "string",
          "channelType": "contact",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "periods": [
            {
              "periodLength": "string",
              "periodUnit": "hour",
              "timeStampType": "contacted",
              "beginTimeStamp": "2019-08-24T14:15:22Z",
              "endTimeStamp": "2019-08-24T14:15:22Z",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ]
    }
    
    {
      "subjectId": "string",
      "subjectLevel": "string",
      "beginTimeStamp": "2019-08-24T14:15:22Z",
      "endTimeStamp": "2019-08-24T14:15:22Z",
      "contactedTimeStampAggregation": [
        {
          "periodLength": "string",
          "periodUnit": "hour",
          "timeStampType": "contacted",
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "channels": [
            {
              "name": "string",
              "channelType": "contact",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ],
      "respondedTimeStampAggregation": [
        {
          "periodLength": "string",
          "periodUnit": "hour",
          "timeStampType": "contacted",
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "channels": [
            {
              "name": "string",
              "channelType": "contact",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ],
      "contactChannelAggregation": [
        {
          "name": "string",
          "channelType": "contact",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "periods": [
            {
              "periodLength": "string",
              "periodUnit": "hour",
              "timeStampType": "contacted",
              "beginTimeStamp": "2019-08-24T14:15:22Z",
              "endTimeStamp": "2019-08-24T14:15:22Z",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ],
      "responseChannelAggregation": [
        {
          "name": "string",
          "channelType": "contact",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "periods": [
            {
              "periodLength": "string",
              "periodUnit": "hour",
              "timeStampType": "contacted",
              "beginTimeStamp": "2019-08-24T14:15:22Z",
              "endTimeStamp": "2019-08-24T14:15:22Z",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    

    Not found.

    {
      "httpStatusCode": 404,
      "version": 2
    }
    
    Status Meaning Description Schema
    200 OK The request succeeded. subjectContactTreatmentAggregate
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource exists at the requested path. Inline

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Traces

    Contains the operations for the traces resource.

    Get decision traces

    Code samples

    # You can also use wget
    curl -X GET https://example.com/subjectContacts/traces \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Accept: text/tab-separated-values' \
      -H 'Accept: application/vnd.sas.collection+json'
    
    
    
    const headers = {
      'Accept':'text/tab-separated-values',
      'Accept':'application/vnd.sas.collection+json'
    };
    
    fetch('https://example.com/subjectContacts/traces',
    {
      method: 'GET',
    
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Accept': 'text/tab-separated-values',
      'Accept': 'application/vnd.sas.collection+json'
    }
    
    r = requests.get('https://example.com/subjectContacts/traces', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Accept": []string{"text/tab-separated-values"},
            "Accept": []string{"application/vnd.sas.collection+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("GET", "https://example.com/subjectContacts/traces", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    GET /traces

    Returns a collection of decision traces. The traces can either be returned in either text/tab-separated-values or application/vnd.sas.collection+json format. The former would be the same format used for adding a decision trace. In the latter format, the traces without the actual trace texts are returned as items in a collection.

    There are two types of traces: one is at the decision step boundary and the other is at the variable assignment. Each GET only obtains the type of traces specified. The scope query parameter is used to specify the type of traces.

    The order of the columns for query parameter scope=step in tab-separated-values format are: traceid, seqno, tracetimestamp, objecturi, processornote, text. The version is 1 implicitly. Always use the column heading to help you locate a specific column. The order of the column and the number of columns are not fixed.

    The order of the columns for query parameter scope=assignment in tab-separated-values format are: traceid, seqno, tracetimestamp, objecturi, processornote, version, scope, and text. The current version is 2. However, always use the column heading to help you locate a specific column. The order of the column and the number of columns might change in a future version.

    Parameters
    Name In Type Required Description
    scope query string false The type of traces.
    start query integer false The starting index of the first item on a page. The index is 0-based. The default index is 0.
    limit query integer false 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 for the application/vnd.sas.collection+json format. For the tab-separated-values format the default is 1 because the trace text is included in the output. Trace text can be very long. There is much higher potential of exhausting the service's memory when retrieving a lot of trace texts at once.
    sortBy query string(sort-criteria) false The sorting criteria for the returned traces.
    filter query string(filter-criteria) false The filter criteria for the returned traces. The fields that can be used are traceId, traceTimeStamp and processorNote.
    Accept header string false Selects the desired representation
    Enumerated Values
    Parameter Value
    scope assignment
    scope step
    Accept text/tab-separated-values
    Accept application/vnd.sas.collection+json
    Accept application/json

    Example responses

    Trace collection as tab-separated values.

    Trace collection.

    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/subjectContacts/traces",
          "uri": "/subjectContacts/traces",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.trace"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=0&limit=10",
          "uri": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=0&limit=10",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.trace"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/",
          "uri": "/subjectContacts/",
          "type": "application/vnd.sas.api"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=10&limit=10",
          "uri": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=10&limit=10",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.trace"
        },
        {
          "method": "GET",
          "rel": "last",
          "href": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=210&limit=10",
          "uri": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=210&limit=10",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.trace"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/traces",
          "uri": "/subjectContacts/traces",
          "type": "text/tab-separated-values",
          "responseType": "multipart/mixed"
        }
      ],
      "name": "items",
      "start": 0,
      "count": 1,
      "items": [
        {
          "traceId": "3d4120b3-1fe7-4fce-b333-0ae1b93aa03c",
          "traceTimeStamp": "2020-08-07T18:02:23Z",
          "processorNote": "",
          "objectUri": "/decisions/flows/835b0890-bca3-42f1-8a50-9dcce2c4a377/revisions/6f5c045a-94a6-4f9b-9adc-cc1dde33558",
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "uri": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "type": "application/vnd.sas.decision.trace"
            },
            {
              "method": "GET",
              "rel": "completeWithTraceText",
              "href": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "uri": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "type": "text/tab-separated-values"
            },
            {
              "method": "POST",
              "rel": "update",
              "href": "/subjectContacts/traces",
              "uri": "/subjectContacts/traces",
              "type": "text/tab-separated-values",
              "responseType": "multipart/mixed"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "uri": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')"
            }
          ]
        }
      ]
    }
    
    {
      "links": [
        {
          "method": "GET",
          "rel": "collection",
          "href": "/subjectContacts/traces",
          "uri": "/subjectContacts/traces",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.trace"
        },
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=0&limit=10",
          "uri": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=0&limit=10",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.trace"
        },
        {
          "method": "GET",
          "rel": "up",
          "href": "/subjectContacts/",
          "uri": "/subjectContacts/",
          "type": "application/vnd.sas.api"
        },
        {
          "method": "GET",
          "rel": "next",
          "href": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=10&limit=10",
          "uri": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=10&limit=10",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.trace"
        },
        {
          "method": "GET",
          "rel": "last",
          "href": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=210&limit=10",
          "uri": "/subjectContacts/traces?filter=eq(sequenceNumber,1)&sortBy=traceTimeStamp:ascending,sequenceNumber:ascending:secondary&start=210&limit=10",
          "type": "application/vnd.sas.collection",
          "itemType": "application/vnd.sas.decision.trace"
        },
        {
          "method": "POST",
          "rel": "create",
          "href": "/subjectContacts/traces",
          "uri": "/subjectContacts/traces",
          "type": "text/tab-separated-values",
          "responseType": "multipart/mixed"
        }
      ],
      "name": "items",
      "start": 0,
      "count": 1,
      "items": [
        {
          "traceId": "3d4120b3-1fe7-4fce-b333-0ae1b93aa03c",
          "traceTimeStamp": "2020-08-07T18:02:23Z",
          "processorNote": "",
          "objectUri": "/decisions/flows/835b0890-bca3-42f1-8a50-9dcce2c4a377/revisions/6f5c045a-94a6-4f9b-9adc-cc1dde33558",
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "uri": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "type": "application/vnd.sas.decision.trace"
            },
            {
              "method": "GET",
              "rel": "completeWithTraceText",
              "href": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "uri": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "type": "text/tab-separated-values"
            },
            {
              "method": "POST",
              "rel": "update",
              "href": "/subjectContacts/traces",
              "uri": "/subjectContacts/traces",
              "type": "text/tab-separated-values",
              "responseType": "multipart/mixed"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')",
              "uri": "/subjectContacts/traces?filter=eq(traceId,'3d4120b3-1fe7-4fce-b333-0ae1b93aa03c')"
            }
          ]
        }
      ]
    }
    

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. traceCollection
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.
    Response Headers
    Status Header Type Format Description
    200 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.
    400 Sas-Service-Response-Flag boolean Indicates whether the response is coming from a SAS service.

    Append text or update traces from TSV

    Code samples

    # You can also use wget
    curl -X POST https://example.com/subjectContacts/traces \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: text/tab-separated-values' \
      -H 'Accept: multipart/mixed' \
      -H 'Accept: multipart/mixed, application/vnd.sas.error+json'
    
    
    const inputBody = 'string';
    const headers = {
      'Content-Type':'text/tab-separated-values',
      'Accept':'multipart/mixed',
      'Accept':'multipart/mixed, application/vnd.sas.error+json'
    };
    
    fetch('https://example.com/subjectContacts/traces',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'text/tab-separated-values',
      'Accept': 'multipart/mixed',
      'Accept': 'multipart/mixed, application/vnd.sas.error+json'
    }
    
    r = requests.post('https://example.com/subjectContacts/traces', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"text/tab-separated-values"},
            "Accept": []string{"multipart/mixed"},
            "Accept": []string{"multipart/mixed, application/vnd.sas.error+json"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/subjectContacts/traces", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /traces

    Appends text to the collection or updates the processorNote field of appended text. There are two types of traces: one is at the decision step boundary and other is at the variable assignment. The scope query parameter is used to specify the type of trace.

    This operation processes tab-separated-values (TSV) text with a case-insensitive header row that specifies the order of these required columns:

    A decision trace might require one or more rows of TSV text to convey. The value of seqNo, starting from 1, should be monotonically increasing from the first row to the last row. The rows are likely to be appended using multiple POST actions due to request body size restriction on the client formulating the POST action. Otherwise, one TSV row would have been used.

    The text column value must not include the TAB character.

    The text column contains whole or part of a decision trace.

    The value of the action column is either append or update.

    When the POST call is used to append text to the collection, all the above columns except the processorNote column must be given non-empty values.

    When the POST call is used to update text to the collection, the only column that can be changed is the processorNote column. The traceId column must have a value for the service to know which execution trace to update. Since a trace has one or more rows, the seqNo column is normally left empty so that all rows of the trace receive the same processorNote value. The other columns (traceTimeStamp, objectUri, text) should be left empty. If values are specified for these columns, they are ignored since they cannot be changed. Here is the order that the columns for updated:

    The output is a multipart/mixed response body. The boundary string of each part is identified in the Content-Type response header. There are three parts in this response.
    1. The first part is for the accepted TSV (header Content-ID: Accepted-TSV). Each trace line that was successfully processed is identified here.
    2. The second part is for the rejected TSV (header Content-ID:Rejected-TSV). Each trace that could not be processed is identified here. It is in CSV format with the following column order: traceId, and error message.
    3. The third part is for global issues (header Content-ID: Global-Issue). It is in TSV format with the following column order: line number, global error message that conveys the error that prevents any TSV processing. An example would be the lack of permissions.

    Body parameter

    Parameters
    Name In Type Required Description
    scope query string false The type of traces.
    Accept header string true In addition to multipart/mixed, also include application/vnd.sas.error+json in the Accept header. The two media types are separated by a comma. If there is a processing error, the error is reported in a JSON error object. In that case, without this arrangement, since the client is expecting only a response of multipart/mixed type, the server uses Http status of 406 to tell the client that it cannot match the expectation because a JSON error object cannot be mapped into a multipart/mixed response. By also accepting application/vnd.sas.error+json, this is avoided.
    body body string true The tap-separated-values that contains a header row.
    Enumerated Values
    Parameter Value
    scope assignment
    scope step
    Accept multipart/mixed, application/vnd.sas.error+json

    Example responses

    Trace updated using CSV text.

    Bad request.

    {
      "httpStatusCode": 400,
      "version": 2
    }
    
    Responses
    Status Meaning Description Schema
    200 OK The request succeeded. One or more rows of text are appended. Check the response for any error. Inline
    400 Bad Request The request was invalid. errorResponse
    Response Schema

    Status Code 200

    Name Type Required Restrictions Description
    » part1 object false none Accepted response
    »» contentType string false none none
    »» contentId string false none none
    »» body string false none none
    » part2 object false none Rejected response
    »» contentType string false none none
    »» contentId string false none none
    »» body string false none none
    » part3 object false none Global issues
    »» contentType string false none none
    »» contentId string false none none
    »» body string false none none

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Delete traces

    Code samples

    # You can also use wget
    curl -X DELETE https://example.com/subjectContacts/traces
      -H 'Authorization: Bearer <access-token-goes-here>' \
    
    
    
    fetch('https://example.com/subjectContacts/traces',
    {
      method: 'DELETE'
    
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    
    r = requests.delete('https://example.com/subjectContacts/traces')
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("DELETE", "https://example.com/subjectContacts/traces", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    DELETE /traces

    Deletes traces produced by decision execution.

    Parameters
    Name In Type Required Description
    scope query string false The type of traces to delete. For your convenience, if both decision step and variable assignment traces, exist, they can be deleted at the same time if the value of the scope query parameter is "all".
    start query integer false The starting index of the first item on a page. The index is 0-based. The default index is 0.
    limit query integer false The maximum number of items to work on. The actual number of returned items might be less if there are no more items in the collection. The default is 10.
    sortBy query string(sort-criteria) false The sorting criteria for the returned traces.
    filter query string(filter-criteria) false The filter criteria for identifying the trace. The fields that can be used are traceId, traceTimeStamp and processorNote.
    Enumerated Values
    Parameter Value
    scope all
    scope assignment
    scope step
    Responses
    Status Meaning Description Schema
    204 No Content The request is processed. None

    Process a trace and store a report file

    Code samples

    # You can also use wget
    curl -X POST https://example.com/subjectContacts/traces/{traceId}/process \
      -H 'Authorization: Bearer <access-token-goes-here>' \
      -H 'Content-Type: application/json' \
      -H 'Accept: application/vnd.sas.decision.trace.report'
    
    
    const inputBody = '{}';
    const headers = {
      'Content-Type':'application/json',
      'Accept':'application/vnd.sas.decision.trace.report'
    };
    
    fetch('https://example.com/subjectContacts/traces/{traceId}/process',
    {
      method: 'POST',
      body: inputBody,
      headers: headers
    })
    .then(function(res) {
        return res.json();
    }).then(function(body) {
        console.log(body);
    });
    
    import requests
    headers = {
      'Content-Type': 'application/json',
      'Accept': 'application/vnd.sas.decision.trace.report'
    }
    
    r = requests.post('https://example.com/subjectContacts/traces/{traceId}/process', headers = headers)
    
    print(r.json())
    
    package main
    
    import (
           "bytes"
           "net/http"
    )
    
    func main() {
    
        headers := map[string][]string{
            "Content-Type": []string{"application/json"},
            "Accept": []string{"application/vnd.sas.decision.trace.report"},
        }
    
        data := bytes.NewBuffer([]byte{jsonReq})
        req, err := http.NewRequest("POST", "https://example.com/subjectContacts/traces/{traceId}/process", data)
        req.Header = headers
    
        client := &http.Client{}
        resp, err := client.Do(req)
        // ...
    }
    

    POST /traces/{traceId}/process

    Processes a trace and stores the report in a file resource in the Files service. A text report is produced from the raw trace. The text report for a decision step boundary provides the following information:

    The text report for a variable assignment provides the following information:

    The report is stored as the content of a file resource in the Files service so that it can be obtained for viewing. The file content is given the name in the format of testName_trace.txt.

    The same raw trace can be processed as many times as needed. At the end of each successful processing, the previously allocated file object in the Files service is deleted. A new file resource is created. The Files service allows a file size up to 100MB by default. The report can be twice as large or more as the raw trace.

    Upon successful processing, this operation stores the Files service resource URI and the timestamp of the processing in the processorNote column of the raw trace record.

    Though a trace ID can be associated with both decision boundary and variable assignment traces, only one type of trace can be processed at one time.

    Body parameter

    {}
    
    Parameters
    Name In Type Required Description
    traceId path string true The id of the trace to process.
    scope query string false The type of trace.
    testName query string false The name of a decision test case that produces the trace. It is used in naming the report. The testName portion of the report name is encoded. Each character not safe to be used in a URL are encoded in the form of a percent character followed by a pair of hexadecimal characters.
    Enumerated Values
    Parameter Value
    scope assignment
    scope step

    Example responses

    Trace collection.

    The request was invalid.

    {}
    

    No resource identified by the traceId.

    {}
    
    Responses
    Status Meaning Description Schema
    201 Created The request succeeded. traceReport
    400 Bad Request The request was invalid. errorResponse
    404 Not Found No resource identified by the traceId. Inline
    Response Schema

    Status Code 400

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Status Code 404

    Error

    Name Type Required Restrictions Description
    » message string false none The message for the error.
    » id string false none The string ID for the error.
    » errorCode integer false none The numeric ID for the error.
    » httpStatusCode integer true none The HTTP status code for the error.
    » details [string] false none Messages that provide additional details about the cause of the error.
    » remediation string false none A message that describes how to resolve the error.
    » errors [#/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema] false none Any additional errors that occurred.
    »» Error #/paths/~1contacts/get/responses/400/content/application~1vnd.sas.error%2Bjson/schema false none The representation of an error.
    » links [link] false none The links that apply to the error.
    »» Link link false none A link to a related operation or resource.
    »»» method string false none The HTTP method for the link.
    »»» rel string true none The relationship of the link to the resource.
    »»» uri string false none The relative URI for the link.
    »»» href string false none The URL for the link.
    »»» title string false none The title for the link.
    »»» type string false none The media type or link type for the link.
    »»» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »»» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »»» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.
    » version integer true none The version number of the error representation. This representation is version 2.

    Schemas

    subjectContactCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "id": "string",
          "subjectId": "string",
          "subjectLevel": "string",
          "objectUri": "string",
          "objectRevisionId": "string",
          "objectType": "string",
          "objectVariables": [
            {
              "name": "string",
              "value": "string",
              "dataType": "boolean"
            }
          ],
          "treatmentsForConsideration": [
            {
              "treatmentId": "string",
              "treatmentRevisionId": "string",
              "treatmentGroupId": "string",
              "treatmentGroupRevisionId": "string",
              "objectNodeId": "string",
              "presented": true,
              "presentedTimeStamp": "2019-08-24T14:15:22Z",
              "respondedTimeStamp": "2019-08-24T14:15:22Z",
              "responseValue": "string",
              "responseType": "string",
              "responseChannel": "string",
              "subjectContactId": "string"
            }
          ],
          "ruleFired": "string",
          "pathTraversed": "string",
          "responseTrackingCode": "string",
          "receiverId": "string",
          "receiverRole": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "createdBy": "string",
          "channel": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "conclusionResponseValue": "string",
          "conclusionResponseType": "string",
          "excludeFromContactRule": true,
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    

    Contact and Response Collection

    Properties
    Name Type Required Restrictions Description
    Contact and Response Collection any false none A collection of the contact representation.

    allOf

    Name Type Required Restrictions Description
    anonymous object false none 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)
    » name string false none The name of the collection.
    » start integer(int64) false none The zero-based index of the first item in the collection.
    » limit integer false none The number of items that were requested for the collection.
    » count integer(int64) false none If populated indicates the number of items in the collection.
    » accept string false none A space-delimited list of media types from which an Accept header may be constructed.
    » links [link] false none The links that apply to the collection.
    » version integer false none The version number of the collection representation. This representation is version 2.

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [subjectContact] false none The actual results of a query.

    subjectContact

    {
      "id": "string",
      "subjectId": "string",
      "subjectLevel": "string",
      "objectUri": "string",
      "objectRevisionId": "string",
      "objectType": "string",
      "objectVariables": [
        {
          "name": "string",
          "value": "string",
          "dataType": "boolean"
        }
      ],
      "treatmentsForConsideration": [
        {
          "treatmentId": "string",
          "treatmentRevisionId": "string",
          "treatmentGroupId": "string",
          "treatmentGroupRevisionId": "string",
          "objectNodeId": "string",
          "presented": true,
          "presentedTimeStamp": "2019-08-24T14:15:22Z",
          "respondedTimeStamp": "2019-08-24T14:15:22Z",
          "responseValue": "string",
          "responseType": "string",
          "responseChannel": "string",
          "subjectContactId": "string"
        }
      ],
      "ruleFired": "string",
      "pathTraversed": "string",
      "responseTrackingCode": "string",
      "receiverId": "string",
      "receiverRole": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "channel": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "conclusionResponseValue": "string",
      "conclusionResponseType": "string",
      "excludeFromContactRule": true,
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Contact Record

    Properties
    Name Type Required Restrictions Description
    id string false none The system-assigned unique ID for this object.
    subjectId string true none A string that identifies the subject. This cannot be unique across subject levels.
    subjectLevel string true none A string that indicates the type of subject ID. Example values are household and customer. A subject is uniquely identified by the subjectLevel and subjectId tuple.
    objectUri string true none A URI of the resource that created this contact record.
    objectRevisionId string true none A string that identifies the revision of the resource that created this contact record.
    objectType string true none A string that identifies the type of resource that created this contact record.
    objectVariables [objectValue] false none A place for saving arbitrary values from the object.
    treatmentsForConsideration [treatmentForConsideration] false none All the treatments that a subject can consider.
    ruleFired string false none An encoded string that records which business rules evaluated to true.
    pathTraversed string false none An ordered string that shows the IDs of rules that were evaluated.
    responseTrackingCode string true none A string that a response uses. This is provided by the merchant's application. This is for grouping all the responses, one for each treatment, considered by the subject.
    receiverId string false none A string that identifies the person that receives this treatment. If the receiver is the subject, then receiverId equals subjectId. Otherwise, they are not equal.
    receiverRole string false none Identifies whether the receiver is a subject or an agent.
    creationTimeStamp string(date-time) false none Timestamp when this object is created. This field is a derived field. This also serves as the contact timestamp. If there are multiple treatments to consider, there is one contact and one contact timestamp. For example, all the treatment options are used to build a customized web page. All the treatment options are used to populate a menu used by a customer agent.
    createdBy string false none ID of the user who created this object. This field is a derived field.
    channel string false none The channel through which the contact is made. This can be different from the response channel. For example, a subject receives an email for a purchase offer and makes the purchase by telephone.
    modifiedTimeStamp string(date-time) false none Timestamp when this object is last modified. This field is a derived field. This tells when the response is recorded.
    modifiedBy string false none ID of the user who last modified this object. This field is a derived field.
    conclusionResponseValue string false none A summary response value derived from the responses to the individual treatments
    conclusionResponseType string false none An interpretation of conclusionResponseValue.
    excludeFromContactRule boolean false none When true, this contact record is ignored by a contact rule when determining an answer. The default is false.
    links [object] false none Zero or more link objects.
    » Link object false none A link to a related operation or resource.
    »» method string false none The HTTP method for the link.
    »» rel string true none The relationship of the link to the resource.
    »» uri string false none The relative URI for the link.
    »» href string false none The URL for the link.
    »» title string false none The title for the link.
    »» type string false none The media type or link type for the link.
    »» itemType string false none If this is a link to a container, itemType is the media type or link type for the items in the container.
    »» responseType string false none The media type or link type of the response body for a PUT, POST, or PATCH operation.
    »» responseItemType string false none The media type or link type of the items in the response body for a PUT, POST, or PATCH operation.

    objectValue

    {
      "name": "string",
      "value": "string",
      "dataType": "boolean"
    }
    
    

    Object Value

    Properties
    Name Type Required Restrictions Description
    name string true none Field name.
    value string false none Value.
    dataType string(enumeration) false none The data type of the value.
    Enumerated Values
    Property Value
    dataType boolean
    dataType date
    dataType datetime
    dataType decimal
    dataType integer
    dataType string

    treatmentForConsideration

    {
      "treatmentId": "string",
      "treatmentRevisionId": "string",
      "treatmentGroupId": "string",
      "treatmentGroupRevisionId": "string",
      "objectNodeId": "string",
      "presented": true,
      "presentedTimeStamp": "2019-08-24T14:15:22Z",
      "respondedTimeStamp": "2019-08-24T14:15:22Z",
      "responseValue": "string",
      "responseType": "string",
      "responseChannel": "string",
      "subjectContactId": "string"
    }
    
    

    A Treatment for a Subject to Consider

    Properties
    Name Type Required Restrictions Description
    treatmentId string true none A string that identifies a treatment.
    treatmentRevisionId string true none A string that identifies the revision of the treatment.
    treatmentGroupId string true none A string that identifies the group that a treatment belongs to.
    treatmentGroupRevisionId string true none A string that identifies the revision of the group that a treatment belongs to.
    objectNodeId string true none A string that identifies a node in the resource identified by the objectUri member in the subject contact record that selected this treatment.
    presented boolean false none Records whether the treatment has been presented. A customer agent handling the customer might decide not to present a treatment based on the nature and mood of the communication.
    presentedTimeStamp string(date-time) false none Timestamp when the treatment is presented to the subject.
    respondedTimeStamp string(date-time) false none Timestamp when the response is actually received.
    responseValue string false none The response.
    responseType string false none An interpretation derived from responseValue.
    responseChannel string false none The channel through which the response is made. This might be different from the contact channel.
    subjectContactId string false none The system-assigned ID for the subject contact that included this treatment.

    aggregationSpecification

    {
      "subjectId": "string",
      "subjectLevel": "string",
      "beginAggregationTimeStamp": "2019-08-24T14:15:22Z",
      "endAggregationTimeStamp": "2019-08-24T14:15:22Z",
      "timeAggregationUnits": [
        "string"
      ],
      "contactChannels": [
        "string"
      ],
      "responseChannels": [
        "string"
      ]
    }
    
    

    Aggregation Specification

    Properties
    Name Type Required Restrictions Description
    subjectId string true none ID of the subject for whom the aggregation is done.
    subjectLevel string true none Indicates the type of subject ID.
    beginAggregationTimeStamp string(date-time) false none Begin aggregation from this time. If omitted, the aggregation starts from seven days prior to the time at which the request is serviced.
    endAggregationTimeStamp string(date-time) false none Stop aggregation before this time. If omitted, the aggregation stops right before the time at which the request is serviced.
    timeAggregationUnits [string] false none The units to use for time-based aggregation. If omitted, the time unit is day. The other acceptable time unit is hour. Aggregation can be done in both time units.
    contactChannels [string] false none The contact channels to aggregate. All channels found are used in secondary aggregation if this is omitted. Through a contact channel, a subject is contacted.
    responseChannels [string] false none The response channels to aggregate. All channels found are used in secondary aggregation if this is omitted. Through a response channel, the subject responds to a treatment.

    subjectContactTreatmentAggregate

    {
      "subjectId": "string",
      "subjectLevel": "string",
      "beginTimeStamp": "2019-08-24T14:15:22Z",
      "endTimeStamp": "2019-08-24T14:15:22Z",
      "contactedTimeStampAggregation": [
        {
          "periodLength": "string",
          "periodUnit": "hour",
          "timeStampType": "contacted",
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "channels": [
            {
              "name": "string",
              "channelType": "contact",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ],
      "respondedTimeStampAggregation": [
        {
          "periodLength": "string",
          "periodUnit": "hour",
          "timeStampType": "contacted",
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "channels": [
            {
              "name": "string",
              "channelType": "contact",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ],
      "contactChannelAggregation": [
        {
          "name": "string",
          "channelType": "contact",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "periods": [
            {
              "periodLength": "string",
              "periodUnit": "hour",
              "timeStampType": "contacted",
              "beginTimeStamp": "2019-08-24T14:15:22Z",
              "endTimeStamp": "2019-08-24T14:15:22Z",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ],
      "responseChannelAggregation": [
        {
          "name": "string",
          "channelType": "contact",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ],
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "periods": [
            {
              "periodLength": "string",
              "periodUnit": "hour",
              "timeStampType": "contacted",
              "beginTimeStamp": "2019-08-24T14:15:22Z",
              "endTimeStamp": "2019-08-24T14:15:22Z",
              "contactedTreatments": [
                "string"
              ],
              "presentedTreatments": [
                "string"
              ],
              "respondedTreatments": [
                "string"
              ]
            }
          ]
        }
      ]
    }
    
    

    Subject Contact Aggregate

    Properties
    Name Type Required Restrictions Description
    subjectId string true none ID of the subject for whom the aggregation is done.
    subjectLevel string true none Indicates the type of subject ID.
    beginTimeStamp string(date-time) true none Timestamp that marks the beginning of the aggregation.
    endTimeStamp string(date-time) true none Timestamp that marks the end of the aggregation.
    contactedTimeStampAggregation [timeStampPrimaryAggregate] false none Aggregation of the subject's treatments in the contacted timestamp dimension
    respondedTimeStampAggregation [timeStampPrimaryAggregate] false none Aggregation of the subject's treatments in the responded timestamp dimension
    contactChannelAggregation [channelPrimaryAggregate] false none Aggregation of the subject's treatments in the contact channel dimension
    responseChannelAggregation [channelPrimaryAggregate] false none Aggregation of the subject's treatments in the response channel dimension

    timeStampAggregate

    {
      "periodLength": "string",
      "periodUnit": "hour",
      "timeStampType": "contacted",
      "beginTimeStamp": "2019-08-24T14:15:22Z",
      "endTimeStamp": "2019-08-24T14:15:22Z",
      "contactedTreatments": [
        "string"
      ],
      "presentedTreatments": [
        "string"
      ],
      "respondedTreatments": [
        "string"
      ]
    }
    
    

    Timestamp Aggregation

    Properties
    Name Type Required Restrictions Description
    periodLength string true none The length of this period in terms of the period unit.
    periodUnit string(enumeration) true none The unit of the period.
    timeStampType string(enumeration) true none The type of timestamp to use for the aggregation
    beginTimeStamp string(date-time) true none Timestamp that marks the beginning of this period.
    endTimeStamp string(date-time) true none Timestamp that marks the end of this period.
    contactedTreatments [string] false none array of IDs of treatments IDs corresponding to the contacts.
    presentedTreatments [string] false none array of IDs of treatment presented.
    respondedTreatments [string] false none array of IDs of treatments that have received response.
    Enumerated Values
    Property Value
    periodUnit hour
    periodUnit day
    timeStampType contacted
    timeStampType responded

    channelAggregate

    {
      "name": "string",
      "channelType": "contact",
      "contactedTreatments": [
        "string"
      ],
      "presentedTreatments": [
        "string"
      ],
      "respondedTreatments": [
        "string"
      ]
    }
    
    

    Channel Aggregation

    Properties
    Name Type Required Restrictions Description
    name string true none Channel code
    channelType string(enumeration) true none Type of channel
    contactedTreatments [string] false none array of IDs of treatments IDs corresponding to the contacts.
    presentedTreatments [string] false none array of IDs of treatment presented.
    respondedTreatments [string] false none array of IDs of treatments that have received response.
    Enumerated Values
    Property Value
    channelType contact
    channelType response

    timeStampSecondaryAggregate

    {
      "periodLength": "string",
      "periodUnit": "hour",
      "timeStampType": "contacted",
      "beginTimeStamp": "2019-08-24T14:15:22Z",
      "endTimeStamp": "2019-08-24T14:15:22Z",
      "contactedTreatments": [
        "string"
      ],
      "presentedTreatments": [
        "string"
      ],
      "respondedTreatments": [
        "string"
      ]
    }
    
    

    Timestamp Secondary Aggregation

    Properties
    Name Type Required Restrictions Description
    Timestamp Secondary Aggregation timeStampAggregate false none Aggregate treatments in the timestamp dimension for a particular channel for which the primary aggregation was done. The secondary aggregation is for a specific length of time

    channelSecondaryAggregate

    {
      "name": "string",
      "channelType": "contact",
      "contactedTreatments": [
        "string"
      ],
      "presentedTreatments": [
        "string"
      ],
      "respondedTreatments": [
        "string"
      ]
    }
    
    

    Channel Secondary Aggregation

    Properties
    Name Type Required Restrictions Description
    Channel Secondary Aggregation channelAggregate false none Aggregate treatments in a channel dimension for a given time period constraint. That time period is the primary aggregation. This identifies the treatments that go through this channel in the time period.

    timeStampPrimaryAggregate

    {
      "periodLength": "string",
      "periodUnit": "hour",
      "timeStampType": "contacted",
      "beginTimeStamp": "2019-08-24T14:15:22Z",
      "endTimeStamp": "2019-08-24T14:15:22Z",
      "contactedTreatments": [
        "string"
      ],
      "presentedTreatments": [
        "string"
      ],
      "respondedTreatments": [
        "string"
      ],
      "channels": [
        {
          "name": "string",
          "channelType": "contact",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ]
        }
      ]
    }
    
    

    Contact Timestamp Primary Aggregation

    Properties
    Name Type Required Restrictions Description
    Contact Timestamp Primary Aggregation any false none Aggregate treatments in the timestamp dimension.

    allOf

    Name Type Required Restrictions Description
    anonymous timeStampAggregate false none Aggregation of metadata regarding the timestamp

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » channels [channelSecondaryAggregate] false none The secondary aggregation in the channel dimension for this time period. This identifies the treatments by the channels that they go through. This is a drill down from a time period to the channels.

    channelPrimaryAggregate

    {
      "name": "string",
      "channelType": "contact",
      "contactedTreatments": [
        "string"
      ],
      "presentedTreatments": [
        "string"
      ],
      "respondedTreatments": [
        "string"
      ],
      "beginTimeStamp": "2019-08-24T14:15:22Z",
      "endTimeStamp": "2019-08-24T14:15:22Z",
      "periods": [
        {
          "periodLength": "string",
          "periodUnit": "hour",
          "timeStampType": "contacted",
          "beginTimeStamp": "2019-08-24T14:15:22Z",
          "endTimeStamp": "2019-08-24T14:15:22Z",
          "contactedTreatments": [
            "string"
          ],
          "presentedTreatments": [
            "string"
          ],
          "respondedTreatments": [
            "string"
          ]
        }
      ]
    }
    
    

    Channel Aggregation

    Properties

    allOf

    Name Type Required Restrictions Description
    anonymous channelAggregate false none Aggregation for channels

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » beginTimeStamp string(date-time) false none The timestamp that marks the beginning of the aggregation period.
    » endTimeStamp string(date-time) false none The timestamp that marks the end of the aggregation period.
    » periods [timeStampSecondaryAggregate] false none This identifies the time periods when treatments go through this channel. This is a drill down from a channel to time periods.

    traceCollection

    {
      "name": "string",
      "start": 0,
      "limit": 0,
      "count": 0,
      "accept": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ],
      "version": 0,
      "items": [
        {
          "traceId": "string",
          "traceTimeStamp": "string",
          "objectUri": "string",
          "processorNote": "string",
          "creationTimeStamp": "2019-08-24T14:15:22Z",
          "createdBy": "string",
          "modifiedTimeStamp": "2019-08-24T14:15:22Z",
          "modifiedBy": "string",
          "links": [
            {
              "method": "string",
              "rel": "string",
              "uri": "string",
              "href": "string",
              "title": "string",
              "type": "string",
              "itemType": "string",
              "responseType": "string",
              "responseItemType": "string"
            }
          ]
        }
      ]
    }
    
    

    Decision Trace Collection

    Properties
    Name Type Required Restrictions Description
    Decision Trace Collection any false none A collection of the trace representations.

    allOf

    Name Type Required Restrictions Description
    anonymous subjectContactCollection false none 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)

    and

    Name Type Required Restrictions Description
    anonymous object false none none
    » items [trace] false none The actual results of a query.

    trace

    {
      "traceId": "string",
      "traceTimeStamp": "string",
      "objectUri": "string",
      "processorNote": "string",
      "creationTimeStamp": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "modifiedTimeStamp": "2019-08-24T14:15:22Z",
      "modifiedBy": "string",
      "links": [
        {
          "method": "string",
          "rel": "string",
          "uri": "string",
          "href": "string",
          "title": "string",
          "type": "string",
          "itemType": "string",
          "responseType": "string",
          "responseItemType": "string"
        }
      ]
    }
    
    

    Decision Trace

    Properties
    Name Type Required Restrictions Description
    traceId string true none The ID of the raw trace. This is provided by the user of the API when a raw trace is submitted to the service for recording.
    traceTimeStamp string true none The timestamp associated with the raw trace.
    objectUri string true none The URI of the decision associated with the raw trace.
    processorNote string true none The history of the processing of the raw trace and other information. The note is composed in YAML format.
    creationTimeStamp string(date-time) false none Timestamp when the trace is recorded. This field is a derived field.
    createdBy string false none ID of the user who recorded this trace. This field is a derived field.
    modifiedTimeStamp string(date-time) false none Timestamp when this trace's processorNote field is last modified. This field is a derived field.
    modifiedBy string false none ID of the user who last modified this trace. This field is a derived field.
    links [link] false none Zero or more link objects.

    traceReport

    {
      "traceId": "string",
      "traceTimeStamp": "string",
      "processedTimeStamp": "string",
      "reportUri": "string",
      "objectUri": "string"
    }
    
    

    Decision Trace Report

    Properties
    Name Type Required Restrictions Description
    traceId string true none The ID of the raw trace. This is provided by the user of the API when a raw trace is submitted to the service for recording.
    traceTimeStamp string true none The timestamp associated with the raw trace.
    processedTimeStamp string false none The timestamp associated with the processing of the raw trace.
    reportUri string true none The Files Service URI of the file resource in which the report is stored.
    objectUri string true none The URI of the decision associated with the raw trace.

    Examples

    Github Examples

    Detailed examples on how to use this API can be found on Github.

    Media Type Samples

    Subject Contact Media Types
    application/vnd.sas.decision.subject.contact

    Provides a contact record.

    The schema is located at subjectContact.

    application/vnd.sas.decision.subject.contact+json

    Here is an example of the JSON representation of this media type.

    
     {
      "version": 1,
      "id": "11dc6b1d-1795-468e-9ea3-253d20a0d919",
      "creationTimeStamp": "2018-05-13T15:02:40.719Z",
      "createdBy": "bob",
      "modifiedTimeStamp": "2018-06-04T15:02:40.719Z",
      "modifiedBy": "sally",
      "objectUri": "/decisions/flows/5c5bc46a-cea0-4102-a88c-71cf1506e2c5",
      "objectRevisionId": "afb62877-64cb-4ae6-bf0c-4e2783a38d3a",
      "objectType": "decision",
      "objectVariables": [
           {"name": "ov1", "value": "A", "dataType": "string"},
           {"name": "ov2", "value": "B", "dataType": "string"}
      ],
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "ruleFired": "00010",
      "pathTraversed": "/9e4e324b-de68-4035-b511-84cd558d5408/2541ab6e-3e7d-4ba0-8f04-7fc13a8e9794/509c4d2d-dc2c-4cb3-a094-5628e1ec879d",
      "responseTrackingCode": "GreatCustomer.07f16e7a-db89-400a-91d9-8b6868f07b7b",
      "receiverId": "Francis.Albert.Bacon.19195313421",
      "receiverRole": "customer",
      "conclusionResponseValue": "",
      "conclusionResponseType": "crt_x",
      "treatmentsForConsideration": [
        {
          "id": "65ecc1c2-094d-49f0-871b-ad86bd502425",
          "treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83",
          "treatmentRevisionId": "7aa86c12-55cf-4e99-8060-5b516314dc44",
          "treatmentGroupId": "bc912f15-96a0-4991-ba2a-9f12491cefc0",
          "treatmentGroupRevisionId": "4f8461be-9311-4dec-b90d-648e339a7f25",
          "objectNodeId": "6bf8f1b3-9910-40ad-8146-6affd4f49a1f",
          "presented": "true",
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z"
        },
        {
          "id": "e3603e98-45d4-45ff-8c31-773f77dbfd11",
          "treatmentId": "826c9635-809a-44cf-a982-63e374846087",
          "treatmentRevisionId": "d14e393d-c21c-4654-8095-376909edace5",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "cf328b78-81b3-465e-b86b-2eb71876a66a",
          "presented": "true",
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "responseValue": "accepted",
          "responseType": "rt_1",
          "responseChannel": "web",
          "respondedTimeStamp": "2018-05-13T18:11:10.687Z"
        },
        {
          "id": "47bb6ad1-2ff8-4b46-98ce-1b7c685683b7",
          "treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81",
          "treatmentRevisionId": "f14c3aa2-98a4-4a42-8b29-c99ad3cc02a8",
          "treatmentGroupId": "1ba80181-7996-4ed5-8d58-66be8d2204e3",
          "treatmentGroupRevisionId": "f38725dc-cb53-4f09-b69c-661a7d675dac",
          "objectNodeId": "f7d361a9-d488-47f6-a579-e4cf28fb7324",
          "presented": "true",
          "presentedTimeStamp": "2018-05-13T15:02:40.719Z",
          "responseValue": "declined",
          "responseType": "rt_2",
          "responseChannel": "web",
          "respondedTimeStamp": "2018-05-13T18:10:45.209Z"
        }
      ],
      "excludeFromContactRule": false,
      "channel": "web",
      "links": [
        {
          "method": "GET",
          "rel": "self",
          "href": "/subjectContacts/contacts/11dc6b1d-1795-468e-9ea3-253d20a0d919",
          "uri": "/subjectContacts/contacts/11dc6b1d-1795-468e-9ea3-253d20a0d919",
          "type": "application/vnd.sas.decision.subject.contact"
        }
      ]
    }
    
    application/vnd.sas.decision.subject.contact.aggregation.specification

    Provides the parameters of an aggregation request.

    The schema is located at aggregationSpecification.

    application/vnd.sas.decision.subject.contact.aggregation.specification+json

    Here is an example of the JSON representation of this media type.

    
     {
      "subjectId": "Francis.Albert.Bacon.19195313421",
      "subjectLevel": "household",
      "timeAggregationUnits" : [
          "hour",
          "day"
      ],
      "beginAggregationTimeStamp" : "2018-05-13T14:47:40.719Z",
      "endTimeStamp": "2018-05-20T23:59:59Z",
      "contactChannels": [
          "web",
          "phone"
      ],
      "responseChannels": [
          "web",
          "phone"
      ],
    }
    
    application/vnd.sas.decision.subject.contact.aggregation.treatment

    Provides the aggregation of a subject's treatments for a time period.

    The schema is located at subjectContactTreatmentAggregate.

    application/vnd.sas.decision.subject.contact.aggregation.treatment+json

    Here is an example of the JSON representation of this media type.

    
     {
          "subjectId": "Francis.Albert.Bacon.19195313421", 
          "subjectLevel": "household", 
          "beginTimeStamp": "2018-05-13T14:47:40.719Z", 
          "endTimeStamp": "2018-05-13T18:47:40.719Z",
          "contactChannelAggregation": [
              {
                  "name": "web", 
                  "channelType": "contact", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                  "beginTimeStamp": "2018-05-13T14:47:40.719Z"
              }, 
              {
                  "name": "phone", 
                  "channelType": "contact", 
                  "contactedTreatments": [
                      {"treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83", "count": 1},
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1},
                      {"treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81", "count": 1},
                      {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                  ], 
                  "presentedTreatments": [
                      {"treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83", "count": 1},
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1},
                      {"treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81", "count": 1}
                  ], 
                  "periods": [
                      {
                          "periodUnit": "hour", 
                          "periodLength": 1, 
                          "contactedTreatments": [
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "timeStampType": "contacted", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T18:00:00.000Z"
                      }, 
                      {
                          "periodUnit": "hour", 
                          "periodLength": 2, 
                          "contactedTreatments": [
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "timeStampType": "contacted", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T17:00:00.000Z"
                      }, 
                      {
                          "periodUnit": "hour", 
                          "periodLength": 3, 
                          "contactedTreatments": [
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "timeStampType": "contacted", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T16:00:00.000Z"
                      }, 
                      {
                          "periodUnit": "hour", 
                          "periodLength": 4, 
                          "contactedTreatments": [
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "timeStampType": "contacted", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T15:00:00.000Z"
                      }, 
                      {
                          "periodUnit": "hour", 
                          "periodLength": 5, 
                          "contactedTreatments": [
                              {"treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83", "count": 1},
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1},
                              {"treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81", "count": 1},
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "presentedTreatments": [
                              {"treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83", "count": 1},
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1},
                              {"treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81", "count": 1}
                          ], 
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "timeStampType": "contacted", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T14:47:40.719Z"
                      }
                  ], 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                  "beginTimeStamp": "2018-05-13T14:47:40.719Z"
              }
          ], 
          "responseChannelAggregation": [
              {
                  "name": "phone", 
                  "channelType": "response", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                  "beginTimeStamp": "2018-05-13T14:47:40.719Z"
              },
              {
                  "name": "web", 
                  "channelType": "response", 
                  "respondedTreatments": [
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                  ], 
                  "periods": [
                      {
                          "periodUnit": "hour", 
                          "periodLength": 1, 
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "timeStampType": "responded", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T18:00:00.000Z"
                      }, 
                      {
                          "periodUnit": "hour", 
                          "periodLength": 2, 
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "timeStampType": "responded", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T17:00:00.000Z"
                      }, 
                      {
                          "periodUnit": "hour", 
                          "periodLength": 3, 
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "timeStampType": "responded", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T16:00:00.000Z"
                      }, 
                      {
                          "periodUnit": "hour", 
                          "periodLength": 4, 
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "timeStampType": "responded", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T15:00:00.000Z"
                      }, 
                      {
                          "periodUnit": "hour", 
                          "periodLength": 5, 
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "timeStampType": "responded", 
                          "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                          "beginTimeStamp": "2018-05-13T14:47:40.719Z"
                      }
                  ], 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z", 
                  "beginTimeStamp": "2018-05-13T14:47:40.719Z"
              } 
          ], 
          "contactedTimeStampAggregation": [
              {
                  "periodUnit": "hour", 
                  "periodLength": 1,
                  "contactedTreatments": [
                      {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                  ], 
                  "channels": [
                      {
                          "channelType": "contact", 
                          "contactedTreatments": [
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "name": "phone"
                      }
                  ], 
                  "timeStampType": "contacted", 
                  "beginTimeStamp": "2018-05-13T18:00:00.000Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }, 
              {
                  "periodUnit": "hour", 
                  "periodLength": 2
                  "contactedTreatments": [
                      {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                  ], 
                  "channels": [
                      {
                          "channelType": "contact", 
                          "contactedTreatments": [
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "name": "phone"
                      }
                  ], 
                  "timeStampType": "contacted", 
                  "beginTimeStamp": "2018-05-13T17:00:00.000Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }, 
              {
                  "periodUnit": "hour", 
                  "periodLength": 3,
                  "contactedTreatments": [
                      {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                  ], 
                  "channels": [
                      {
                          "channelType": "contact", 
                          "contactedTreatments": [
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "name": "phone"
                      }
                  ], 
                  "timeStampType": "contacted", 
                  "beginTimeStamp": "2018-05-13T16:00:00.000Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }, 
              {
                  "periodUnit": "hour", 
                  "periodLength": 4,
                  "contactedTreatments": [
                      {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                  ], 
                  "channels": [
                      {
                          "channelType": "contact", 
                          "contactedTreatments": [
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "name": "phone"
                      }
                  ], 
                  "timeStampType": "contacted", 
                  "beginTimeStamp": "2018-05-13T15:00:00.000Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }, 
              {
                  "periodUnit": "hour", 
                  "periodLength": 5,
                  "contactedTreatments": [
                      {"treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83", "count": 1},
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1},
                      {"treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81", "count": 1},
                      {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                  ], 
                  "presentedTreatments": [
                      {"treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83", "count": 1},
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1},
                      {"treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81", "count": 1}
                  ], 
                  "channels": [
                      {
                          "name": "phone"
                          "channelType": "contact", 
                          "contactedTreatments": [
                              {"treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83", "count": 1},
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1},
                              {"treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81", "count": 1},
                              {"treatmentId": "29ed1a67-e3be-412c-ae2f-567edd38e086", "count": 1}
                          ], 
                          "presentedTreatments": [
                              {"treatmentId": "4f3f14cf-69ed-4d59-9ea2-ecfb525cfa83", "count": 1},
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1},
                              {"treatmentId": "2826de5a-d0d6-4bd1-8a80-08c12ba2ad81", "count": 1}
                          ], 
                      }
                  ], 
                  "timeStampType": "contacted", 
                  "beginTimeStamp": "2018-05-13T14:47:40.719Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }
          ], 
          "respondedTimeStampAggregation": [
              {
                  "periodUnit": "hour", 
                  "periodLength": 1,
                  "respondedTreatments": [
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                  ], 
                  "channels": [
                      {
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "channelType": "response", 
                          "name": "web"
                      }
                  ], 
                  "timeStampType": "responded", 
                  "beginTimeStamp": "2018-05-13T18:00:00.000Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }, 
              {
                  "periodUnit": "hour", 
                  "periodLength": 2,
                  "respondedTreatments": [
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                  ], 
                  "channels": [
                      {
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "channelType": "response", 
                          "name": "web"
                      }
                  ], 
                  "timeStampType": "responded", 
                  "beginTimeStamp": "2018-05-13T17:00:00.000Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }, 
              {
                  "periodUnit": "hour", 
                  "periodLength": 3,
                  "respondedTreatments": [
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                  ], 
                  "channels": [
                      {
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "channelType": "response", 
                          "name": "web"
                      }
                  ], 
                  "timeStampType": "responded", 
                  "beginTimeStamp": "2018-05-13T16:00:00.000Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }, 
              {
                  "periodUnit": "hour", 
                  "periodLength": 4,
                  "respondedTreatments": [
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                  ], 
                  "channels": [
                      {
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "channelType": "response", 
                          "name": "web"
                      }
                  ], 
                  "timeStampType": "responded", 
                  "beginTimeStamp": "2018-05-13T15:00:00.000Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }, 
              {
                  "periodUnit": "hour", 
                  "periodLength": 5,
                  "respondedTreatments": [
                      {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                  ], 
                  "channels": [
                      {
                          "respondedTreatments": [
                              {"treatmentId": "826c9635-809a-44cf-a982-63e374846087", "count": 1}
                          ], 
                          "channelType": "response", 
                          "name": "web"
                      }
                  ], 
                  "timeStampType": "responded", 
                  "beginTimeStamp": "2018-05-13T14:47:40.719Z", 
                  "endTimeStamp": "2018-05-13T18:47:40.719Z"
              }
          ]
      }
    
    
    application/vnd.sas.decision.trace

    Conveys the essential information of a raw trace

    The schema is located at trace.

    application/vnd.sas.decision.trace+json

    Here is an example of the JSON representation of this media type.

    
     {
          "version": 2,
          "traceId": "954931B7-2425-CB45-90D2-756189E18F72",
          "traceTimeStamp": "2020-07-27T09:49:20.000Z",
          "scope": "step",
          "processorNote": "",
          "objectUri": "/decisions/flows/aaf496e0-3ea4-4b96-969c-768e581660c5/revisions/cd9d34ed-c358-4a8d-89d5-5f494923de3d",
          "links": [
            {
              "method": "GET",
              "rel": "self",
              "href": "/subjectContacts/traces?filter=eq(traceId,'954931B7-2425-CB45-90D2-756189E18F72')",
              "uri": "/subjectContacts/traces?filter=eq(traceId,'954931B7-2425-CB45-90D2-756189E18F72')",
              "type": "application/vnd.sas.decision.trace"
            },
            {
              "method": "GET",
              "rel": "completeWithTraceText",
              "href": "/subjectContacts/traces?filter=eq(traceId,'954931B7-2425-CB45-90D2-756189E18F72')",
              "uri": "/subjectContacts/traces?filter=eq(traceId,'954931B7-2425-CB45-90D2-756189E18F72')",
              "type": "text/tab-separated-values"
            },
            {
              "method": "POST",
              "rel": "update",
              "href": "/subjectContacts/traces",
              "uri": "/subjectContacts/traces",
              "type": "text/tab-separated-values",
              "responseType": "multipart/mixed"
            },
            {
              "method": "DELETE",
              "rel": "delete",
              "href": "/subjectContacts/traces?filter=eq(traceId,'954931B7-2425-CB45-90D2-756189E18F72')",
              "uri": "/subjectContacts/traces?filter=eq(traceId,'954931B7-2425-CB45-90D2-756189E18F72')"
            }
          ]
    }
    
    application/vnd.sas.decision.trace.report

    Conveys the result of processing a raw trace.

    The schema is located at traceReport.

    application/vnd.sas.decision.trace.report+json

    Here is an example of the JSON representation of this media type.

    
     {
      "version": 1,
      "traceId":"6d707a51-62b3-40a4-4973-b2d9f12d20fe",
      "traceTimeStamp":"2020-09-08T14:29:30.000Z",
      "processedTimeStamp":"2020-09-08T14:35:27.000Z",
      "reportUri":"/files/files/b8bc8dd8-6747-4194-8b64-6f574f0f1f42",
      "objectUri":"/decisions/flows/501fa196-6d6e-4515-ac8f-3840ba576b56/revisions/37f0e7af-d27d-453c-b3a0-546f29c26a94",
      "links":[
         {
           "method":"POST",
           "rel":"self",
           "href":"/subjectContacts/traces/6d707a51-62b3-40a4-4973-b2d9f12d20fe/process",
           "uri":"/subjectContacts/traces/6d707a51-62b3-40a4-4973-b2d9f12d20fe/process",
           "type":"application/vnd.sas.decision.trace.report"
         },
         {
           "method":"GET",
           "rel":"reportContent",
           "href":"/files/files/b8bc8dd8-6747-4194-8b64-6f574f0f1f42/content",
           "uri":"/files/files/b8bc8dd8-6747-4194-8b64-6f574f0f1f42/content"
         },
         {
           "method":"GET",
           "rel":"rawContent",
           "href":"/subjectContacts/traces?filter=eq(traceId,'6d707a51-62b3-40a4-4973-b2d9f12d20fe')",
           "uri":"/subjectContacts/traces?filter=eq(traceId,'6d707a51-62b3-40a4-4973-b2d9f12d20fe')",
           "type":"text/tab-separated-values"
         }
      ]
    }
    
    Externally Defined Media Types
    application/vnd.sas.collection

    A paginated, filterable, sortable collection of resource representations. For this API, this is a collection of application/vnd.sas.decision.subject.contact representations.

    See application/vnd.sas.collection.

    application/vnd.sas.summary

    Used to represent a summary of a resource.

    See application/vnd.sas.summary.

    application/vnd.sas.error

    Used to represent an error response.

    See application/vnd.sas.error.

    Resource Relationships

    The following diagram shows the relationships between the resources in this API. Subject Contacts API resource relationship diagram

    Root

    Path: /

    The root of the API. This resource contains links to the top-level resources in the API. The response uses the application/vnd.sas.api media type.

    The GET / response includes the following links.

    Relation Method Description
    contacts GET Returns the first page of the collection of contact records.
    Response type: application/vnd.sas.collection.
    Response item type: application/vnd.sas.summary.
    Response item type: application/vnd.sas.decision.subject.contact.
    createContact POST Creates a new contact record or update an existing record keyed by responseTrackingCode.
    Request type: application/vnd.sas.decision.subject.contact.
    Response type: application/vnd.sas.decision.subject.contact.
    aggregations POST Returns aggregated information.
    Request type: application/vnd.sas.decision.subject.contact.aggregation.specification.
    Response type: application/vnd.sas.decision.subject.contact.aggregation.treatment.
    Contacts

    Path: /contacts

    Provides a collection of contact records.

    Default page size is 10.

    The contacts collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.decision.subject.contact resources. (These types apply to the response for the self, collection, prev, next, first and last links below.)

    The GET /contacts response includes the following links.

    Relation Method Description
    create POST Creates a new contact record.
    Request type: application/vnd.sas.decision.subject.contact.
    Response type: application/vnd.sas.decision.subject.contact.
    self GET Returns the current page of the collection.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Return the parent resource, which is the root of this API.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    The default sort order for the contacts collection is by descending creationTimeStamp.

    Contact

    Path: /contacts/{contactId}

    Provides a contact record.

    The GET /contacts/{contactId} response includes the following links.

    Relation Method Description
    self GET Returns the full representation of the record.
    Response type: application/vnd.sas.decision.subject.contact
    delete DELETE Deletes the contact record.
    update PUT Update the mutable fields of the entire record.
    Request type: application/vnd.sas.decision.subject.contact
    Response type: application/vnd.sas.decision.subject.contact
    patch PATCH Patch this record with new presentation or response information.
    Request type: application/vnd.sas.decision.subject.contact
    Response type: application/vnd.sas.decision.subject.contact
    up GET Returns the parent resource.
    Aggregation

    Path: /aggregations

    Provides aggregation of the treatments.

    The POST /aggregations response includes the following links.

    Relation Method Description
    self GET Returns this aggregation.
    Response type: application/vnd.sas.decision.subject.contact.aggregation.treatment
    up GET Returns the parent resource.
    Traces

    Path: /traces

    Provides a collection of decision traces.

    Default page size is 10.

    The traces collection representation is application/vnd.sas.collection. The collection items are application/vnd.sas.decision.trace resources. (These types apply to the response for the self, collection, prev, next, first and last links below.)

    The GET /traces response includes the following links.

    Relation Method Description
    create POST Records a new decision trace.
    Request type: [text/tab-separated-values]
    Response type: [multipart/mixed]
    self GET Returns the current page of the collection.
    collection GET Returns the first page of the collection, without the sorting or filtering criteria.
    prev GET Returns the previous page of resources from the collection.
    This link is omitted if the current view is on the first page.
    next GET Returns the next page of resources from the collection.
    This link is omitted if the current view is on the last page or if the last page of the collection cannot be determined.
    first GET Returns the first page of resources from the collection.
    This link is omitted if the current view is on the first page.
    last GET Returns the last page of resources from the collection.
    This link is omitted if the current view is on the last page.
    up GET Return the parent resource, which is the root of this API.
    Sorting and Filtering

    These collections can be sorted and filtered using the ?sortBy= and ?filter= query parameters.

    Trace Report

    Path: /traces/{traceId}/process

    Provides the details of processing a trace.

    The POST /traces/{traceId}/process response includes the following links.

    Relation Method Description
    self POST Returns this resource.
    Response type: application/vnd.sas.decision.trace.report
    reportContent GET Returns the report generated by processing the trace.
    rawContent GET Returns the decision trace used to generate the report.