Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Register users using django oscar API

I'm using Django oscar to build an eCommerce site. I have exposed every modules as an API using Oscar API. But I cant find an API for registering users by default in Oscar API.

like image 668
Gladwin Simendy Avatar asked Aug 26 '26 13:08

Gladwin Simendy


1 Answers

It looks like django-oscar-api currently does not provide an endpoint for registering users, only logging in pre-existing users: https://github.com/django-oscar/django-oscar-api/blob/master/oscarapi/urls.py#L8

You will need to create a custom API endpoint that can register/create a User. You can add this endpoint by creating a new view, customizing the Oscar API and adding the endpoint to urls.py: https://django-oscar-api.readthedocs.io/en/latest/usage/customizing_oscarapi.html

like image 169
accraze Avatar answered Aug 29 '26 04:08

accraze



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!