Skip to main content

TREST client

Description

Basic REST client with extended logging.

Features

  • Every request provide allure report step with all request and response data.
    Report data organised in a way convenient for testing API and repeating issues in Postman.
  • Dataclass objects provided by jto library can be used as request body.
    Useful for project organization.
  • Client configuration using Config module.
    • Print full request and response data to stdout. Useful for fast debugging.
    • Provide oneline representation of request and response. Useful for mor accurate logging.

Examples

Basic usage:

from trest.rest_request import RESTRequest

request = RESTRequest(method='GET', url='https://api.ipify.org')
response = request.send()

Client configuration:

from trest.configuration.config import Config

Config.one_line_response = True
Config.print_response_to_std_out = True

Metadata

Release files for trest 1.4.1

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

Source distribution (sdist)

Source distribution for trest 1.4.1
File Size Uploaded
trest-1.4.1.tar.gz 16.4 kB Details

Built distribution (wheel)

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

Total release size: 31.9 kB

Release files / trest-1.4.1.tar.gz

Download URL trest-1.4.1.tar.gz
Size 16.4 kB
Tags Source
SHA-256 checksum
How to use checksums
9819af5b93fa370eb048aaf4ef3410e5506ae0bbbd8991537d9fdbfc5b01f9fe
BLAKE2b-256 checksum
How to use checksums
93e0ca59f77064d57cc7d72c9de4561264570088d93d05c8d1784bee5a27af87
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.17

Release files / trest-1.4.1-py3-none-any.whl

Download URL trest-1.4.1-py3-none-any.whl
Size 15.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
50efaeb571e51036a5df1342fd32de1c164952bb4cf9e20b9ac1f7f8d7a40ecc
BLAKE2b-256 checksum
How to use checksums
e73b9938ec5a2d532118a6cd4eafc76c953140d3d9508f60e7b0bb482a25f1b7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.17

Release history Release notifications | RSS feed

This release

1.4.1 This release

2 release files

1.4.0

2 release files

1.3.0

2 release files

1.2.0

2 release files

1.1.6

2 release files

1.1.5

2 release files

1.1.4

2 release files

1.1.3

2 release files

1.1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.0

2 release files

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