Skip to main content
# Formatted APIs presentation for testing
Can be used as part of RESTful API test framework

# Install
sudo pip3 install restapi3

# Usage
1. 'Get' : 'query_strings'
1. 'Post' : 'data', 'files', 'json'
1. 'Put' : 'data', 'json'
1. 'Delete'

```Python
from restapi3.api import BaseAPIs, API

class Video_Model(BaseAPIs):

def __init__(self):
BaseAPIs.__init__(self, "http://XXXX")
self.headers = {'X-Device-ID': 'YA'}

@API
def get_video(self):
return {
'path': '/v1/A/C/X',
'headers': self.headers,
'method': 'Get',
'query_strings': {
'first_str': 'val space, yee',
'second_str': 123
},
'json': {
'a': 123,
'b': ['123', '234']
},
'files': {
'image': open('/Users/tedchen/Desktop/test.png', 'rb')
}
}


r = Video_Model().get_video() # Return for requests Response object

if r.status_code != 200:
raise Exception("Fail to call API")
r_json = r.json()
```


Metadata

Release files for restapi3 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for restapi3 0.0.1
File Interpreter ABI Platform Actions
restapi3-0.0.1-py3-none-any.whl Python 3 none any Details for restapi3-0.0.1-py3-none-any.whl

Release files / restapi3-0.0.1-py3-none-any.whl

Download URL restapi3-0.0.1-py3-none-any.whl
Size 4.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
cb5323a5678f003bc58d91ddba4d7a7e59b08b9ffaf9fa38ad9e26b9c51d8498
BLAKE2b-256 checksum
How to use checksums
a739f899e8ad8d348f05e02e265625995b25def0637644b0f4563fcdd9dadc5d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.9.1 pkginfo/1.4.1 requests/2.19.1 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.15.0 CPython/2.7.10

Security for restapi3 0.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.0.1 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page