policy

Agent Server REST API

policy

POST http://dev.whitehat.co.kr/agent/v1/policy

API that can search the whole list of policy or with a given search condition

Headers

Name
Type
Description

X-AGENT-API-TOKEN

string

required token for searching the Agent API

Request Body

Name
Type
Description

policyName

string

policy name to search

expectedPayer

string

the expected payer of policy to search

limit

string

number of items to get at a time (default: 10)

page

string

Current page number (default: 1)

{
  "code": 200,
  "message": "Success",
  "data": {
    "totalCount": 1,
    "list": [
      {
        "policyDistRate": [
          {
            "key": "bp",
            "value": "50"
          },
          {
            "key": "officials",
            "value": "50"
          }
        ],
        "_id": "0",
        "policyName": "POLICY_ADD_ISSUER",
        "policyNameHash": "7274D6B4E3DFCD9F967BFF80FADF9826794140F33A42E673550B42F65455AA05",
        "policyProcAsset": "0.0000 OCR",
        "expectedPayer": "issuer"
      }
    ]
  }
}

Request Parameter example (JSON)

{
  "query": {
    "policyName": "POLICY_ADD_ISSUER"
  },
  "limit": 10,
  "page": 1
}

transpolicy

POST http://dev.whitehat.co.kr/agent/v1/policy/transpolicy

API that can search the whole list of transpolicy or with a given search condition

Headers

Name
Type
Description

X-AGENT-API-TOKEN

string

required token for searching the Agent API (issuing console)

Request Body

Name
Type
Description

policyName

string

policy name to search

expectedPlayer

string

the expected payer of policy to search

limit

string

Number of items to get at a time (default: 10)

page

string

Current page number (default: 1)

{
  "code": 200,
  "message": "Success",
  "data": {
    "totalCount": 1,
    "list": [
      {
        "policyDistRate": [
          {
            "key": "bp",
            "value": "50"
          },
          {
            "key": "officials",
            "value": "50"
          }
        ],
        "_id": "0",
        "policyName": "POLICY_ADD_ISSUER",
        "policyNameHash": "7274D6B4E3DFCD9F967BFF80FADF9826794140F33A42E673550B42F65455AA05",
        "policyProcAsset": "0.0000 OCR",
        "expectedPayer": "issuer"
      }
    ]
  }
}

Request Parameter example (JSON)

{
  "query": {
    "policyName": "POLICY_ADD_ISSUER"
  },
  "limit": 10,
  "page": 1
}

Last updated