Authentication & JSON Schemas

Authentication

All requests to the Saner Server must include a valid API key in the Authorization header.

POST https://saner.secpod.com/AncorWebService/perform?accountid=<account_name> 

Authorization: <Your API Key>
Content-Type: application/json

To obtain your API key, contact the SecPod Support team at [email protected].

Key Points

  • The Authorization header is required on every request — there are no public/unauthenticated endpoints.
  • The accountid query parameter is required for operations scoped to a specific account (Device, Group, Organization, Configuration, Remediation, Reports).
  • API keys should be stored securely and never committed to source control.

Request JSON Schema

The full JSON Schema for all perform requests:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "required": ["request"],
  "properties": {
    "request": {
      "type": "object",
      "required": ["method", "parameters"],
      "properties": {
        "method": {
          "type": "string",
          "description": "The RPC method name to invoke (e.g. 'adduser', 'getDevice')"
        },
        "parameters": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "parameterset": {
                "type": "object",
                "properties": {
                  "parameter": { "type": "string" },
                  "value":     { "type": "string" }
                }
              }
            }
          }
        }
      }
    }
  }
}

Response JSON Schema

The common response schema for write/action operations:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "required": ["response"],
  "properties": {
    "response": {
      "type": "object",
      "required": ["method", "results"],
      "properties": {
        "method": {
          "type": "string",
          "description": "Echoes back the method name from the request"
        },
        "results": {
          "type": "object",
          "properties": {
            "result": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "key":    { "type": "string", "description": "Identifier of the affected record" },
                  "status": { "type": "string", "description": "SUCCESS or FAIL" },
                  "reason": { "type": "string", "description": "Reason for failure, empty on success" }
                }
              }
            }
          }
        }
      }
    }
  }
}

Response Field Reference

FieldTypeDescription
response.methodstringThe method name echoed from the request
response.results.result[].keystringIdentifier of the record (e.g., username)
response.results.result[].statusstringSUCCESS or FAIL
response.results.result[].reasonstringError message if FAIL, otherwise empty string