Tib612 / pluxee-api

A python API to access Pluxee (Sodexo) balance and transactions
https://pypi.org/project/pluxee-api/
MIT License
5 stars 1 forks source link

SSL Certificate Error #1

Open marcolinux46 opened 3 weeks ago

marcolinux46 commented 3 weeks ago

Hi,

I used the library with an italian account but i received a SSL error. Can you help you to resolve this issue? I'm interested to work with this library 1718006480206144451513174845342

marcolinux46 commented 3 weeks ago

If you want i can help you to improve the library for italian users

Tib612 commented 2 weeks ago

Hi Marcolinux46,

Thanks for your message. I could reproduce the error. I will try to solve it this evening.

Tib612 commented 2 weeks ago

If you want i can help you to improve the library for italian users

Thank you, if you help me, I can make it work with Italian users. It seems the login method is different from Belgium though. On which website (URL) do you check your balance ?

Also, if the HTML is different, I will probably need the HTML of the page so I can extract the data and maybe some screenshot. (Don't forget to hide and remove sensible info like name, balance). I'll add a wiki with the info I need to make it work on other countries.

marcolinux46 commented 2 weeks ago

I @Tib612 ,

Thank you for your answer. I will provide you all the informations

marcolinux46 commented 2 weeks ago

Do you need the URL from website not from the android app right?

marcolinux46 commented 2 weeks ago

So,

from website you have to go on:

https://buoni.clienti.pluxee.it/

and click on login

image

login.txt

marcolinux46 commented 2 weeks ago

Clicked Login button you will find the authentication phase with email

image

marcolinux46 commented 2 weeks ago

And after the password

image

marcolinux46 commented 2 weeks ago

and this is the finale page

image

marcolinux46 commented 2 weeks ago

I will send you the html for:

balance: balance-movements.txt

image

marcolinux46 commented 2 weeks ago

Movements

movements-searchmovements.txt

image

marcolinux46 commented 2 weeks ago

I think this is a good starting point...

Let me know if you need something else.

Tib612 commented 2 weeks ago

Thanks for the infos. I started working on a fix for the SSL and to add data retrieval for Italy.

What is the URL (path) for the transactions ("movimenti") ?

I will need the GET/POST request made to retrieve the balance and transactions. The payload should be enough I think. It can be found in the network tab of your chrome dev tool.

I will make a PR when the parsing of the HTML and the login are ready.

marcolinux46 commented 2 weeks ago

Hi @Tib612 ,

this is the url for the Transactions("movimenti")

https://buoni.clienti.pluxee.it/BPE/Movimenti.aspx

For balance and transactions in the network tab i have more than one payload in GET request.

Balance:

RequestUrl: https://buoni.clienti.pluxee.it/WebResource.axd?d=pynGkmcFUV13He1Qd6_TZD3YJONjE4lo8ThtpREC3HB4pnteSA8d4ONQjSOhqw1LPb6rvzXosMX4MfRabbMVGg2&t=638259476865233147

Payload: pynGkmcFUV13He1Qd6_TZD3YJONjE4lo8ThtpREC3HB4pnteSA8d4ONQjSOhqw1LPb6rvzXosMX4MfRabbMVGg2

RequestUrl: https://buoni.clienti.pluxee.it/ScriptResource.axd?d=uHIkleVeDJf4xS50Krz-yGxjMpHXjadahB0rKxMU_4Fu96evfGUXXRtGIM4fY3KTLh9vtqikxuuY7wgdbtxvH7N57Qiu_NH38s0hptlNmbB5f3mY-EgSiShzMUMMcU-BrFUy2ASJWmNVcGqTT5M1ukXd7YGAoMMShpn-i9rFtxw1&t=ffffffffb1d0f179

Payload: uHIkleVeDJf4xS50Krz-yGxjMpHXjadahB0rKxMU_4Fu96evfGUXXRtGIM4fY3KTLh9vtqikxuuY7wgdbtxvH7N57Qiu_NH38s0hptlNmbB5f3mY-EgSiShzMUMMcU-BrFUy2ASJWmNVcGqTT5M1ukXd7YGAoMMShpn-i9rFtxw1

RequestUrl: https://buoni.clienti.pluxee.it/ScriptResource.axd?d=Jw6tUGWnA15YEa3ai3FadGNXHx_DYc5p546xV4lr7BBOr0hJBeoR4VyPxP2lYb82jFgF-SGHgVDsqfQJNr54W8-PvQSburFzEXgaAe3Mrt6G4tMKZ4YLU9MnsTLZCV_SUQcf-asqgvppo4VJoDVLdj4beuHunu0djNlO_vzYb5c1&t=ffffffffb1d0f179

Payload: Jw6tUGWnA15YEa3ai3FadGNXHx_DYc5p546xV4lr7BBOr0hJBeoR4VyPxP2lYb82jFgF-SGHgVDsqfQJNr54W8-PvQSburFzEXgaAe3Mrt6G4tMKZ4YLU9MnsTLZCV_SUQcf-asqgvppo4VJoDVLdj4beuHunu0djNlO_vzYb5c1

Transaction

RequestUrl: https://buoni.clienti.pluxee.it/WebResource.axd?d=pynGkmcFUV13He1Qd6_TZD3YJONjE4lo8ThtpREC3HB4pnteSA8d4ONQjSOhqw1LPb6rvzXosMX4MfRabbMVGg2&t=638259476865233147

Payload: pynGkmcFUV13He1Qd6_TZD3YJONjE4lo8ThtpREC3HB4pnteSA8d4ONQjSOhqw1LPb6rvzXosMX4MfRabbMVGg2

RequestUrl: https://buoni.clienti.pluxee.it/ScriptResource.axd?d=uHIkleVeDJf4xS50Krz-yGxjMpHXjadahB0rKxMU_4Fu96evfGUXXRtGIM4fY3KTLh9vtqikxuuY7wgdbtxvH7N57Qiu_NH38s0hptlNmbB5f3mY-EgSiShzMUMMcU-BrFUy2ASJWmNVcGqTT5M1ukXd7YGAoMMShpn-i9rFtxw1&t=ffffffffb1d0f179

Payload: uHIkleVeDJf4xS50Krz-yGxjMpHXjadahB0rKxMU_4Fu96evfGUXXRtGIM4fY3KTLh9vtqikxuuY7wgdbtxvH7N57Qiu_NH38s0hptlNmbB5f3mY-EgSiShzMUMMcU-BrFUy2ASJWmNVcGqTT5M1ukXd7YGAoMMShpn-i9rFtxw1

RequestUrl: https://buoni.clienti.pluxee.it/ScriptResource.axd?d=Jw6tUGWnA15YEa3ai3FadGNXHx_DYc5p546xV4lr7BBOr0hJBeoR4VyPxP2lYb82jFgF-SGHgVDsqfQJNr54W8-PvQSburFzEXgaAe3Mrt6G4tMKZ4YLU9MnsTLZCV_SUQcf-asqgvppo4VJoDVLdj4beuHunu0djNlO_vzYb5c1&t=ffffffffb1d0f179

Payload: Jw6tUGWnA15YEa3ai3FadGNXHx_DYc5p546xV4lr7BBOr0hJBeoR4VyPxP2lYb82jFgF-SGHgVDsqfQJNr54W8-PvQSburFzEXgaAe3Mrt6G4tMKZ4YLU9MnsTLZCV_SUQcf-asqgvppo4VJoDVLdj4beuHunu0djNlO_vzYb5c1

They seem to be all the same

marcolinux46 commented 2 weeks ago

Also from different device i received this page

image

marcolinux46 commented 2 weeks ago

Hi @Tib612 ,

Everything Is ok? Do you need help?

Tib612 commented 2 weeks ago

Hi, I have implemented the parsing of the HTML files to extract the balance and transactions. I'm trying to make to login work now. Concerning the two factor authentication, I'm leaving it for later. Also, I found a temporary fix for the SSL certificate error. But it will be useless for non-Belgian user anyway.

marcolinux46 commented 2 weeks ago

Very good news. When you need to do some tests let me know