mollie / mollie/mollie-api-python

Add User-Agent header to OAuth requests

Open
#296 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Python
Stars
127
Forks
53
PR merge metrics
No merged PRs in 30d

Description

Jonas at Mollie requested to add User-Agent headers to all API requests. We are already doing that for all Mollie data requests, but during the OAuth setup we use a different client (OAuth2Session from requests-oauthlib), which doesn't use the custom User-Agent when refreshing tokens etc.

NB We also have the X-Mollie-Client-Info header, we can add that too.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Inspect the OAuth2Session setup and the existing header handling in mollie/api/client.py, including the X-Mollie-Client-Info reference around line 213. Ensure OAuth requests, including token refreshes, carry the requested User-Agent and client-info headers; done means the OAuth client consistently sends them.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, authentication
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.