Comments (5)
FWIW the api currently handles unknown methods just fine, so you could call api.nodebalancer_create
and things would work as expected. However there's no method documentation or required argument verification for such calls.
I plan to add nodebalancer methods, and also a mechanism to check with the api of the api to handle unknown methods more sanely. There just isn't an ETA of when that will happen.
I will of course happily review any patches or pull requests. Though, I'm more in mind to have a script to auto-generate the bindings than to continue to maintain methods manually.
from linode-python.
Yeah, I started playing today and realised that "it just works". Great! :-D
Also, been looking at the code and it seems it should be scriptable as you say to me too, at least api.py (the one I was looking). I might give it a try later on. But there's no single file containing the API actions and required arguments that Linode updates, right ? Or I just didn't find it ?
Also, one silly question. The code says it is for Linode API v2, although current one is v3 1. And the URL seems a bit different on 1 too: https://api.linode.com/ instead of https://api.linode.com/api/ (note the missing "/api/" at the end). Also, I didn't see the "api_responseFormat" parameter on Linode documentation. Perhaps this uses Linode API v2, which is currently available, and has been dropped on Linode API v3 ? Or have you verified with Linode that it is correct to use all this (the slightly different URL and that parameter) ?
Thanks a lot!
Rodrigo
from linode-python.
Sorry, ignore the "api_responseFormat", I've just seen it :S (this happens when I do a lot of things at the same time :-D)
from linode-python.
Right, responseFormat better still be there.
https://api.linode.com/?api_key=abc123&api_action=test.echo&foo=bar
is the canonical way to access the api, only the documentation site is under http://www.linode.com/api/
As far as building the bindings with a script the ideal mechanism would be utilizing http://www.linode.com/api/utility/api.spec
The version is still at 2 because it hasn't been updated in a while to match, and there hasn't been a significant change in the behavior on the consumer end. There was a complete rewrite of the api by Linode between v1 and v2.
from linode-python.
So, a simple patch changing the LINODE_API_URL to https://api.linode.com/ is correct, right ? Do you want me to send it or you do it yourself ? (I've just tested it and the API seems to work okay too)
Cool, it sounds nice to create them automatically with that api method. Didn't know about it. If I have time will look into it during the weekend :-)
Ohh, is good to know it is not updated. If something fails (not the case yet), I'll consider this possibility :-)
Thanks a lot!
Rodrigo
from linode-python.
Related Issues (19)
- this python project is vulnerable to MITM as it fails to verify the ssl validity of the remote destination HOT 8
- Would be great to encode structured parameters as JSON
- New Decimal handling breaks at least shell --avail_linodeplans HOT 1
- fallthrough generic_request doesn't work?
- Namespaces and Setup.py HOT 1
- Version 1.1 on PyPI? HOT 2
- Debug logs include sensitive data
- Completely broke on Debian HOT 2
- AttributeError: 'Request' object has no attribute 'prepare' HOT 3
- Python 3 HOT 4
- Examples?
- Using API Correctly? HOT 1
- Which repository to use? HOT 1
- No more upgrade to support APIv4?
- Error when using API's nodebalancer_node_update() HOT 1
- illegal api_action sent if "Api" tested for not == None HOT 2
- Deploy to PyPI HOT 2
- Licensing HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from linode-python.