> ## Documentation Index
> Fetch the complete documentation index at: https://docs.northaxiumdata.ca/llms.txt
> Use this file to discover all available pages before exploring further.

# Department Profile

> Aggregated procurement profile for a federal department.

## Overview

Returns an aggregated procurement profile for a federal department — total spend, top vendors, event type breakdown, and recent contracts.

## Path Parameters

<ParamField path="name" type="string" required>
  Exact department name string — e.g. `National Defence | Défense nationale`. Example: `Justin Trudeau`.
</ParamField>

<RequestExample>
  ```bash cURL theme={null}
  curl -H "X-API-Key: your_api_key_here" \
    "https://api.northaxiumdata.ca/api/v1/departments/National%20Defence%20%7C%20D%C3%A9fense%20nationale"
  ```

  ```python Python theme={null}
  import requests

  headers = {"X-API-Key": "your_api_key_here"}
  dept = "National Defence | Défense nationale"

  response = requests.get(
      f"https://api.northaxiumdata.ca/api/v1/departments/{dept}",
      headers=headers
  )
  print(response.json())
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "data": {
      "department": "National Defence | Défense nationale",
      "record_count": 18432,
      "total_value": 4821034521.00,
      "first_event_date": "2004-01-09",
      "last_event_date": "2025-12-01",
      "top_vendors": [
        {
          "vendor": "Lockheed Martin Canada Inc",
          "total_value": 980000000.00,
          "contract_count": 124
        }
      ],
      "by_event_type": [
        { "event_type": "award", "count": 2100, "total_value": 0.00 },
        { "event_type": "contract", "count": 15200, "total_value": 4821034521.00 },
        { "event_type": "tender", "count": 1132, "total_value": 0.00 }
      ],
      "recent_contracts": [
        {
          "record_id": "abc123",
          "vendor": "Lockheed Martin Canada Inc",
          "department": "National Defence | Défense nationale",
          "value": 3200000.00,
          "date": "2025-11-01"
        }
      ]
    }
  }
  ```

  ```json 404 theme={null}
  {
    "error": {
      "code": "NOT_FOUND",
      "message": "Department not found."
    }
  }
  ```

  ```json 401 theme={null}
  {
    "error": {
      "code": "UNAUTHORIZED",
      "message": "Missing API key. Pass your key in the X-API-Key header."
    }
  }
  ```

  ```json 429 theme={null}
  {
    "error": {
      "code": "RATE_LIMITED",
      "message": "Monthly request limit exceeded. Upgrade your plan for higher limits."
    }
  }
  ```
</ResponseExample>
