RIAEvangelist / node-dominos-pizza-api

This is a node.js wrapper for the dominos pizza apis
MIT License
538 stars 129 forks source link

International India #2

Open darkyen opened 9 years ago

RIAEvangelist commented 9 years ago

not sure. I would love to know, please test

RIAEvangelist commented 9 years ago

closing due to inactivity

darkyen commented 9 years ago

Well I will try now x)

RIAEvangelist commented 9 years ago

awesome

RIAEvangelist commented 9 years ago

if you can provide some example calls from the Indian dominos we can start integrating them.

zubinmehta commented 8 years ago

@RIAEvangelist Here is the link for ordering: https://pizzaonline.dominos.co.in/

I can help out if you need anything to get this done.

I figured out that it makes calls to https://pizzaonline.dominos.co.in/getLocality/homedelivery/?city_id= where CITY_NAME list is standardized. However, when I briefly tried to create requests(using python) to get this locality, it seems like it needs cookies to be sent in the headers which are set in the browser. Not sure if it will be possible to do this from the commandline script ?

On the pizza order page: it does a post request to https://pizzaonline.dominos.co.in/quickadd with {product_id:11 quantity:1 csrf_token: }

At the same time, it also does a POST on https://pizzaonline.dominos.co.in/view/cart

and it returns the following after the addition of a single pizza: (alongwith the key upselling which is irrelevant)

{"session_id":"b7c3efb4506d1223ba8df8db9f09800e","customer_basket_info":[{"customers_basket_id":"1625913","products_model":"PIZZA","products_name":"Veg Extravaganza","attributes_details":"Crust : Classic Hand Tossed\nToppings : Black Olive + Onion + Crisp Capsicum + Mushroom + Fresh Tomato + Golden Corn + Jalapeno + Cheese\nSize : Medium (serves 2)","customers_basket_quantity":"1","final_price":"535","product_level_coupon_line_id":"0","order_level_coupon_line_id":"0","applied_coupon_line_id":"0","products_id":"11#983573,984255,983684,983687,983690,983693,983696,983699,983702,984318","product_image":"vegextra.png","product_details":""}],"net_price":"535","tax_price":"0.00","total_price":"535","upselling": ........

kaushik20-dev commented 6 years ago

I cannot find the API key for dominos India website.I logged in and searched in account settings.

MetalDent commented 5 years ago

Is this issue fixed or it's still not working for Domino's India?

madelinecameron commented 5 years ago

There shouldn't be an API key needed @kaushikraghupathruni. It uses a completely open REST API that the site uses.

This is why some countries can use the library with a simple change of URLs and others can't.

ghost commented 5 years ago

can someone link me to complete api with interface to take a look it would be much appreciated cause i am new to this

RIAEvangelist commented 3 years ago

v3.x branch international settings should make this possible now. Still need to work out the endpoints, but everything is baked in to support it.

RIAEvangelist commented 3 years ago

v3 now supports international apis.

Please have a look. If you can not find your API endpoints request help again, and we can work on it together. I will need to work with someone in country to make sure the order completes and you get Pizza.

RIAEvangelist commented 3 years ago

If anyone would like to contribute the API list as defined in docs/InternationalSupport.md

I would be happy to implement it into the code. I do need help from contributors though because I do not know addresses etc to use for testing without traveling to the country on my own.

Help would be greatly appreciated, and the world of Pizza lovers would thank you.

RIAEvangelist commented 3 years ago

@abhyuday-tripathi

Here is the objecct we need populated from docs/InternationalSupport.md

Please replace the URLs with the India URLs and I will integrate it into the code after we test.

You can find more details in the link above if you need.


{
      referer   :"https://order.dominos.nz/en/pages/order/",
      sourceUri :"order.dominos.nz",
          location:{
          find:urls.location.find
      },
      store     : {
          find    : "https://order.dominos.nz/power/store-locator?s=${line1}&c=${line2}&type=${type}",
          info    : "https://order.dominos.nz/power/store/${storeID}/profile",
          menu    : "https://order.dominos.nz/power/store/${storeID}/menu?lang=${lang}&structured=true"
      },
      order     : {
          validate: "https://order.dominos.nz/power/validate-order",
          price   : "https://order.dominos.nz/power/price-order",
          place   : "https://order.dominos.nz/power/place-order"
      },
      track   : "https://order.dominos.nz/orderstorage/GetTrackerData?"
}
alestor123 commented 3 years ago

Ok does it support delivery in india @RIAEvangelist and also we have to convert the price to Indian rupee

RIAEvangelist commented 3 years ago

If you add in the URLs, everything should automatically be done in Rupees.

bucharitesh commented 3 years ago

Is it working for Domino's india ? Did anyone try it ?

RIAEvangelist commented 3 years ago

I would be happy to help if anyone would be willing to work with me on it. I can not order a Pizza in India myself because I am not there.

Anyone who wants to help, please, just let me know. I will work with you for free and all your friends in India will think you are so cool.

I'm just too busy doing my regular work to stop and do this all by myself.

Namaste

On Fri, Jun 18, 2021 at 2:46 PM Ritesh Bucha @.***> wrote:

Is it working for Domino's india ? Did anyone try it ?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/RIAEvangelist/node-dominos-pizza-api/issues/2#issuecomment-864289836, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAC2DEOXP7WIUFTQLJWF3M3TTO5DBANCNFSM4A4PSF7Q .

RIAEvangelist commented 3 years ago

Also, I already documented how to do the internationalization on the readme. Please read it before you reach out ;)

On Fri, Jun 18, 2021 at 3:08 PM Brandon Nozaki Miller @.***> wrote:

I would be happy to help if anyone would be willing to work with me on it. I can not order a Pizza in India myself because I am not there.

Anyone who wants to help, please, just let me know. I will work with you for free and all your friends in India will think you are so cool.

I'm just too busy doing my regular work to stop and do this all by myself.

Namaste

On Fri, Jun 18, 2021 at 2:46 PM Ritesh Bucha @.***> wrote:

Is it working for Domino's india ? Did anyone try it ?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/RIAEvangelist/node-dominos-pizza-api/issues/2#issuecomment-864289836, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAC2DEOXP7WIUFTQLJWF3M3TTO5DBANCNFSM4A4PSF7Q .

rishabhkeshan commented 3 years ago

Hey in India, we get an OTP based on our debit card number, how will we support that. @RIAEvangelist I am up for working on the integration and testing.

RIAEvangelist commented 3 years ago

In hospital for a couple days will respond when I am out.

On Wed, Jun 23, 2021, 4:56 AM Rishabh Keshan @.***> wrote:

Hey in India, we get an OTP based on our debit card number, how will we support that. @RIAEvangelist https://github.com/RIAEvangelist I am up for working on the integration and testing.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/RIAEvangelist/node-dominos-pizza-api/issues/2#issuecomment-866772996, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAC2DEPVRH6GRZZUGHEWK5LTUHDYJANCNFSM4A4PSF7Q .

RIAEvangelist commented 3 years ago

@rishabhkeshan I do not know what an OTP is.

bucharitesh commented 3 years ago

Hey why don't we test COD first because Domino's had severe multiple data breaches. Me and my friends are ready to integrate and work with you on this. Plus the testing part.

gems2000 commented 3 years ago

OTP is One-Time Password. It works as a 2FA for payments and authentication platforms.

RIAEvangelist commented 3 years ago

Awesome, Thank you.

Perhaps sometime we could do a remote desktop session, so we could work on getting India setup

On Fri, Jul 2, 2021 at 11:00 AM Bodhisatta Das @.***> wrote:

OTP is One-Time Password. It works as a 2FA for payments and authentication platforms.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/RIAEvangelist/node-dominos-pizza-api/issues/2#issuecomment-873167614, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAC2DEO7ZJWB77Z6LGUPLBLTVX5CFANCNFSM4A4PSF7Q .

rishabhkeshan commented 3 years ago

Yeah I would too like to help out with it, can decide on a suitable time next week

abhyuday-tripathi commented 3 years ago

I think we should try Cash on Delivery first

RIAEvangelist commented 3 years ago

@rishabhkeshan and @abhyuday-tripathi I think trying CoD first is a good option, do you need help trying this?