Skip to main content

A library that contains core logic and utilities for consuming REST APIs using Python SDKs generated by APIMatic.

Project description

apimatic-core

PyPI Tests Test Coverage Licence

Introduction

The APIMatic Core libraries provide a stable runtime that powers all the functionality of SDKs. This includes functionality like the ability to create HTTP requests, handle responses, apply authentication schemes, convert API responses back to object instances, and validate user and server data.

Installation

You will need Python 3.7-3.11 to support this package.

Simply run the command below to install the core library in your SDK. The core library will be added as a dependency your SDK.

pip install apimatic-core

API Call Classes

Name Description
RequestBuilder A builder class used to build an API Request
APICall A class used to create an API Call object
ResponseHandler Used to handle the response returned by the server

Authentication

Name Description
HeaderAuth A class supports HTTP authentication through HTTP Headers
QueryAuth A class supports HTTP authentication through query parameters
AuthGroup A helper class to support multiple authentication operation
And A helper class to support AND operation between multiple authentication types
Or A helper class to support OR operation between multiple authentication types
Single A helper class to support single authentication

Configurations

Name Description
EndpointConfiguration A class which hold the possible configurations for an endpoint
GlobalConfiguration A class which hold the global configuration properties to make a successful Api Call

Decorators

Name Description
LazyProperty A decorator class for lazy instantiation

Exceptions

Name Description
OneOfValidationException An exception class for the failed validation of oneOf (union-type) cases
AnyOfValidationException An exception class for the failed validation of anyOf (union-type) cases
AuthValidationException An exception class for the failed validation of authentication schemes

Factories

Name Description
HttpResponseFactory A factory class to create an HTTP Response

HTTP

Name Description
HttpCallBack A factory class to create an HTTP Response
HttpClientConfiguration A class used for configuring the SDK by a user
HttpRequest A class which contains information about the HTTP Response
ApiResponse A wrapper class for Api Response
HttpResponse A class which contains information about the HTTP Response

Logging Configuration

Name Description
ApiLoggingConfiguration Holds overall logging configuration for logging an API call
ApiRequestLoggingConfiguration Holds logging configuration for API request
ApiResponseLoggingConfiguration Holds logging configuration for API response

Logger

Name Description
SdkLogger Responsible for logging the request and response of an API call, it represents the default implementation of ApiLogger when there exist any logging configuration
NoneSdkLogger Represents the default implementation for ApiLogger when no logging configuration is provided
ConsoleLogger Represents the default implementation for Logger when no custom implementation is provided
LoggerFactory Responsible for providing the ApiLogger implementation (SdkLogger | NoneSdkLogger) based on the logging configuration

Types

Name Description
SerializationFormats An Enumeration of Array serialization formats
DateTimeFormat An Enumeration of Date Time formats
ErrorCase A class to represent Exception types
FileWrapper A wrapper to allow passing in content type for file uploads
Parameter A class to represent information about a Parameter passed in an endpoint
XmlAttributes A class to represent information about a XML Parameter passed in an endpoint
OneOf A class to represent information about OneOf union types
AnyOf A class to represent information about AnyOf union types
LeafType A class to represent the case information in an OneOf or AnyOf union type

Utilities

Name Description
ApiHelper A Helper Class with various functions associated with making an API Call
AuthHelper A Helper Class with various functions associated with authentication in API Calls
ComparisonHelper A Helper Class used for the comparison of expected and actual API response
FileHelper A Helper Class for files
XmlHelper A Helper class that holds utility methods for xml serialization and deserialization.
DateTimeHelper A Helper class that holds utility methods for validation of different datetime formats.
UnionTypeHelper A Helper class that holds utility methods for deserialization and validation of OneOf/AnyOf union types.

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

apimatic_core-0.2.15.tar.gz (82.1 kB view details)

Uploaded Source

Built Distribution

apimatic_core-0.2.15-py3-none-any.whl (120.3 kB view details)

Uploaded Python 3

File details

Details for the file apimatic_core-0.2.15.tar.gz.

File metadata

  • Download URL: apimatic_core-0.2.15.tar.gz
  • Upload date:
  • Size: 82.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.19

File hashes

Hashes for apimatic_core-0.2.15.tar.gz
Algorithm Hash digest
SHA256 087749bd7a8800fea7f86c093ff97f6d90d0d378529047e6e0f2d2e3139a8190
MD5 08a71238bf071481b738edf6e35537f6
BLAKE2b-256 4d5046c3da733d7f3b415c009d4e7fcb74249eb5037a69af78fcc98b53c869dc

See more details on using hashes here.

File details

Details for the file apimatic_core-0.2.15-py3-none-any.whl.

File metadata

File hashes

Hashes for apimatic_core-0.2.15-py3-none-any.whl
Algorithm Hash digest
SHA256 bcd79fef82afd6d09e6e398c7f3d2c1ba706142e987ea0aa1e1bbe730d34412e
MD5 54267bbb291c0d29b77f7c5e68cbe3c7
BLAKE2b-256 74d82b5daa5f972128a590ac3e83f118143163e962ce9cf767e691769263c74a

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page