Skip to content
This repository was archived by the owner on Mar 12, 2025. It is now read-only.

Add support for user credentials/jwt #5

Merged
merged 1 commit into from
Aug 5, 2019
Merged

Conversation

ThomasKranitsas
Copy link
Contributor

Fixes #1

Copy link
Collaborator

@callmekatootie callmekatootie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor issues but can indeed be merged 👍

schema = credentialsSchema
schemaType = 'User Credentials Configuration'
}

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment: A better configuration in my opinion would have been asking the user itself which approach they are going with - like a type field which can have m2m|user|jwt values instead of us figuring it out.

Also, note that this "check" is also duplicated in the helper function. Too trivial to wrap it in its own method but asking the user itself for the type would have thus helped.

```

**JWT Method Argument Authentication Configuration:**
- SUBMISSION_API_URL - Topcoder V5 Submission API URL. E.g. `https://api.topcoder.com/v5` or for dev `https://api.topcoder-dev.com/v5`
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment: So the JWT way is to only pass the submission api url and then pass the token each time any method is called? 🤔 hmm... Not sure why the constructor didn't accept the jwt token itself... assuming it is because it allows us to use different tokens for each method...

@callmekatootie callmekatootie merged commit 720d777 into develop Aug 5, 2019
@callmekatootie callmekatootie deleted the support-user-jwt branch September 25, 2019 06:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Adjust configuration to use either user or M2M JWTs
2 participants