{
  "swagger": "2.0",
  "info": {
    "description": "API Gateway User Management Service allows you to manage Users, Groups and Access profiles in the API Gateway. Any user with the 'Manage user administration' functional privilege can manage the Users, Groups and Access profiles in API Gateway. By default, the users who are part of API-Gateway-Administrators groups will have this privilege.\n\nAPI Gateway allows you to manage the password restrictions settings. For security purposes, API Gateway places length and character restrictions on passwords for administrator and non-administrator users. API Gateway contains a default set of password requirements. However, you can change these using the API Gateway Administration Service. Refer the REST resource '/configurations/passwordRestrictions' in the API Gateway Administration Service. \n\nAPI Gateway allows you to manage the password expiration settings. For security purposes, API Gateway allows administrators to set password expiration requirements on passwords for administrator and non-administrator users. API Gateway contains a default set of password expiry settings. However, you can change these with the API Gateway Administration service. Refer the REST resource '/configurations/passwordExpiry' in the API Gateway Administration Service. \n\nAPI Gateway allows you to manage the account locking settings. For security purposes, it is important to lock a user account when the user fails to provide the correct password after a specified number of failed login attempts to API Gateway. A locked user account remains locked for a specific period of time, after which the account gets unlocked. API Gateway allows administrators to configure these account locking settings for administrator and non-administrator users. Using API Gateway Administration Service, you can set the values for number of attempts by a user before locking the account and also the duration of the lock interval. Refer the REST resource '/configurations/accountLockSettings' in the API Gateway Administration Service.\n\nAPI Gateway allows you to view the locked user accounts and also allows to manually unlock locked user accounts before the automatic unlocking period. This can be achieved using the REST resource '/is/lockedAccounts' in the API Gateway User Management Service. \n\nAPI Gateway allows you to configure LDAP directories. If your server uses Lightweight Directory Access Protocol (LDAP) for user and group information, you can configure API Gateway to obtain user and group information from the external LDAP directory. You can configure API Gateway to use more than one LDAP directory at a time, allowing API Gateway to work with different LDAP directories for users in different locations or different organizations. You can manage the LDAP directories and LDAP configurations using the API Gateway Administration service. Refer the REST resource '/configurations/ldapConfig' in the API Gateway Administration Service.\n\nGlobal Team Assignments : When Teamwork feature is enabled, one can automate the team assignment for assets, by defining Global Team Assignment rules. Rules are defined by specifying one or more asset based conditions, and by configuring the rule output if the conditions are met. Management of such rules are exposed through an REST API. Refer the REST resource '/rule' in the API Gateway Administration Service.",
    "version": "11.0",
    "title": "API Gateway User Management Service"
  },
  "host": "localhost:5555",
  "basePath": "/rest/apigateway",
  "schemes": [
    "http"
  ],
  "consumes": [
    "application/json"
  ],
  "produces": [
    "application/json"
  ],
  "paths": {
    "/accessProfiles": {
      "get": {
        "description": "The method retrieves list of all teams in API Gateway.",
        "operationId": "getAccessProfiles",
        "produces": [
          "application/json"
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "This status code indicates that the list of teams is successfully retrieved.",
            "examples": {
              "application/json": "{\r\n    \"accessProfiles\": [\r\n        {\r\n            \"id\": \"Administrators\",\r\n            \"name\": \"Administrators\",\r\n            \"description\": \"Groups associated to this team are allowed to perform all the administration related tasks. \",\r\n            \"systemDefined\": true,\r\n            \"privilege\": \"1111111111111111111111111111111111111111111111111111111111111111\",\r\n            \"groupIds\": [\r\n                \"Administrators\",\r\n                \"API-Gateway-Administrators\"\r\n            ]\r\n        },\r\n        {\r\n            \"id\": \"API-Gateway-Providers\",\r\n            \"name\": \"API-Gateway-Providers\",\r\n            \"description\": \"Groups associated to this team are allowed to access an asset based on the functional privileges assigned to this team.\",\r\n            \"systemDefined\": true,\r\n            \"privilege\": \"111100101101100000001\",\r\n            \"groupIds\": [\r\n                \"API-Gateway-Providers\"\r\n            ]\r\n        },\r\n        {\r\n            \"id\": \"8b6f2e10-1d82-4813-b927-4c1cf4a4d029\",\r\n            \"name\": \"TestProfile\",\r\n            \"description\": \"Test\",\r\n            \"systemDefined\": false,\r\n            \"privilege\": \"101110000001100000110101\",\r\n            \"groupIds\": [\r\n                \"be9147a8-6e53-4472-b1bd-16337a84d314\"\r\n            ],\r\n            \"teamAdmin\": {\r\n                \"userIds\": [\r\n                    \"user1\"\r\n                ],\r\n                \"groupIds\": [\r\n                    \"group1\"\r\n                ]\r\n            }\r\n\r\n        }\r\n    ]\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/AccessProfile"
            }
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "post": {
        "description": "The method creates a team in API Gateway. The API request body must contain the payload for the team. Each bit infers the applicability of the functional privilege permission. Value 1 implies permission granted for that functional privilege. Value  0 implies denied permission. Function Privileges and its positions from left most bit to the right most bit. 1.Manage APIs2.Activate / Deactivate APIs3.Manage applications4.Manage aliases5.Manage global policies6.Activate / Deactivate global policies7.Manage policy templates8.Manage threat protection configurations9.Manage packages and plans10.Activate / Deactivate packages11.Publish to API Portal12.Import assets13.Export assets14.View administration configurations15.Manage general administration configurations16.Manage security configurations17.Manage destination configurations18.Manage system settings19.Manage user administration20.Manage purge and restore runtime events21.Execute service result cache APIs22.Manage Promotion23.Publish API to Service Registry24.Manage Service Registries",
        "operationId": "createAccessProfile",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "This parameter describes the request payload of a accessProfile that is to be created in API Gateway.",
            "required": true,
            "schema": {
              "$ref": "#/definitions/AccessProfile"
            },
            "x-examples": {
              "application/json": "{\r\n    \"name\": \"TestProfile\",\r\n    \"description\": \"Test\",\r\n    \"privilege\": \"1011100000011000001101010001\",\r\n    \"groupIds\": [\r\n        \"be9147a8-6e53-4472-b1bd-16337a84d314\"\r\n    ],\r\n    \"teamAdmin\": {\r\n        \"userIds\": [\r\n            \"Administrator\"\r\n        ],\r\n        \"groupIds\": [\r\n            \"Administrators\"\r\n        ]\r\n    }\r\n}"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "This status code indicates that the team has been successfully created in API Gateway, and the newly created team is available in the response body.",
            "examples": {
              "application/json": "{\r\n    \"id\": \"8b6f2e10-1d82-4813-b927-4c1cf4a4d029\",\r\n    \"name\": \"TestProfile\",\r\n    \"description\": \"Test\",\r\n    \"privilege\": \"101110000001100000110101\",\r\n    \"groupIds\": [\r\n        \"be9147a8-6e53-4472-b1bd-16337a84d314\"\r\n    ],\r\n    \"teamAdmin\": {\r\n        \"userIds\": [\r\n    \"Administrator\"\r\n        ],\r\n        \"groupIds\": [\r\n    \"Administrators\"\r\n        ]\r\n    }\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/AccessProfile"
            }
          },
          "400": {
            "description": "This status code indicates that a team with the given name already exists in API Gateway or the request body is not correct."
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    },
    "/accessProfiles/{accessProfileId}": {
      "get": {
        "description": "The method retrieves the details of a team in API Gateway.",
        "operationId": "getAccessProfile",
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "name": "accessProfileId",
            "in": "path",
            "description": "The path parameter specifies the id of a team whose details are to be retrieved.",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "This status code indicates that the details of the team is successfully retrieved.",
            "examples": {
              "application/json": "{\r\n    \"id\": \"8b6f2e10-1d82-4813-b927-4c1cf4a4d029\",\r\n    \"name\": \"TestProfile\",\r\n    \"description\": \"Test\",\r\n    \"systemDefined\": false,\r\n    \"privilege\": \"1011100000011000001\",\r\n    \"groupIds\": [\r\n        \"be9147a8-6e53-4472-b1bd-16337a84d314\"\r\n    ],\r\n    \"teamAdmin\": {\r\n        \"userIds\": [\r\n            \"Administrator\"\r\n        ],\r\n        \"groupIds\": [\r\n            \"Administrators\"\r\n        ]\r\n    }\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/AccessProfile"
            }
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          },
          "404": {
            "description": "This status code indicates that a team with the given id could not be found in API Gateway.",
            "examples": {
              "application/json": "{\r\n    \"errorDetails\": \" AccessProfile with id: 15fbeeb2-745c-4988-b7b6-61f359ecbfc8 does not exist.\"\r\n}"
            }
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "put": {
        "description": "The method updates the details of a specified team in API Gateway. The API request body must contain the payload for the updated accessProfile.",
        "operationId": "updateAccessProfile",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "This parameter describes the request payload of a accessProfile that is to be updated in API Gateway.",
            "required": true,
            "schema": {
              "$ref": "#/definitions/AccessProfile"
            },
            "x-examples": {
              "application/json": "{\r\n    \"name\": \"TestProfile\",\r\n    \"description\": \"Test\",\r\n    \"privilege\": \"101110000001100000110101\",\r\n    \"groupIds\": [\r\n        \"be9147a8-6e53-4472-b1bd-16337a84d314\"\r\n    ],\r\n    \"teamAdmin\": {\r\n        \"userIds\": [\r\n            \"Administrator\"\r\n        ],\r\n        \"groupIds\": [\r\n            \"Administrators\"\r\n        ]\r\n    }\r\n}"
            }
          },
          {
            "name": "accessProfileId",
            "in": "path",
            "description": "The path parameter specifies the id of a team whose detail is to be updated in API Gateway.",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "This status code indicates that the team has been successfully updated in API Gateway, and the updated team is available in the response body.",
            "examples": {
              "application/json": "{\r\n    \"id\": \"8b6f2e10-1d82-4813-b927-4c1cf4a4d029\",\r\n    \"name\": \"TestProfile\",\r\n    \"description\": \"Test\",\r\n    \"systemDefined\": false,\r\n    \"privilege\": \"1011100000011000001\",\r\n    \"groupIds\": [\r\n        \"be9147a8-6e53-4472-b1bd-16337a84d314\"\r\n    ],\r\n    \"teamAdmin\": {\r\n        \"userIds\": [\r\n            \"Administrator\"\r\n        ],\r\n        \"groupIds\": [\r\n            \"Administrators\"\r\n        ]\r\n    }\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/AccessProfile"
            }
          },
          "400": {
            "description": "This status code indicates that the request body is invalid."
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "delete": {
        "description": "The method deletes a team from API Gateway.",
        "operationId": "deleteAccessProfile",
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "name": "accessProfileId",
            "in": "path",
            "description": "This parameter specifies the ID of a team that is to be deleted in API Gateway.",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "204": {
            "description": "This status code indicates that the specified team has been successfully deleted from API Gateway."
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          },
          "404": {
            "description": "This status code indicates that team with the given id could not be found in API Gateway.",
            "examples": {
              "application/json": "{\r\n    \"errorDetails\": \" AccessProfile with id: 732c4526-db9a-4ef9-9782-edda1a6aa9bc does not exist.\"\r\n}"
            }
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    },
    "/authenticate": {
      "post": {
        "description": "This HTTP request authenticates an User in API Gateway.",
        "operationId": "authorize",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "This parameter describes the request payload of a user that is to be created in API Gateway.",
            "required": true,
            "schema": {
              "$ref": "#/definitions/User"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "This status code indicates that the user was successfully authenticated.",
            "schema": {
              "$ref": "#/definitions/User"
            }
          },
          "400": {
            "description": "This status code indicates that the request payload is not correct or User is already exists"
          },
          "401": {
            "description": "This status code indicates that authorization has been refused for this HTTP request. This is possibly because, the user has not specified the required credentials (username and password), or has specified invalid credentials."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    },
    "/groups": {
      "get": {
        "description": "The method retrieves list of all groups in API Gateway.",
        "operationId": "getGroups",
        "produces": [
          "application/json"
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "This status code indicates that the list of groups is successfully retrieved.",
            "examples": {
              "application/json": "{\r\n    \"groups\": [\r\n        {\r\n            \"id\": \"Administrators\",\r\n            \"name\": \"Administrators\",\r\n            \"description\": \"Users added to this group can perform similar local administrative tasks.\",\r\n            \"type\": \"local\",\r\n            \"systemDefined\": true,\r\n            \"userIds\": [\r\n                \"Administrator\"\r\n            ]\r\n        },\r\n        {\r\n            \"id\": \"API-Gateway-Administrators\",\r\n            \"name\": \"API-Gateway-Administrators\",\r\n            \"description\": \"Users added to this group can perform similar API Gateway Administrative tasks.\",\r\n            \"type\": \"local\",\r\n            \"systemDefined\": true,\r\n            \"userIds\": [\r\n                \"Administrator\"\r\n            ]\r\n        },\r\n        {\r\n            \"id\": \"API-Gateway-Providers\",\r\n            \"name\": \"API-Gateway-Providers\",\r\n            \"description\": \"Users added to this group can perform similar API Gateway Providers tasks.\",\r\n            \"type\": \"local\",\r\n            \"systemDefined\": true,\r\n            \"userIds\": []\r\n        },\r\n        {\r\n            \"id\": \"be9147a8-6e53-4472-b1bd-16337a84d314\",\r\n            \"name\": \"TestGrp\",\r\n            \"description\": \"\",\r\n            \"type\": \"local\",\r\n            \"systemDefined\": false,\r\n            \"userIds\": [\r\n                \"69aa914e-fbfc-4c74-87f1-2d48f589e115\"\r\n            ]\r\n        }\r\n    ]\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/Group"
            }
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "post": {
        "description": "The method creates a group in API Gateway. The API request body must contain the payload for the group.",
        "operationId": "createGroup",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "This parameter describes the request payload of a group that is to be created in API Gateway.",
            "required": true,
            "schema": {
              "$ref": "#/definitions/Group"
            },
            "x-examples": {
              "application/json": "{\r\n\t \"name\": \"TestGrp\",\r\n\t\"description\": \"Group has all QA Members\",\r\n\t\"userIds\": [\r\n\t\t\"69aa914e-fbfc-4c74-87f1-2d48f589e115\"\r\n\t]\r\n}"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "This status code indicates that the group has been successfully created in API Gateway, and the newly created group is available in the response body.",
            "examples": {
              "application/json": "{\r\n\t\"id\": \"be9147a8-6e53-4472-b1bd-16337a84d314\",\r\n\t\"name\": \"TestGrp\",\r\n\t\"description\": \"Group has all QA Members\",\r\n\t\"type\": \"local\",\r\n\t\"userIds\": [\r\n\t\t\"69aa914e-fbfc-4c74-87f1-2d48f589e115\"\r\n\t]\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/Group"
            }
          },
          "400": {
            "description": "This status code indicates that a group with the given name already exists in API Gateway or the request body is not correct."
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    },
    "/groups/{groupId}": {
      "get": {
        "description": "The method retrieves the details of a group in API Gateway.",
        "operationId": "getGroup",
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "name": "groupId",
            "in": "path",
            "description": "The path parameter specifies the id of a group whose details are to be retrieved.",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "This status code indicates that the details of the group is successfully retrieved.",
            "examples": {
              "application/json": "{\r\n    \"groups\": [\r\n        {\r\n            \"id\": \"be9147a8-6e53-4472-b1bd-16337a84d314\",\r\n            \"name\": \"TestGrp\",\r\n            \"description\": \"Group has all QA Members\",\r\n            \"type\": \"local\",\r\n            \"userIds\": [\r\n                \"69aa914e-fbfc-4c74-87f1-2d48f589e115\"\r\n            ]\r\n        }\r\n    ]\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/Group"
            }
          },
          "401": {
            "description": "This status code indicates that either group didn't provide right credentials or user doesn't have required privileges to access this API."
          },
          "404": {
            "description": "This status code indicates that a group with the given id could not be found in API Gateway.",
            "examples": {
              "application/json": "{\r\n    \"errorDetails\": \" Group with id: 15fbeeb2-745c-4988-b7b6-61f359ecbfc8 does not exist.\"\r\n}"
            }
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "put": {
        "description": "The method updates the details of a specified group in API Gateway. The API request body must contain the payload for the updated group.",
        "operationId": "updateGroup",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "This parameter describes the request payload of a group that is to be updated in API Gateway.",
            "required": true,
            "schema": {
              "$ref": "#/definitions/Group"
            },
            "x-examples": {
              "application/json": "{\r\n\t\"id\": \"be9147a8-6e53-4472-b1bd-16337a84d314\",\r\n\t\"name\": \"TestGrp\",\r\n\t\"description\": \"Group has all QA Members\",\r\n\t\"userIds\": [\r\n\t\t\"69aa914e-fbfc-4c74-87f1-2d48f589e115\"\r\n\t]\r\n}"
            }
          },
          {
            "name": "groupId",
            "in": "path",
            "description": "The path parameter specifies the id of a group whose detail is to be updated in API Gateway.",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "This status code indicates that the group has been successfully updated in API Gateway, and the updated group is available in the response body.",
            "examples": {
              "application/json": "{\r\n\t\"id\": \"be9147a8-6e53-4472-b1bd-16337a84d314\",\r\n\t\"name\": \"TestGrp\",\r\n\t\"description\": \"Group has all QA Members\",\r\n\t\"type\": \"local\",\r\n\t\"userIds\": [\r\n\t\t\"69aa914e-fbfc-4c74-87f1-2d48f589e115\"\r\n\t]\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/Group"
            }
          },
          "400": {
            "description": "This status code indicates that the request body is invalid."
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "delete": {
        "description": "The method deletes a group from API Gateway.",
        "operationId": "deleteGroup",
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "name": "groupId",
            "in": "path",
            "description": "The path parameter specifies the id of a group that is to be deleted from API Gateway.",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "204": {
            "description": "This status code indicates that the specified group has been successfully deleted from API Gateway."
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          },
          "404": {
            "description": "This status code indicates that group with the given id could not be found in API Gateway.",
            "examples": {
              "application/json": "{\r\n    \"errorDetails\": \" Group with id: 732c4526-db9a-4ef9-9782-edda1a6aa9bc does not exist.\"\r\n}"
            }
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    },
    "/installedLanguages": {
      "get": {
        "description": "The method retrieves list of installed language packs in API Gateway.",
        "operationId": "getInstalledLanguages",
        "produces": [
          "application/json"
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "This status code indicates that the list of installed language packs is successfully retrieved.",
            "examples": {
              "application/json": "{\r\n    \"installedLanguages\": [\r\n        \"ja\"\r\n    ]\r\n}"
            },
            "schema": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    },
    "/is/lockedAccounts": {
      "get": {
        "description": "Retrieves the locked accounts in API Gateway",
        "operationId": "getLockedAccounts",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "",
            "examples": {
              "application/json": "{\r\n\t\"lockedAccounts\":[\"a\",\"b\"]\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/LockedAccounts"
            }
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "post": {
        "description": "Unlock user account(s) locked by API Gateway",
        "operationId": "unLockUserAccounts",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "$ref": "#/definitions/UnlockAccountsRequest"
            },
            "x-examples": {
              "application/json": "{\r\n\t\"unLockAccounts\": { \r\n\t\t\"userName\": [\"c\"]\r\n\t}\r\n}"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "",
            "examples": {
              "application/json": "{\r\n\t\"lockedAccounts\":[\"a\",\"b\"]\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/LockedAccounts"
            }
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    },
    "/users": {
      "get": {
        "description": "The method retrieves list of all users in API Gateway.",
        "operationId": "getUsers",
        "produces": [
          "application/json"
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "This status code indicates that the list of users is successfully retrieved.",
            "examples": {
              "application/json": "{\r\n    \"users\": [\r\n        {\r\n            \"id\": \"Administrator\",\r\n            \"loginId\": \"Administrator\",\r\n            \"firstName\": \"Administrator\",\r\n            \"password\": \"********************************\",\r\n            \"type\": \"local\",\r\n            \"allowDigestAuth\": false,\r\n            \"active\": true,\r\n            \"systemDefined\": true,\r\n            \"language\": \"en\",\r\n             \"emailAddresses\": []\r\n        },\r\n        {\r\n            \"id\": \"15fbeeb2-745c-4988-b7b6-61f359ecbfc8\",\r\n            \"loginId\": \"testUser\",\r\n            \"firstName\": \"User\",\r\n            \"lastName\": \"Test\",\r\n            \"password\": \"********************************\",\r\n            \"type\": \"local\",\r\n            \"allowDigestAuth\": false,\r\n            \"active\": true,\r\n            \"systemDefined\": false,\r\n            \"language\": \"ja\",\r\n            \"emailAddresses\": [\r\n                \"noreply@softwareag.com\"\r\n            ]\r\n        }\r\n    ]\r\n}\r\n"
            },
            "schema": {
              "$ref": "#/definitions/User"
            }
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "post": {
        "description": "The method creates an user in API Gateway. The API request body must contain the payload for the user.",
        "operationId": "createUser",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "This parameter describes the request payload of a user that is to be created in API Gateway.",
            "required": true,
            "schema": {
              "$ref": "#/definitions/User"
            },
            "x-examples": {
              "application/json": "{\r\n            \"loginId\": \"testUser\",\r\n            \"firstName\": \"User\",\r\n            \"lastName\": \"Test\",\r\n            \"password\": \"test\",\r\n            \"type\": \"local\",\r\n            \"allowDigestAuth\": false,\r\n            \"language\": \"en\",\r\n            \"emailAddresses\": [\r\n                \"noreply@softwareag.com\"\r\n            ]\r\n        }"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "This status code indicates that the user has been successfully created in API Gateway, and the newly created user is available in the response body.",
            "examples": {
              "application/json": "{\r\n            \"id\": \"15fbeeb2-745c-4988-b7b6-61f359ecbfc8\",\r\n            \"loginId\": \"testUser\",\r\n            \"firstName\": \"User\",\r\n            \"lastName\": \"Test\",\r\n            \"password\": \"********************************\",\r\n            \"type\": \"local\",\r\n            \"allowDigestAuth\": false,\r\n            \"active\": true,\r\n            \"language\": \"en\",\r\n            \"emailAddresses\": [\r\n                \"noreply@softwareag.com\"\r\n            ]\r\n        }"
            },
            "schema": {
              "$ref": "#/definitions/User"
            }
          },
          "400": {
            "description": "This status code indicates that an user with the given loginId already exists in API Gateway or the request body is not correct."
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    },
    "/users/authenticate": {
      "post": {
        "description": "This HTTP request authenticates an User in API Gateway.",
        "operationId": "authorizeUser",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "This parameter describes the request payload of a user that is to be created in API Gateway.",
            "required": true,
            "schema": {
              "$ref": "#/definitions/User"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "This status code indicates that the user was successfully authenticated.",
            "schema": {
              "$ref": "#/definitions/User"
            }
          },
          "400": {
            "description": "This status code indicates that the request payload is not correct or User is already exists"
          },
          "401": {
            "description": "This status code indicates that authorization has been refused for this HTTP request. This is possibly because, the user has not specified the required credentials (username and password), or has specified invalid credentials."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    },
    "/users/{userId}": {
      "get": {
        "description": "The method retrieves the details of an user in API Gateway.",
        "operationId": "getUser",
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "name": "userId",
            "in": "path",
            "description": "The path parameter specifies the id of an user whose details are to be retrieved.",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "This status code indicates that the details of the user is successfully retrieved.",
            "examples": {
              "application/json": "{\r\n    \"users\": [\r\n        {\r\n            \"id\": \"15fbeeb2-745c-4988-b7b6-61f359ecbfc8\",\r\n            \"loginId\": \"testUser\",\r\n            \"firstName\": \"User\",\r\n            \"lastName\": \"Test\",\r\n            \"password\": \"********************************\",\r\n            \"type\": \"local\",\r\n            \"allowDigestAuth\": false,\r\n            \"active\": true,\r\n            \"emailAddresses\": [\r\n                \"noreply@softwareag.com\"\r\n            ]\r\n        }\r\n    ]\r\n}"
            },
            "schema": {
              "$ref": "#/definitions/User"
            }
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          },
          "404": {
            "description": "This status code indicates that an user with the given id could not be found in API Gateway.",
            "examples": {
              "application/json": "{\r\n    \"errorDetails\": \" User with id: 15fbeeb2-745c-4988-b7b6-61f359ecbfc8 does not exist.\"\r\n}"
            }
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "put": {
        "description": "The method updates the details of a specified user in API Gateway. The API request body must contain the payload for the updated user.",
        "operationId": "updateUser",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "This parameter describes the request payload of a user that is to be updated in API Gateway.",
            "required": true,
            "schema": {
              "$ref": "#/definitions/User"
            },
            "x-examples": {
              "application/json": "{\r\n            \"loginId\": \"testUser\",\r\n            \"firstName\": \"User\",\r\n            \"lastName\": \"Test\",\r\n            \"password\": \"test\",\r\n            \"type\": \"local\",\r\n            \"allowDigestAuth\": false,\r\n            \"emailAddresses\": [\r\n                \"noreply@softwareag.com\"\r\n            ]\r\n        }"
            }
          },
          {
            "name": "userId",
            "in": "path",
            "description": "The path parameter specifies the id of an user whose detail is to be updated in API Gateway.",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "This status code indicates that the user has been successfully updated in API Gateway, and the updated user is available in the response body.",
            "examples": {
              "application/json": "{\r\n  \"id\": \"15fbeeb2-745c-4988-b7b6-61f359ecbfc8\",\r\n            \"loginId\": \"testUser\",\r\n            \"firstName\": \"User\",\r\n            \"lastName\": \"Test\",\r\n            \"password\": \"test\",\r\n            \"type\": \"local\",\r\n            \"allowDigestAuth\": false,\r\n            \"emailAddresses\": [\r\n                \"noreply@softwareag.com\"\r\n            ]\r\n        }"
            },
            "schema": {
              "$ref": "#/definitions/User"
            }
          },
          "400": {
            "description": "This status code indicates that the request body is invalid."
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      },
      "delete": {
        "description": "This HTTP request deletes the specified application in API Gateway.",
        "operationId": "deleteUser",
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "name": "userId",
            "in": "path",
            "description": "This parameter specifies the ID of an application that is to be deleted in API Gateway.",
            "required": true,
            "type": "string"
          }
        ],
        "responses": {
          "204": {
            "description": "This status code indicates that the specified user has been successfully deleted from API Gateway."
          },
          "401": {
            "description": "This status code indicates that either user didn't provide right credentials or user doesn't have required privileges to access this API."
          },
          "404": {
            "description": "This status code indicates that an user with the given id could not be found in API Gateway.",
            "examples": {
              "application/json": "{\r\n    \"errorDetails\": \" User with id: 732c4526-db9a-4ef9-9782-edda1a6aa9bc does not exist.\"\r\n}"
            }
          }
        },
        "security": [
          {
            "Basic": []
          }
        ]
      }
    }
  },
  "securityDefinitions": {
    "Basic": {
      "description": "API Gateway Administrator and API Gateway provider",
      "type": "basic"
    }
  },
  "definitions": {
    "AccessProfile": {
      "type": "object",
      "properties": {
        "description": {
          "type": "string",
          "description": "description of the accessprofile"
        },
        "groupIds": {
          "type": "array",
          "description": "list of groupIds assigned to the accessprofile",
          "items": {
            "type": "string"
          }
        },
        "id": {
          "type": "string",
          "description": "AccessProfile ID",
          "readOnly": true
        },
        "includeTeamAdminsAsApprovers": {
          "type": "boolean",
          "description": "When the property is set to true, all the team administrators becomes approvers. The default value is false"
        },
        "name": {
          "type": "string",
          "description": "name of the accessprofile"
        },
        "privilege": {
          "$ref": "#/definitions/BitSet"
        },
        "teamAdmin": {
          "$ref": "#/definitions/TeamAdmin"
        },
        "teamApprovers": {
          "$ref": "#/definitions/TeamApprovers"
        }
      },
      "description": "This model contains details about a Team in API Gateway"
    },
    "BitSet": {
      "type": "object",
      "properties": {
        "empty": {
          "type": "boolean"
        }
      }
    },
    "Group": {
      "type": "object",
      "properties": {
        "description": {
          "type": "string",
          "description": "description of the group"
        },
        "id": {
          "type": "string",
          "description": "Group ID",
          "readOnly": true
        },
        "name": {
          "type": "string",
          "description": "name of the group"
        },
        "userIds": {
          "type": "array",
          "description": "list of user's Ids assigned to the group",
          "items": {
            "type": "string"
          }
        }
      },
      "description": "This model contains details about a group in API Gateway"
    },
    "LockedAccounts": {
      "type": "object",
      "properties": {
        "lockedAccounts": {
          "type": "array",
          "description": "Comma separated list of user accounts which are locked.",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "TeamAdmin": {
      "type": "object",
      "properties": {
        "groupIds": {
          "type": "array",
          "description": "List of groupIds to be assigned as the team administrator. All users in the group will become team administrator.",
          "items": {
            "type": "string"
          }
        },
        "userIds": {
          "type": "array",
          "description": "List of userIds to be assigned as the team administrator.",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "TeamApprovers": {
      "type": "object",
      "properties": {
        "groupIds": {
          "type": "array",
          "description": "List of groupIds to be assigned as the team approvers. All users in the group will become team approvers.",
          "items": {
            "type": "string"
          }
        },
        "userIds": {
          "type": "array",
          "description": "List of userIds to be assigned as the team approvers.",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "UnlockAccounts": {
      "type": "object",
      "properties": {
        "userName": {
          "type": "array",
          "description": "Username that needs to be unlocked.",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "UnlockAccountsRequest": {
      "type": "object",
      "properties": {
        "unLockAccounts": {
          "$ref": "#/definitions/UnlockAccounts"
        }
      }
    },
    "User": {
      "type": "object",
      "properties": {
        "active": {
          "type": "boolean",
          "description": "active status of the user"
        },
        "allowDigestAuth": {
          "type": "boolean",
          "description": "list of email addresses of the user"
        },
        "emailAddresses": {
          "type": "array",
          "description": "list of email addresses of the user",
          "items": {
            "type": "string"
          }
        },
        "firstName": {
          "type": "string",
          "description": "first name of the user"
        },
        "id": {
          "type": "string",
          "description": "unique identifier of a user",
          "readOnly": true
        },
        "language": {
          "type": "string",
          "description": "preferred language of the user"
        },
        "lastName": {
          "type": "string",
          "description": "last name of the user"
        },
        "loginId": {
          "type": "string",
          "description": "login name"
        }
      },
      "description": "This model contains details about a User in API Gateway"
    }
  }
}