Skip to main content

REST API plugin app for Alliance Auth

Alliance auth plugin to open up REST API endpoints

Currently supports:

Installation

Step 1 - Check Preconditions

Please make sure you meet all preconditions before proceeding:

  1. Restapi is a plugin for Alliance Auth. If you don't have Alliance Auth running already, please install it first before proceeding. (see the official AA installation guide for details)

  2. To use the Structure Timers endpoints you need to have the plugin installed, installation instructions

Note that Structure Timers is compatible with Alliance Auth's Structure Timer app and can be installed in parallel.

Step 2 - Install app

Make sure you are in the virtual environment (venv) of your Alliance Auth installation. Then install the newest release from PyPI:

pip install allianceauth-restapi

Step 3 - Configure settings

Configure your Auth settings (local.py) as follows:

  • Add 'restapi' to INSTALLED_APPS
  • add 'restapi' to APPS_WITH_PUBLIC_VIEWS

Step 4 - Finalize installation

Run migrations & copy static files

python manage.py migrate

Restart your supervisor services for Auth

How to use

Create a apikey in the admin area of your auth instance.

The api key will have the same rights as the user it's assigned to.

In your request headers, X-restapi-Key is one of your created api keys.

The following endpoints are available:

  • /rest/api/structuretimers
    • GET gives you a list of active structure timers, filtered via header params:
      • hours-passed: timers that have been passed by X hours (default: 2)
      • hours-until: timers coming out in X hours (default: 24)
    • POST let's you create a new timer with json data in the request body:
    • {
          "system": "Jita", # [string] Name of the system
          "structure": 35834, # [int] ID of the structure type
          "structure_name": "TEST TEST TEST", # [string] name of the structure
          "date": "2026-07-20T01:19:20+00:00", # [string] timer using pythons datetime.isoformat()
          "timer_type": "AN", # [string] type code of the timer¹
          "objective": "HO", # [string] type code of objective/standings¹
          "details_notes":"this is just a test timer", # [string] detail note
          "opsec": true # [boolean] is this timer opsec (optional, default: false)
      }
      

1: type codes

examples

create a new timer

curl -s -H "X-restapi-Key:this_is_my_api_key" -X POST https://auth.my-eve-corp.com/rest/api/structuretimers -d \
'
{
        "system": "Jita",
        "structure": 35834,
        "structure_name": "TEST TEST TEST",
        "date": "2026-07-20T01:19:20+00:00",
        "timer_type": "AN",
        "objective": "HO",
        "details_notes":"this is just a test timer",
        "opsec": true
    }
' | jq

result:

{
  "username": "munsking",
  "system": {
    "id": 30000142,
    "name": "Jita"
  },
  "structure": {
    "id": 35834,
    "type": "Keepstar",
    "name": "TEST TEST TEST"
  },
  "url": "http://auth.my-eve-corp.com/structuretimers/edit/1"
}

get a list of active timers

curl -s -H "X-restapi-Key:this_is_my_api_key" -H "hours-passed:12" -H "hours-until:48" -X GET https://auth.my-eve-corp.com/rest/api/structuretimers | jq

result:

{
  "timers": [
    {
      "date": "2026-07-20 01:19",
      "timestamp": 1784510360,
      "structure": {
        "id": 35834,
        "name": "TEST TEST TEST",
        "type": "Keepstar"
      },
      "stance": "HO",
      "owner": null,
      "type": "AN",
      "system": "Jita",
      "important": false,
      "opsec": true
    }
  ]
}

Metadata

Release files for allianceauth-restapi 1.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for allianceauth-restapi 1.1.1
File Size Uploaded Provenance Actions
allianceauth_restapi-1.1.1.tar.gz 22.9 kB Without provenance Details for allianceauth_restapi-1.1.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for allianceauth-restapi 1.1.1
File Interpreter ABI Platform Actions
allianceauth_restapi-1.1.1-py3-none-any.whl Python 3 none any Details for allianceauth_restapi-1.1.1-py3-none-any.whl

Total release size: 47.9 kB

Release files / allianceauth_restapi-1.1.1.tar.gz

Download URL allianceauth_restapi-1.1.1.tar.gz
Size 22.9 kB
Tags Source
SHA-256 checksum
How to use checksums
efea59252d3284bf5b1e3c150e0c6761165f5a26137ab926bef9440d7d0896f3
BLAKE2b-256 checksum
How to use checksums
e3ef2f7cf93a6b5b3bc11f319e5c3761532d206a4f6ea0362e27cee4fbe310bc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-requests/2.34.2

Release files / allianceauth_restapi-1.1.1-py3-none-any.whl

Download URL allianceauth_restapi-1.1.1-py3-none-any.whl
Size 25.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
134186e3a46102fe2d01de16565c161698b247eb9d41c1b9737a497fc01ce602
BLAKE2b-256 checksum
How to use checksums
82c2284a57523be5073e3f46014b224b37f93ee765ae98d562379cf87b15c1d6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-requests/2.34.2

Security for allianceauth-restapi 1.1.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page