Code Monkey home page Code Monkey logo

Comments (4)

dirkjanfaber avatar dirkjanfaber commented on September 14, 2024

A statuscode of 429 indicates too many requests from the user in a short period: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429.

Not saying that there is nothing wrong in the code, but it might help to retry after a while of no requests. Leaving this issue open for now to be sure that it is gets resolved after a period of no requests.

from node-red-contrib-eskomsepush.

Ohwelt avatar Ohwelt commented on September 14, 2024

I retried after a few hours and received the same result - while it (always) works with curl command as often (no waiting time) as I use it (and I have tokens).
In my opinion, it is nearly impossible to develop my own flow with the EskomSePush node when I cannot trigger it with an inject command to test as often as I need to until my flow works properly (and while I have tokens left.).
Creating a flow with the node and to always wait an hour to see if it works like I want it to, is not realistic. Also the test=current is not really helpful as I need to test with real data before connecting it to the my PV Inverter.

In order to see, if the problem is the node or the API , I created my own function using the curl and header command.
The result is also quite interesting.

Checking with:
msg.headers['token'] = 'XXXXXXXX-XXXXXXXX-XXXXXXXX-XXXXXXXX';
https://developer.sepush.co.za/business/2.0/api_allowance
results in:
"{"allowance":{"count":1,"limit":50,"type":"daily"}}↵"

Testing with:
msg.headers['token'] = 'XXXXXXXX-XXXXXXXX-XXXXXXXX-XXXXXXXX';
https://developer.sepush.co.za/business/2.0/area?id=eskmo-13-belabelawarmbadtownbelabelalimpopo&test=current
results in:
"{"events":[{"end":"2023-06-11T20:30:00+02:00","note":"Stage 8 (TESTING: current)","start":"2023-06-11T18:00:00+02:00"}],"info":{"name":"TESTING Bela Bela(Warmbad) Town (13)","region":"Eskom Municipal, Belabela, Limpopo"},"schedule":{"days":[{"date":"2023-06-11","name":"Sunday","stages":[["12:00-14:30"],["04:00-06:30","12:0............

And requesting a schedule with:
msg.headers['token'] = 'XXXXXXXX-XXXXXXXX-XXXXXXXX-XXXXXXXX';
https://developer.sepush.co.za/business/2.0/area?id=eskmo-13-belabelawarmbadtownbelabelalimpopo
results in:
"{"error":"Free account abuse detected - Limited access \ud83d\ude40. Please pay if you can."}↵"

Something is really not working properly here.

Thanks for your help.

from node-red-contrib-eskomsepush.

Ohwelt avatar Ohwelt commented on September 14, 2024

A statuscode of 429 indicates too many requests from the user in a short period: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429.

That is solved:
I had two token that I tried from Node Red running on Cerbo. If the EskomSePush API recognises two different token coming from the same IP it blocks them. The curl command executed on the Mac worked, because they came from a different IP.

from node-red-contrib-eskomsepush.

dirkjanfaber avatar dirkjanfaber commented on September 14, 2024

Ah, that is good to know. Thanks! I'll close this issue then.

from node-red-contrib-eskomsepush.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.