Skip to content

getlate-dev/late-php

Repository files navigation

Late

API reference for Late. Authenticate with a Bearer API key. Base URL: https://getlate.dev/api

For more information, please visit https://getlate.dev.

Installation & Usage

Requirements

PHP 8.1 and later.

Composer

To install the bindings via Composer, add the following to composer.json:

{
  "repositories": [
    {
      "type": "vcs",
      "url": "https://github.com/getlate-dev/late-php.git"
    }
  ],
  "require": {
    "getlate-dev/late-php": "*@dev"
  }
}

Then run composer install

Manual Installation

Download the files and include autoload.php:

<?php
require_once('/path/to/Late/vendor/autoload.php');

Getting Started

Please follow the installation procedure and then run the following:

<?php
require_once(__DIR__ . '/vendor/autoload.php');



// Configure Bearer (JWT) authorization: bearerAuth
$config = Late\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new Late\Api\APIKeysApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$create_api_key_request = {"name":"Production API Key","expiresIn":365}; // \Late\Model\CreateApiKeyRequest

try {
    $result = $apiInstance->createApiKey($create_api_key_request);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling APIKeysApi->createApiKey: ', $e->getMessage(), PHP_EOL;
}

API Endpoints

All URIs are relative to https://getlate.dev/api

Class Method HTTP request Description
APIKeysApi createApiKey POST /v1/api-keys Create key
APIKeysApi deleteApiKey DELETE /v1/api-keys/{keyId} Delete key
APIKeysApi listApiKeys GET /v1/api-keys List keys
AccountGroupsApi createAccountGroup POST /v1/account-groups Create group
AccountGroupsApi deleteAccountGroup DELETE /v1/account-groups/{groupId} Delete group
AccountGroupsApi listAccountGroups GET /v1/account-groups List groups
AccountGroupsApi updateAccountGroup PUT /v1/account-groups/{groupId} Update group
AccountSettingsApi deleteInstagramIceBreakers DELETE /v1/accounts/{accountId}/instagram-ice-breakers Delete IG ice breakers
AccountSettingsApi deleteMessengerMenu DELETE /v1/accounts/{accountId}/messenger-menu Delete FB persistent menu
AccountSettingsApi deleteTelegramCommands DELETE /v1/accounts/{accountId}/telegram-commands Delete TG bot commands
AccountSettingsApi getInstagramIceBreakers GET /v1/accounts/{accountId}/instagram-ice-breakers Get IG ice breakers
AccountSettingsApi getMessengerMenu GET /v1/accounts/{accountId}/messenger-menu Get FB persistent menu
AccountSettingsApi getTelegramCommands GET /v1/accounts/{accountId}/telegram-commands Get TG bot commands
AccountSettingsApi setInstagramIceBreakers PUT /v1/accounts/{accountId}/instagram-ice-breakers Set IG ice breakers
AccountSettingsApi setMessengerMenu PUT /v1/accounts/{accountId}/messenger-menu Set FB persistent menu
AccountSettingsApi setTelegramCommands PUT /v1/accounts/{accountId}/telegram-commands Set TG bot commands
AccountsApi deleteAccount DELETE /v1/accounts/{accountId} Disconnect account
AccountsApi getAccountHealth GET /v1/accounts/{accountId}/health Check account health
AccountsApi getAllAccountsHealth GET /v1/accounts/health Check accounts health
AccountsApi getFollowerStats GET /v1/accounts/follower-stats Get follower stats
AccountsApi listAccounts GET /v1/accounts List accounts
AccountsApi updateAccount PUT /v1/accounts/{accountId} Update account
AnalyticsApi getAnalytics GET /v1/analytics Get post analytics
AnalyticsApi getFollowerStats GET /v1/accounts/follower-stats Get follower stats
AnalyticsApi getLinkedInAggregateAnalytics GET /v1/accounts/{accountId}/linkedin-aggregate-analytics Get LinkedIn aggregate stats
AnalyticsApi getLinkedInPostAnalytics GET /v1/accounts/{accountId}/linkedin-post-analytics Get LinkedIn post stats
AnalyticsApi getYouTubeDailyViews GET /v1/analytics/youtube/daily-views Get YouTube daily views
CommentsApi deleteInboxComment DELETE /v1/inbox/comments/{postId} Delete comment
CommentsApi getInboxPostComments GET /v1/inbox/comments/{postId} Get post comments
CommentsApi hideInboxComment POST /v1/inbox/comments/{postId}/{commentId}/hide Hide comment
CommentsApi likeInboxComment POST /v1/inbox/comments/{postId}/{commentId}/like Like comment
CommentsApi listInboxComments GET /v1/inbox/comments List commented posts
CommentsApi replyToInboxPost POST /v1/inbox/comments/{postId} Reply to comment
CommentsApi sendPrivateReplyToComment POST /v1/inbox/comments/{postId}/{commentId}/private-reply Send private reply
CommentsApi unhideInboxComment DELETE /v1/inbox/comments/{postId}/{commentId}/hide Unhide comment
CommentsApi unlikeInboxComment DELETE /v1/inbox/comments/{postId}/{commentId}/like Unlike comment
ConnectApi completeTelegramConnect PATCH /v1/connect/telegram Check Telegram status
ConnectApi connectBlueskyCredentials POST /v1/connect/bluesky/credentials Connect Bluesky account
ConnectApi getConnectUrl GET /v1/connect/{platform} Get OAuth connect URL
ConnectApi getFacebookPages GET /v1/accounts/{accountId}/facebook-page List Facebook pages
ConnectApi getGmbLocations GET /v1/accounts/{accountId}/gmb-locations List GBP locations
ConnectApi getLinkedInOrganizations GET /v1/accounts/{accountId}/linkedin-organizations List LinkedIn orgs
ConnectApi getPendingOAuthData GET /v1/connect/pending-data Get pending OAuth data
ConnectApi getPinterestBoards GET /v1/accounts/{accountId}/pinterest-boards List Pinterest boards
ConnectApi getRedditFlairs GET /v1/accounts/{accountId}/reddit-flairs List subreddit flairs
ConnectApi getRedditSubreddits GET /v1/accounts/{accountId}/reddit-subreddits List Reddit subreddits
ConnectApi getTelegramConnectStatus GET /v1/connect/telegram Generate Telegram code
ConnectApi handleOAuthCallback POST /v1/connect/{platform} Complete OAuth callback
ConnectApi initiateTelegramConnect POST /v1/connect/telegram Connect Telegram directly
ConnectApi listFacebookPages GET /v1/connect/facebook/select-page List Facebook pages
ConnectApi listGoogleBusinessLocations GET /v1/connect/googlebusiness/locations List GBP locations
ConnectApi listLinkedInOrganizations GET /v1/connect/linkedin/organizations List LinkedIn orgs
ConnectApi listPinterestBoardsForSelection GET /v1/connect/pinterest/select-board List Pinterest boards
ConnectApi listSnapchatProfiles GET /v1/connect/snapchat/select-profile List Snapchat profiles
ConnectApi selectFacebookPage POST /v1/connect/facebook/select-page Select Facebook page
ConnectApi selectGoogleBusinessLocation POST /v1/connect/googlebusiness/select-location Select GBP location
ConnectApi selectLinkedInOrganization POST /v1/connect/linkedin/select-organization Select LinkedIn org
ConnectApi selectPinterestBoard POST /v1/connect/pinterest/select-board Select Pinterest board
ConnectApi selectSnapchatProfile POST /v1/connect/snapchat/select-profile Select Snapchat profile
ConnectApi updateFacebookPage PUT /v1/accounts/{accountId}/facebook-page Update Facebook page
ConnectApi updateGmbLocation PUT /v1/accounts/{accountId}/gmb-locations Update GBP location
ConnectApi updateLinkedInOrganization PUT /v1/accounts/{accountId}/linkedin-organization Switch LinkedIn account type
ConnectApi updatePinterestBoards PUT /v1/accounts/{accountId}/pinterest-boards Set default Pinterest board
ConnectApi updateRedditSubreddits PUT /v1/accounts/{accountId}/reddit-subreddits Set default subreddit
GMBAttributesApi getGoogleBusinessAttributes GET /v1/accounts/{accountId}/gmb-attributes Get attributes
GMBAttributesApi updateGoogleBusinessAttributes PUT /v1/accounts/{accountId}/gmb-attributes Update attributes
GMBFoodMenusApi getGoogleBusinessFoodMenus GET /v1/accounts/{accountId}/gmb-food-menus Get food menus
GMBFoodMenusApi updateGoogleBusinessFoodMenus PUT /v1/accounts/{accountId}/gmb-food-menus Update food menus
GMBLocationDetailsApi getGoogleBusinessLocationDetails GET /v1/accounts/{accountId}/gmb-location-details Get location details
GMBLocationDetailsApi updateGoogleBusinessLocationDetails PUT /v1/accounts/{accountId}/gmb-location-details Update location details
GMBMediaApi createGoogleBusinessMedia POST /v1/accounts/{accountId}/gmb-media Upload photo
GMBMediaApi deleteGoogleBusinessMedia DELETE /v1/accounts/{accountId}/gmb-media Delete photo
GMBMediaApi listGoogleBusinessMedia GET /v1/accounts/{accountId}/gmb-media List media
GMBPlaceActionsApi createGoogleBusinessPlaceAction POST /v1/accounts/{accountId}/gmb-place-actions Create action link
GMBPlaceActionsApi deleteGoogleBusinessPlaceAction DELETE /v1/accounts/{accountId}/gmb-place-actions Delete action link
GMBPlaceActionsApi listGoogleBusinessPlaceActions GET /v1/accounts/{accountId}/gmb-place-actions List action links
GMBReviewsApi getGoogleBusinessReviews GET /v1/accounts/{accountId}/gmb-reviews Get reviews
InvitesApi createInviteToken POST /v1/invite/tokens Create invite token
LinkedInMentionsApi getLinkedInMentions GET /v1/accounts/{accountId}/linkedin-mentions Resolve LinkedIn mention
LogsApi getPostLogs GET /v1/posts/{postId}/logs Get post logs
LogsApi listConnectionLogs GET /v1/connections/logs List connection logs
LogsApi listPostsLogs GET /v1/posts/logs List publishing logs
MediaApi getMediaPresignedUrl POST /v1/media/presign Get presigned upload URL
MessagesApi editInboxMessage PATCH /v1/inbox/conversations/{conversationId}/messages/{messageId} Edit message
MessagesApi getInboxConversation GET /v1/inbox/conversations/{conversationId} Get conversation
MessagesApi getInboxConversationMessages GET /v1/inbox/conversations/{conversationId}/messages List messages
MessagesApi listInboxConversations GET /v1/inbox/conversations List conversations
MessagesApi sendInboxMessage POST /v1/inbox/conversations/{conversationId}/messages Send message
MessagesApi updateInboxConversation PUT /v1/inbox/conversations/{conversationId} Update conversation status
PostsApi bulkUploadPosts POST /v1/posts/bulk-upload Bulk upload from CSV
PostsApi createPost POST /v1/posts Create post
PostsApi deletePost DELETE /v1/posts/{postId} Delete post
PostsApi getPost GET /v1/posts/{postId} Get post
PostsApi listPosts GET /v1/posts List posts
PostsApi retryPost POST /v1/posts/{postId}/retry Retry failed post
PostsApi unpublishPost POST /v1/posts/{postId}/unpublish Unpublish post
PostsApi updatePost PUT /v1/posts/{postId} Update post
ProfilesApi createProfile POST /v1/profiles Create profile
ProfilesApi deleteProfile DELETE /v1/profiles/{profileId} Delete profile
ProfilesApi getProfile GET /v1/profiles/{profileId} Get profile
ProfilesApi listProfiles GET /v1/profiles List profiles
ProfilesApi updateProfile PUT /v1/profiles/{profileId} Update profile
QueueApi createQueueSlot POST /v1/queue/slots Create schedule
QueueApi deleteQueueSlot DELETE /v1/queue/slots Delete schedule
QueueApi getNextQueueSlot GET /v1/queue/next-slot Get next available slot
QueueApi listQueueSlots GET /v1/queue/slots List schedules
QueueApi previewQueue GET /v1/queue/preview Preview upcoming slots
QueueApi updateQueueSlot PUT /v1/queue/slots Update schedule
RedditSearchApi getRedditFeed GET /v1/reddit/feed Get subreddit feed
RedditSearchApi searchReddit GET /v1/reddit/search Search posts
ReviewsApi deleteInboxReviewReply DELETE /v1/inbox/reviews/{reviewId}/reply Delete review reply
ReviewsApi listInboxReviews GET /v1/inbox/reviews List reviews
ReviewsApi replyToInboxReview POST /v1/inbox/reviews/{reviewId}/reply Reply to review
ToolsApi checkInstagramHashtags POST /v1/tools/instagram/hashtag-checker Check IG hashtag bans
ToolsApi downloadBlueskyMedia GET /v1/tools/bluesky/download Download Bluesky media
ToolsApi downloadFacebookVideo GET /v1/tools/facebook/download Download Facebook video
ToolsApi downloadInstagramMedia GET /v1/tools/instagram/download Download Instagram media
ToolsApi downloadLinkedInVideo GET /v1/tools/linkedin/download Download LinkedIn video
ToolsApi downloadTikTokVideo GET /v1/tools/tiktok/download Download TikTok video
ToolsApi downloadTwitterMedia GET /v1/tools/twitter/download Download Twitter/X media
ToolsApi downloadYouTubeVideo GET /v1/tools/youtube/download Download YouTube video
ToolsApi getYouTubeTranscript GET /v1/tools/youtube/transcript Get YouTube transcript
UsageApi getUsageStats GET /v1/usage-stats Get plan and usage stats
UsersApi getUser GET /v1/users/{userId} Get user
UsersApi listUsers GET /v1/users List users
WebhooksApi createWebhookSettings POST /v1/webhooks/settings Create webhook
WebhooksApi deleteWebhookSettings DELETE /v1/webhooks/settings Delete webhook
WebhooksApi getWebhookLogs GET /v1/webhooks/logs Get delivery logs
WebhooksApi getWebhookSettings GET /v1/webhooks/settings List webhooks
WebhooksApi testWebhook POST /v1/webhooks/test Send test webhook
WebhooksApi updateWebhookSettings PUT /v1/webhooks/settings Update webhook

Models

Authorization

Authentication schemes defined for the API:

bearerAuth

  • Type: Bearer authentication (JWT)

connectToken

  • Type: API key
  • API key parameter name: X-Connect-Token
  • Location: HTTP header

Tests

To run the tests, use:

composer install
vendor/bin/phpunit

Author

support@getlate.dev

About this package

This PHP package is automatically generated by the OpenAPI Generator project:

  • API version: 1.0.1
    • Generator version: 7.19.0
  • Build package: org.openapitools.codegen.languages.PhpClientCodegen

About

Late API - Official PHP SDK

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •  

Languages