{
  "openapi": "3.1.0",
  "info": {
    "title": "Password Generator API",
    "version": "1.0.0",
    "description": "Strong random passwords with the length and character classes you choose, generated with cryptographic randomness.\n\nGenerate strong random passwords with the length and character classes you choose, such as upper and lower case, digits and symbols, using cryptographic randomness. Nothing is stored or logged.",
    "contact": {
      "name": "Data and APIs",
      "url": "https://dataandapis.com/contact"
    },
    "termsOfService": "https://dataandapis.com/terms-of-service",
    "license": {
      "name": "Data and APIs Terms of Service",
      "url": "https://dataandapis.com/terms-of-service"
    },
    "x-logo": {
      "url": "https://dataandapis.com/images/password-generator.webp"
    }
  },
  "externalDocs": {
    "description": "Documentation, live tester and pricing",
    "url": "https://dataandapis.com/apis/password-generator"
  },
  "servers": [
    {
      "url": "https://password-generator.dataandapis.com"
    }
  ],
  "tags": [
    {
      "name": "Tools",
      "description": "Password Generator API belongs to the Tools category of the Data and APIs catalog."
    }
  ],
  "paths": {
    "/v1/generate-password": {
      "get": {
        "operationId": "generatePassword",
        "summary": "Generate Password",
        "description": "Generate Password endpoint of the Password Generator API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/password-generator/generate-password"
        },
        "parameters": [
          {
            "name": "exclude",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "1"
          },
          {
            "name": "excludeSimilarCharacters",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "false"
          },
          {
            "name": "length",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "15"
          },
          {
            "name": "lowercase",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "true"
          },
          {
            "name": "numbers",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "true"
          },
          {
            "name": "strict",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "false"
          },
          {
            "name": "symbols",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "false"
          },
          {
            "name": "uppercase",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "true"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "password": "CKZdiwzfCBMK5yS"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    }
  },
  "components": {
    "securitySchemes": {
      "ApiKey": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Api-Key",
        "description": "Create a free key at https://dataandapis.com/sign-up. 500 tokens a month on the Free plan; this API costs 1 token per call."
      }
    }
  },
  "security": [
    {
      "ApiKey": []
    }
  ]
}