alfio-event/alf.io

API Key Authorization for Tickets List Endpoint

kmiskiewicz opened this issue · 3 comments

Hi, thank you for your amazing work. I hope you could help me with one issue.

I'd like to use the following endpoint through the API:

/admin/api/reservation/{purchaseContextType}/{publicIdentifier}/reservations/list

I attempted to call it using the API, but it doesn't work with the API key; it only works with the cookie. Below is the cURL command I used:

curl 'https://xxxxx.xxx/admin/api/reservation/event/test-event/reservations/list?page=0&search=&status=COMPLETE' \
  -H 'accept: application/json, text/plain, */*' \
  -H 'cache-control: no-cache' \
  -H 'cookie: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'

Could it be possible to authorize this endpoint with the API key instead of the cookie?

Is your feature request related to a problem? Please describe.

I need to be able to export tickets in an automated way to push them into a central system, which processes tickets from various channels. Currently, I am unable to access the endpoint using an API key, which makes it difficult to integrate this functionality into our automated workflows.

Describe the solution you'd like

I would like the endpoint /admin/api/reservation/event/test-event/reservations/list to accept API key authorization.

Describe alternatives you've considered

As an alternative, I have tried using cookie-based authentication, but it is not feasible for automated processes

Hi @kmiskiewicz ,

this definitely make sense, thank you for the suggestion.

However, we usually add new (suggested) features to public APIs if:

  • we receive an external contribution from third parties, after an initial discussion phase
  • the development is sponsored, see Wiki page

Let me know what would work better for you

Celestino

Thx. To be honest, both options could be OK. Perhaps it would be good to have a quick call sometime next week (I've just returned from holiday and need a couple of days to catch up). Do you have a form or email where I could elaborate on what we do, our plans, and our needs?

Hi, sure!
Please reach out to hello _at_ alf.io so that we can schedule a call.

Looking forward to hear from you!
Celestino