Python SDK for integrating APIs published via Yappes platform
Project description
ypconnector-python
ypconnector-python is a Python SDK used for integrating the Yappes Published APIs with your application. SDK is installed via npm.
ypconnector-python provides individual action methods and a common method for making API requests.Currently it supports GET,POST,POST,DELETE and PATCH.
Install:
pip install ypconnector
Usage:
from yplib.ypconnector import YappesLibrary
//Yappes-Token obtained from yappes portal
yappesToken = "YOUR X-YAPPES-KEY";
ypObj = YappesLibrary(token)
//Data needed to call the library methods - individual Actions(GET/POST/PUT)
url = "http://localhost:8081/getdata";
data = {
"headers": {
"Content-Type":"application/json"
},
"queryparams": {
"queryParam1" : "value1"
},
"payload": {
"key":"value"
}
}
//GET Request with empty payload: {}
responseData = ypObj.get(url, data)
print(responseData["body"])
//POST Request
responseData = ypObj.post(url, data)
print(responseData["body"])
//PUT Request
responseData = ypObj.put(url, data)
print(responseData["body"])
//Common Method
//Data needed to call the library methods - common action (call)
url = "http://localhost:8081/getdata";
data = {
"method":"get"
"headers": {
"Content-Type":"application/json"
},
"queryparams": {
"queryParam1" : "value1"
},
"payload": {
"key":"value"
}
}
responseData = ypObj.call(url, data)
print(responseData["body"])
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ypconnector-1.1.2.tar.gz.
File metadata
- Download URL: ypconnector-1.1.2.tar.gz
- Upload date:
- Size: 2.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/40.0.0 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.7.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fa72ea94517a291759efb558fa520236f592d24664619c35f6b604eda2f0dbe8
|
|
| MD5 |
7987816a5ce39ec4b3b850ee87a3df04
|
|
| BLAKE2b-256 |
fbed067f1154fe3945c545ac432b2c65a2ee2dc1689f3ca5ee67e436c5bdb95e
|
File details
Details for the file ypconnector-1.1.2-py3-none-any.whl.
File metadata
- Download URL: ypconnector-1.1.2-py3-none-any.whl
- Upload date:
- Size: 2.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/40.0.0 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.7.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d6668370e16a72d394e92452582d2f6c42986aa418ba82547f46cb8556d775a8
|
|
| MD5 |
1a8484773488ae724a7f73e3c46fe982
|
|
| BLAKE2b-256 |
3c1c1cf04c6c502b3fbc6c59939ad0752e87a5db384c0193d86ec73dc36d70fb
|