Metadata-Version: 2.5
Name: onepostly
Version: 0.2.4
Summary: The official Python SDK for the Onepostly API
Project-URL: Homepage, https://onepostly.com
Project-URL: Repository, https://github.com/onepostly/onepostly-python
Author-email: Onepostly <support@onepostly.com>
License-Expression: Apache-2.0
License-File: LICENSE
Keywords: api,bluesky,facebook,instagram,linkedin,onepostly,pinterest,sdk,social-media,threads,tiktok,twitter,x,youtube
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Typing :: Typed
Requires-Python: >=3.10
Requires-Dist: httpx>=0.28.1
Requires-Dist: pydantic>=2.11
Requires-Dist: python-dateutil>=2.8.2
Requires-Dist: typing-extensions>=4.7.1
Provides-Extra: dev
Requires-Dist: pytest>=8.0; extra == 'dev'
Description-Content-Type: text/markdown

# onepostly
One API for all social media. Authenticate with a workspace API key (`op_…`).

This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:

- API version: 1.0.0
- Package version: 0.2.4
- Generator version: 7.25.0
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
For more information, please visit [https://onepostly.com](https://onepostly.com)

## Requirements.

Python 3.10+

## Installation & Usage
### pip install

If the python package is hosted on a repository, you can install directly using:

```sh
pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git
```
(you may need to run `pip` with root permission: `sudo pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git`)

Then import the package:
```python
import onepostly
```

### Setuptools

Install via [Setuptools](http://pypi.python.org/pypi/setuptools).

```sh
python setup.py install --user
```
(or `sudo python setup.py install` to install the package for all users)

Then import the package:
```python
import onepostly
```

### Tests

Execute `pytest` to run the tests.

## Getting Started

Please follow the [installation procedure](#installation--usage) and then run the following:

```python

import onepostly
from onepostly.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.onepostly.com
# See configuration.py for a list of all supported configuration parameters.
configuration = onepostly.Configuration(
    host = "https://api.onepostly.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyHeader
configuration.api_key['ApiKeyHeader'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyHeader'] = 'Bearer'

# Configure Bearer authorization (op_): ApiKeyBearer
configuration = onepostly.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)


# Enter a context with an instance of the API client
async with onepostly.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = onepostly.CommentsApi(api_client)
    id = 'id_example' # str | 
    create_comment_body = onepostly.CreateCommentBody() # CreateCommentBody | 

    try:
        # Create reply
        api_response = await api_instance.create_comment(id, create_comment_body)
        print("The response of CommentsApi->create_comment:\n")
        pprint(api_response)
    except ApiException as e:
        print("Exception when calling CommentsApi->create_comment: %s\n" % e)

```

## Documentation for API Endpoints

All URIs are relative to *https://api.onepostly.com*

Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*CommentsApi* | [**create_comment**](docs/CommentsApi.md#create_comment) | **POST** /v1/posts/{id}/comments | Create reply
*CommentsApi* | [**delete_comment**](docs/CommentsApi.md#delete_comment) | **DELETE** /v1/posts/{id}/comments/{commentId} | Delete own comment
*CommentsApi* | [**list_comments**](docs/CommentsApi.md#list_comments) | **GET** /v1/posts/{id}/comments | List comments
*ConnectionsApi* | [**connect_bluesky**](docs/ConnectionsApi.md#connect_bluesky) | **POST** /v1/connections/bluesky/connect | Connect Bluesky via App Password
*ConnectionsApi* | [**create_pinterest_board**](docs/ConnectionsApi.md#create_pinterest_board) | **POST** /v1/connections/{id}/pinterest/boards | Create Pinterest board
*ConnectionsApi* | [**get_connection_stats**](docs/ConnectionsApi.md#get_connection_stats) | **GET** /v1/connections/{id}/stats | Get connection account stats
*ConnectionsApi* | [**get_tik_tok_creator_info**](docs/ConnectionsApi.md#get_tik_tok_creator_info) | **GET** /v1/connections/{id}/tiktok/creator-info | Get TikTok creator info
*ConnectionsApi* | [**list_connection_media**](docs/ConnectionsApi.md#list_connection_media) | **GET** /v1/connections/{id}/media | List creator media
*ConnectionsApi* | [**list_connections**](docs/ConnectionsApi.md#list_connections) | **GET** /v1/connections | List connections
*ConnectionsApi* | [**list_facebook_pages**](docs/ConnectionsApi.md#list_facebook_pages) | **GET** /v1/connections/oauth/facebook/pages | List Facebook Pages for pending connect
*ConnectionsApi* | [**list_pinterest_boards**](docs/ConnectionsApi.md#list_pinterest_boards) | **GET** /v1/connections/{id}/pinterest/boards | List Pinterest boards
*ConnectionsApi* | [**select_facebook_page**](docs/ConnectionsApi.md#select_facebook_page) | **POST** /v1/connections/oauth/facebook/select | Select Facebook Page and finish connect
*ConnectionsApi* | [**start_o_auth**](docs/ConnectionsApi.md#start_o_auth) | **GET** /v1/connections/oauth/{platform}/start | Start OAuth connect
*EngagementApi* | [**bookmark**](docs/EngagementApi.md#bookmark) | **POST** /v1/posts/{id}/bookmarks | Bookmark
*EngagementApi* | [**like**](docs/EngagementApi.md#like) | **POST** /v1/posts/{id}/likes | Like
*EngagementApi* | [**list_retweeters**](docs/EngagementApi.md#list_retweeters) | **GET** /v1/posts/{id}/retweets | List retweeters
*EngagementApi* | [**quote**](docs/EngagementApi.md#quote) | **POST** /v1/posts/{id}/quotes | Quote tweet
*EngagementApi* | [**remove_bookmark**](docs/EngagementApi.md#remove_bookmark) | **DELETE** /v1/posts/{id}/bookmarks | Remove bookmark
*EngagementApi* | [**retweet**](docs/EngagementApi.md#retweet) | **POST** /v1/posts/{id}/retweets | Retweet
*EngagementApi* | [**undo_retweet**](docs/EngagementApi.md#undo_retweet) | **DELETE** /v1/posts/{id}/retweets | Undo retweet
*EngagementApi* | [**unlike**](docs/EngagementApi.md#unlike) | **DELETE** /v1/posts/{id}/likes | Unlike
*InsightsApi* | [**get_post_insights**](docs/InsightsApi.md#get_post_insights) | **GET** /v1/posts/{id}/insights | Get insights
*InsightsApi* | [**get_post_insights_timeline**](docs/InsightsApi.md#get_post_insights_timeline) | **GET** /v1/posts/{id}/insights/timeline | Get daily insights timeline
*MediaApi* | [**delete_media**](docs/MediaApi.md#delete_media) | **DELETE** /v1/media/{id} | Delete media
*MediaApi* | [**list_media**](docs/MediaApi.md#list_media) | **GET** /v1/media | List media
*MediaApi* | [**upload_media**](docs/MediaApi.md#upload_media) | **POST** /v1/media | Upload media
*PostsApi* | [**cancel_post**](docs/PostsApi.md#cancel_post) | **DELETE** /v1/posts/{id} | Cancel post
*PostsApi* | [**create_post**](docs/PostsApi.md#create_post) | **POST** /v1/posts | Create post
*PostsApi* | [**delete_post_destination**](docs/PostsApi.md#delete_post_destination) | **DELETE** /v1/posts/{id}/destinations/{destinationId} | Remote-delete destination
*PostsApi* | [**get_post**](docs/PostsApi.md#get_post) | **GET** /v1/posts/{id} | Get post
*PostsApi* | [**list_posts**](docs/PostsApi.md#list_posts) | **GET** /v1/posts | List posts
*WebhooksApi* | [**create_webhook**](docs/WebhooksApi.md#create_webhook) | **POST** /v1/webhooks | Create webhook
*WebhooksApi* | [**delete_webhook**](docs/WebhooksApi.md#delete_webhook) | **DELETE** /v1/webhooks/{id} | Delete webhook
*WebhooksApi* | [**get_webhook**](docs/WebhooksApi.md#get_webhook) | **GET** /v1/webhooks/{id} | Get webhook
*WebhooksApi* | [**list_webhook_deliveries**](docs/WebhooksApi.md#list_webhook_deliveries) | **GET** /v1/webhooks/{id}/deliveries | List webhook deliveries
*WebhooksApi* | [**list_webhook_event_types**](docs/WebhooksApi.md#list_webhook_event_types) | **GET** /v1/webhooks/events | List webhook event types
*WebhooksApi* | [**list_webhooks**](docs/WebhooksApi.md#list_webhooks) | **GET** /v1/webhooks | List webhooks
*WebhooksApi* | [**rotate_webhook_secret**](docs/WebhooksApi.md#rotate_webhook_secret) | **POST** /v1/webhooks/{id}/rotate-secret | Rotate webhook secret
*WebhooksApi* | [**test_webhook**](docs/WebhooksApi.md#test_webhook) | **POST** /v1/webhooks/{id}/test | Send test event
*WebhooksApi* | [**update_webhook**](docs/WebhooksApi.md#update_webhook) | **PATCH** /v1/webhooks/{id} | Update webhook


## Documentation For Models

 - [Actor](docs/Actor.md)
 - [Bookmark201Response](docs/Bookmark201Response.md)
 - [Comment](docs/Comment.md)
 - [ConnectBluesky200Response](docs/ConnectBluesky200Response.md)
 - [ConnectBlueskyRequest](docs/ConnectBlueskyRequest.md)
 - [Connection](docs/Connection.md)
 - [CreateComment201Response](docs/CreateComment201Response.md)
 - [CreateCommentBody](docs/CreateCommentBody.md)
 - [CreatePinterestBoard201Response](docs/CreatePinterestBoard201Response.md)
 - [CreatePinterestBoardRequest](docs/CreatePinterestBoardRequest.md)
 - [CreatePostBody](docs/CreatePostBody.md)
 - [CreatePostBodyDestinationsInner](docs/CreatePostBodyDestinationsInner.md)
 - [CreateWebhook201Response](docs/CreateWebhook201Response.md)
 - [CreateWebhookBody](docs/CreateWebhookBody.md)
 - [DeleteComment200Response](docs/DeleteComment200Response.md)
 - [DestinationIdBody](docs/DestinationIdBody.md)
 - [DestinationStatus](docs/DestinationStatus.md)
 - [Error](docs/Error.md)
 - [ErrorError](docs/ErrorError.md)
 - [GetConnectionStats200Response](docs/GetConnectionStats200Response.md)
 - [GetPostInsights200Response](docs/GetPostInsights200Response.md)
 - [GetPostInsights200ResponseInsights](docs/GetPostInsights200ResponseInsights.md)
 - [GetPostInsights200ResponseInsightsDestinationsInner](docs/GetPostInsights200ResponseInsightsDestinationsInner.md)
 - [GetPostInsightsTimeline200Response](docs/GetPostInsightsTimeline200Response.md)
 - [GetPostInsightsTimeline200ResponseTimeline](docs/GetPostInsightsTimeline200ResponseTimeline.md)
 - [GetPostInsightsTimeline200ResponseTimelineDestinationsInner](docs/GetPostInsightsTimeline200ResponseTimelineDestinationsInner.md)
 - [GetPostInsightsTimeline200ResponseTimelineDestinationsInnerPointsInner](docs/GetPostInsightsTimeline200ResponseTimelineDestinationsInnerPointsInner.md)
 - [GetTikTokCreatorInfo200Response](docs/GetTikTokCreatorInfo200Response.md)
 - [GetTikTokCreatorInfo200ResponseCreatorInfo](docs/GetTikTokCreatorInfo200ResponseCreatorInfo.md)
 - [Like201Response](docs/Like201Response.md)
 - [ListComments200Response](docs/ListComments200Response.md)
 - [ListConnectionMedia200Response](docs/ListConnectionMedia200Response.md)
 - [ListConnections200Response](docs/ListConnections200Response.md)
 - [ListFacebookPages200Response](docs/ListFacebookPages200Response.md)
 - [ListFacebookPages200ResponsePagesInner](docs/ListFacebookPages200ResponsePagesInner.md)
 - [ListMedia200Response](docs/ListMedia200Response.md)
 - [ListPinterestBoards200Response](docs/ListPinterestBoards200Response.md)
 - [ListPinterestBoards200ResponseBoardsInner](docs/ListPinterestBoards200ResponseBoardsInner.md)
 - [ListPosts200Response](docs/ListPosts200Response.md)
 - [ListRetweeters200Response](docs/ListRetweeters200Response.md)
 - [ListRetweeters200ResponseRetweets](docs/ListRetweeters200ResponseRetweets.md)
 - [ListRetweeters200ResponseRetweetsDestinationsInner](docs/ListRetweeters200ResponseRetweetsDestinationsInner.md)
 - [ListWebhookDeliveries200Response](docs/ListWebhookDeliveries200Response.md)
 - [ListWebhookEventTypes200Response](docs/ListWebhookEventTypes200Response.md)
 - [ListWebhooks200Response](docs/ListWebhooks200Response.md)
 - [MediaAsset](docs/MediaAsset.md)
 - [MediaKind](docs/MediaKind.md)
 - [NormalizedMetrics](docs/NormalizedMetrics.md)
 - [Post](docs/Post.md)
 - [PostDestination](docs/PostDestination.md)
 - [PostResponse](docs/PostResponse.md)
 - [PostStatus](docs/PostStatus.md)
 - [Quote201Response](docs/Quote201Response.md)
 - [QuoteBody](docs/QuoteBody.md)
 - [Retweet201Response](docs/Retweet201Response.md)
 - [SelectFacebookPage200Response](docs/SelectFacebookPage200Response.md)
 - [SelectFacebookPageRequest](docs/SelectFacebookPageRequest.md)
 - [StartOAuth200Response](docs/StartOAuth200Response.md)
 - [TestWebhook200Response](docs/TestWebhook200Response.md)
 - [UpdateWebhookBody](docs/UpdateWebhookBody.md)
 - [UploadMedia201Response](docs/UploadMedia201Response.md)
 - [Webhook](docs/Webhook.md)


<a id="documentation-for-authorization"></a>
## Documentation For Authorization


Authentication schemes defined for the API:
<a id="ApiKeyHeader"></a>
### ApiKeyHeader

- **Type**: API key
- **API key parameter name**: x-api-key
- **Location**: HTTP header

<a id="ApiKeyBearer"></a>
### ApiKeyBearer

- **Type**: Bearer authentication (op_)


## Author




