influxdata / influxdata/influxdb

Add support for `GET /api/v2/authorizations?token=` to filter auths by token value (as in Cloud)

Open
#23,857 0 comments 0 reactions 0 assignees View on GitHub
area/api area/auth
Dominant language
Rust
Stars
31.7k
Forks
3.7k
Avg merge
13h 37m
Merged PRs (30d)
8

Description

__Proposal:__
Support the `?token=` query parameter in `GET /api/v2/authorizations` requests.
As in InfluxDB Cloud, the parameter should list only the
authorization with the specified `token` value.

__Current behavior:__
`GET /api/v2/authorizations` responds with the list of authorizations after applying other parameters; ignores `token=`.

__Desired behavior:__
- Parity with IDPE.
- `GET /api/v2/authorizations` should respond with a list that contains only the authorization with the specified `token` property value.

__Alternatives considered:__
None

__Use case:__
- Parity with IDPE (Cloud).
- Support for this parameter appears to be the only difference between the IDPE and OSS contracts for the `GET /api/v2/authorizations` endpoint.

Contributor guide

Open the contributing guide

Research direction

Start by locating the GET /api/v2/authorizations entry point and the existing handling of query parameters. Add support for token filtering consistent with the stated Cloud behavior, then verify that a request with token= returns only the authorization whose token property matches.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
api, authorization
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.