mozilla-services / msisdn-gateway

INACTIVE - http://mzl.la/ghe-archive - An MSISDN based Authentication Server.
Mozilla Public License 2.0
18 stars 13 forks source link

ideas to improve callback URL semantics + plugins #103

Closed tarekziade closed 2 months ago

tarekziade commented 10 years ago

Looking at the current endpoints, it looks like we are adding a specific endpoint for each sms backend we're adding. e.g.:

in index.js. With the same code beside grabbing the right options from the request depending on the backend.

If possible we should try to have the SMS backend specific code located into the class in sms/.js and have the callback code implemented there.

One other improvement in mind to have a single url, with the backend name as a param : /sms/momt/callback?name=nexmo&msisdn=xxx&text=xxx&...

Natim commented 10 years ago

We don't choose the callback formalism. It is defined by the SMS provider.

tarekziade commented 10 years ago

We don't choose the callback formalism. It is defined by the SMS provider.

I don't understand why that prevents us from wrapping the code for a given provider in a single class

Natim commented 10 years ago

Hum I think I see what you mean. I will try that yes.

tarekziade commented 10 years ago

cool! It's just an improvement idea, not urgent