parse-community / parse-community/parse-server
Ability to register auth via cloud code
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 21.4k
- Forks
- 4.8k
- Avg merge
- 7h 45m
- Merged PRs (30d)
- 11
Description
New Feature / Enhancement Checklist
- I am not disclosing a vulnerability.
- I am not just asking a question.
- I have searched through existing issues.
Current Limitation
Any additional auth has to be defined in index.js, which can bloat the file, and also be disorganized if you like to keep user related code grouped in one file.
Feature / Enhancement Description
Be able to register auth using a helper method such as Parse.Cloud.registerAuth('authName', data);
Example Use Case
I have all my login code in /functions/login.js.
It would be nice to be able to write:
Parse.Cloud.registerAuth('authName', {...});
Rather than having to export and import back to index.js.
Alternatives / Workarounds
const authenticationLoader = require('../lib/Adapters/Auth');
authenticationLoader.loadAuthAdapter(
'authName',
options
);
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading /functions/login.js and the existing loader in lib/Adapters/Auth mentioned in the workaround. Trace how auth adapters are registered today and determine the public behavior needed for Parse.Cloud.registerAuth('authName', data), including how it should work when called from cloud code.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, nodejs
- Domain
- authentication, backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100