{
    "documentation_version": 1,
    "base_url": "https://c7dev.com",
    "instructions_url": "https://c7dev.com/api_instructions",
    "selection": {
        "method": "GET",
        "parameter": "api",
        "required": false,
        "description": "Omit api for the full suite, or use an endpoint name for its instructions only.",
        "example_url": "https://c7dev.com/api_instructions?api=media_api"
    },
    "instructions": [
        "Choose an endpoint by its description, then use its documented HTTP method and parameter location.",
        "URL-encode GET query values. Preserve identifiers such as VAT numbers and registration codes as strings.",
        "For JSON APIs, require HTTP success and result=true before using returned data. Read error_message on failure.",
        "Do not fabricate missing data or treat null as zero or false. Warnings may indicate incomplete or older data.",
        "Do not blindly retry invalid input or access errors. Temporary service failures may be retried with bounded backoff.",
        "Responses prohibit browser caching. Inspect cached, timestamps and X-API-Version when those fields are available."
    ],
    "authentication": {
        "documentation": "Public; no token is required to read these instructions.",
        "restricted_endpoints": "Supply credentials provided by the API operator when access control requires them.",
        "token_locations": [
            "Authorization: Bearer YOUR_ACCESS_TOKEN",
            "X-Access-Token: YOUR_ACCESS_TOKEN",
            "access_token query or form parameter"
        ],
        "domain": "Send domain as a query or form parameter when the client token is restricted to registered domains. Access may also be restricted by IP.",
        "ai_generate": "Requires both access_token and domain in the form body."
    },
    "json_response_envelope": {
        "result": "boolean; request succeeded",
        "error": "boolean; request failed",
        "error_message": "string; empty on success",
        "server_time": "integer; Unix timestamp in seconds"
    },
    "errors": {
        "400": "Missing or invalid input.",
        "403": "Access denied; check token, registered domain and IP permissions.",
        "404": "Unknown API selected for instructions.",
        "405": "Unsupported method for the instructions endpoint.",
        "500": "Processing failed.",
        "503": "Service temporarily unavailable."
    },
    "apis": [
        {
            "name": "weather_api",
            "method": "GET",
            "path": "/weather_api",
            "description": "Worldwide weather forecasts for an address.",
            "instructions_url": "https://c7dev.com/api_instructions?api=weather_api",
            "request": {
                "parameter_location": "query",
                "parameters": {
                    "address": {
                        "type": "string",
                        "required": true,
                        "description": "Address or locality for the forecast."
                    },
                    "country": {
                        "type": "string",
                        "required": true,
                        "description": "ISO 3166-1 alpha-2 country code, such as LT or GB."
                    },
                    "country_code": {
                        "type": "string",
                        "required": false,
                        "description": "Alias for country."
                    },
                    "forecast_type": {
                        "type": "string",
                        "required": false,
                        "description": "Forecast interval.",
                        "default": "long-term",
                        "enum": [
                            "long-term"
                        ]
                    },
                    "countries": {
                        "type": "string",
                        "required": false,
                        "description": "Set to 1 to list supported countries instead of fetching a forecast."
                    },
                    "debug": {
                        "type": "string",
                        "required": false,
                        "description": "Set to 1 for request diagnostics; omit for ordinary requests.",
                        "enum": [
                            "0",
                            "1"
                        ]
                    }
                }
            },
            "response": {
                "format": "application/json",
                "headers": {
                    "X-API-Version": "weather_api_v17_geocoding_api_v2"
                }
            },
            "details": {
                "Supported countries": "Worldwide using ISO 3166-1 alpha-2 country codes",
                "Optional parameters": "country_code (alias for country), forecast_type, countries=1",
                "Address input": "The address is resolved internally and must match the requested country",
                "Returns": "location metadata and timezone, local date/hour forecasts, daily summaries, locally calculated sun/moon astronomy, and marine forecasts when available"
            },
            "notes": [
                "The countries=1 discovery request does not require address or country.",
                "The address must resolve within the requested country.",
                "Forecast dates, four-digit hour keys and astronomy timestamps use the location timezone. Server timestamps use UTC.",
                "Forecasts cache for 30 minutes and may include older cached data during outages; inspect timestamps and warnings.",
                "precipitation_rate_mm_h is an average over precipitation_period_hours. Marine data may be null."
            ],
            "examples": [
                {
                    "method": "GET",
                    "url": "https://c7dev.com/weather_api?address=Gedimino%20pr.%201%2C%20Vilnius&country=LT"
                }
            ]
        }
    ],
    "result": true,
    "error": false,
    "error_message": "",
    "server_time": 1791673141
}