postboost 1.0.0 → 1.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CODE_OF_CONDUCT.md +7 -0
- data/CONTRIBUTING.md +31 -0
- data/README.md +252 -0
- data/SECURITY.md +9 -0
- data/docs/AIApi.md +871 -0
- data/docs/AICredits.md +22 -0
- data/docs/AIUsage.md +20 -0
- data/docs/AIUsageText.md +24 -0
- data/docs/Account.md +19 -9
- data/docs/AccountAnalytics.md +28 -0
- data/docs/AccountAnalyticsInitialSync.md +20 -0
- data/docs/AccountConnectionHealth.md +34 -0
- data/docs/AccountErrorsInner.md +49 -0
- data/docs/AccountErrorsInnerOneOf.md +24 -0
- data/docs/AccountGroup.md +24 -0
- data/docs/AccountGroupInput.md +20 -0
- data/docs/AccountGroupsApi.md +372 -0
- data/docs/AccountHealth.md +34 -0
- data/docs/AccountHealthDailyCap.md +20 -0
- data/docs/AccountSchedule.md +22 -0
- data/docs/AccountsApi.md +231 -5
- data/docs/ActivityApi.md +87 -0
- data/docs/AddCompetitor202Response.md +20 -0
- data/docs/AddCompetitor409Response.md +20 -0
- data/docs/AddPostToQueueRequest.md +18 -0
- data/docs/AgentPageMeta.md +24 -0
- data/docs/AgentProposal.md +44 -0
- data/docs/AgentProposalDecision.md +18 -0
- data/docs/AgentRun.md +44 -0
- data/docs/AgentsApi.md +745 -0
- data/docs/AnalyticsApi.md +899 -0
- data/docs/AnalyticsPeriod.md +24 -0
- data/docs/AnalyticsSummary.md +20 -0
- data/docs/AnalyticsSummaryData.md +38 -0
- data/docs/ApiActivity.md +36 -0
- data/docs/ApiActivityOutcome.md +15 -0
- data/docs/ApiKey.md +32 -0
- data/docs/ApiKeyAbility.md +15 -0
- data/docs/ApiKeyInput.md +24 -0
- data/docs/ApproveAgentProposal200Response.md +18 -0
- data/docs/ApproveAgentProposal409Response.md +20 -0
- data/docs/ApproveInboxReplyDraft403Response.md +20 -0
- data/docs/ApprovePostRequest.md +24 -0
- data/docs/BestPostingTimes.md +20 -0
- data/docs/BestPostingTimesTimesInner.md +24 -0
- data/docs/BlogToSocial200Response.md +20 -0
- data/docs/BlogToSocial429Response.md +18 -0
- data/docs/BlogToSocialCaption.md +28 -0
- data/docs/BlogToSocialInput.md +44 -0
- data/docs/BlogToSocialMedia.md +20 -0
- data/docs/BlogToSocialResponse.md +30 -0
- data/docs/BrandVoice.md +48 -0
- data/docs/BrandVoiceInput.md +46 -0
- data/docs/BrandVoiceMeta.md +18 -0
- data/docs/CancelSubscription422Response.md +20 -0
- data/docs/CancelSubscription422ResponseErrors.md +18 -0
- data/docs/CancelSubscriptionRequest.md +18 -0
- data/docs/ChannelAccount.md +36 -0
- data/docs/CodedError.md +22 -0
- data/docs/Competitor.md +34 -0
- data/docs/CompetitorDetail.md +38 -0
- data/docs/CompetitorInput.md +20 -0
- data/docs/CompetitorMedia.md +28 -0
- data/docs/CompetitorSnapshot.md +22 -0
- data/docs/CompetitorsApi.md +296 -0
- data/docs/CompleteChunkedUploadRequest.md +20 -0
- data/docs/ConnectChannelInput.md +24 -0
- data/docs/CreateAccountGroup201Response.md +18 -0
- data/docs/CreateAgent201Response.md +18 -0
- data/docs/CreateApiKey201Response.md +18 -0
- data/docs/CreateApiKey201ResponseData.md +34 -0
- data/docs/CreateHashtagGroup201Response.md +18 -0
- data/docs/CreateInboxReplyDraft201Response.md +18 -0
- data/docs/CreateMediaFolderRequest.md +20 -0
- data/docs/CreateMention201Response.md +18 -0
- data/docs/CreateRecyclingRule201Response.md +18 -0
- data/docs/CreateReportExport201Response.md +18 -0
- data/docs/CreateResellerClient201Response.md +18 -0
- data/docs/CreateRssFeed201Response.md +18 -0
- data/docs/CreateTemplate201Response.md +18 -0
- data/docs/CreateWebhookSubscription201Response.md +18 -0
- data/docs/CreateWebhookSubscription201ResponseData.md +30 -0
- data/docs/DeleteAgent200Response.md +18 -0
- data/docs/DeleteMediaBulkRequest.md +1 -1
- data/docs/DeleteMediaBulkRequestItemsInner.md +49 -0
- data/docs/DeleteMediaFolderRequest.md +18 -0
- data/docs/DeleteResult.md +3 -3
- data/docs/GetAccountHealth200Response.md +18 -0
- data/docs/GetBrandVoice200Response.md +18 -0
- data/docs/GetCompetitor200Response.md +18 -0
- data/docs/GetInboxConversation200Response.md +18 -0
- data/docs/GetPostingSchedule200Response.md +18 -0
- data/docs/GetReportBranding200Response.md +18 -0
- data/docs/GuardrailError.md +28 -0
- data/docs/HashtagGroup.md +22 -0
- data/docs/HashtagGroupInput.md +20 -0
- data/docs/HashtagGroupsApi.md +372 -0
- data/docs/ImageAltText200Response.md +18 -0
- data/docs/ImageAltTextInput.md +18 -0
- data/docs/ImageAltTextResponse.md +24 -0
- data/docs/ImageCreditBalance.md +28 -0
- data/docs/ImageEditInput.md +30 -0
- data/docs/ImageGenerate200Response.md +20 -0
- data/docs/ImageGenerate429Response.md +18 -0
- data/docs/ImageGenerateInput.md +38 -0
- data/docs/ImageGenerationResponse.md +30 -0
- data/docs/ImagePrompt200Response.md +20 -0
- data/docs/ImagePrompt429Response.md +18 -0
- data/docs/ImagePromptInput.md +30 -0
- data/docs/ImagePromptResponse.md +18 -0
- data/docs/ImageVariations200Response.md +18 -0
- data/docs/ImageVariationsInput.md +24 -0
- data/docs/ImageVariationsResponse.md +26 -0
- data/docs/InboxApi.md +758 -0
- data/docs/InboxAuthor.md +22 -0
- data/docs/InboxConversation.md +46 -0
- data/docs/InboxConversationAccount.md +24 -0
- data/docs/InboxConversationUpdate.md +20 -0
- data/docs/InboxMessage.md +32 -0
- data/docs/InboxMessageAuthor.md +22 -0
- data/docs/InboxReplyDraft.md +42 -0
- data/docs/InboxReplyDraftApprove.md +18 -0
- data/docs/InboxReplyDraftEdit.md +18 -0
- data/docs/InboxReplyDraftInput.md +20 -0
- data/docs/{InitiateChunkedUpload200Response.md → InitiateChunkedUpload201Response.md} +2 -2
- data/docs/{InitiateRemoteUpload200Response.md → InitiateRemoteUpload201Response.md} +7 -7
- data/docs/{InitiateRemoteUpload200ResponseOneOf.md → InitiateRemoteUpload201ResponseOneOf.md} +2 -2
- data/docs/InitiateRemoteUploadRequest.md +3 -1
- data/docs/LearnBrandVoiceInput.md +24 -0
- data/docs/LearnBrandVoiceResponse.md +20 -0
- data/docs/LearnBrandVoiceResponseMeta.md +26 -0
- data/docs/ListAccountGroups200Response.md +22 -0
- data/docs/ListAgentProposals200Response.md +20 -0
- data/docs/ListAgentRuns200Response.md +20 -0
- data/docs/ListAgents200Response.md +18 -0
- data/docs/ListApiActivity200Response.md +22 -0
- data/docs/ListApiKeys200Response.md +18 -0
- data/docs/ListCompetitors200Response.md +18 -0
- data/docs/ListHashtagGroups200Response.md +22 -0
- data/docs/ListInboxConversations200Response.md +22 -0
- data/docs/ListInboxReplyDrafts200Response.md +22 -0
- data/docs/ListMediaFolders200Response.md +18 -0
- data/docs/ListMentions200Response.md +22 -0
- data/docs/ListMyWorkspaces200Response.md +18 -0
- data/docs/ListRecyclingRules200Response.md +18 -0
- data/docs/ListRecyclingRuns200Response.md +18 -0
- data/docs/ListReportExports200Response.md +18 -0
- data/docs/ListResellerClients200Response.md +20 -0
- data/docs/ListRssFeeds200Response.md +18 -0
- data/docs/ListTemplates200Response.md +22 -0
- data/docs/ListWebhookSubscriptions200Response.md +18 -0
- data/docs/Media.md +22 -8
- data/docs/MediaApi.md +435 -31
- data/docs/MediaBase64Input.md +24 -0
- data/docs/MediaFolder.md +24 -0
- data/docs/MediaFolderInput.md +20 -0
- data/docs/MediaFolderRef.md +20 -0
- data/docs/Mention.md +28 -0
- data/docs/MentionIdentity.md +24 -0
- data/docs/MentionIdentityInput.md +26 -0
- data/docs/MentionInput.md +22 -0
- data/docs/MentionsApi.md +379 -0
- data/docs/MessageOnly.md +18 -0
- data/docs/PollRssFeed200Response.md +22 -0
- data/docs/Post.md +10 -8
- data/docs/PostAnalytics.md +22 -0
- data/docs/PostContent.md +1 -1
- data/docs/PostInput.md +8 -2
- data/docs/PostOptionsInstagram.md +22 -0
- data/docs/PostOptionsTikTok.md +34 -0
- data/docs/PostOptionsYoutube.md +24 -0
- data/docs/PostVersion.md +4 -2
- data/docs/PostVersionOptions.md +24 -0
- data/docs/PostingSchedule.md +28 -0
- data/docs/PostingScheduleApi.md +377 -0
- data/docs/PostingScheduleDay.md +22 -0
- data/docs/PostingScheduleDayTimesInner.md +18 -0
- data/docs/PostingScheduleInput.md +24 -0
- data/docs/PostingTimeSlot.md +22 -0
- data/docs/PostingTimes.md +32 -0
- data/docs/PostingTimesBestInner.md +24 -0
- data/docs/PostingTimesDayIntervalsInnerInner.md +28 -0
- data/docs/PostingTimesDaysInner.md +24 -0
- data/docs/PostsApi.md +1264 -82
- data/docs/PreflightResult.md +26 -0
- data/docs/PublicWorkspace.md +24 -0
- data/docs/PublicWorkspacePivot.md +22 -0
- data/docs/PublishProgress.md +22 -0
- data/docs/QueueSlots.md +20 -0
- data/docs/Receipt.md +8 -8
- data/docs/ReceiptsApi.md +15 -1
- data/docs/RecommendedPostingTimes.md +26 -0
- data/docs/ReconnectLink.md +22 -0
- data/docs/RecyclingRule.md +42 -0
- data/docs/RecyclingRuleInput.md +34 -0
- data/docs/RecyclingRuleSettings.md +28 -0
- data/docs/RecyclingRuleUpdate.md +28 -0
- data/docs/RecyclingRun.md +28 -0
- data/docs/RemoveGenericSubscription422Response.md +18 -0
- data/docs/ReportBranding.md +28 -0
- data/docs/ReportBrandingInput.md +24 -0
- data/docs/ReportExport.md +42 -0
- data/docs/ReportExportInput.md +28 -0
- data/docs/RepurposeContent200Response.md +20 -0
- data/docs/RepurposeInput.md +54 -0
- data/docs/RepurposeInputTheme.md +22 -0
- data/docs/RepurposeResult.md +32 -0
- data/docs/RepurposeResultMedia.md +20 -0
- data/docs/RepurposeResultSource.md +22 -0
- data/docs/RepurposeSlide.md +20 -0
- data/docs/ResellerClient.md +32 -0
- data/docs/ResellerClientInput.md +18 -0
- data/docs/ResellerClientUsage.md +20 -0
- data/docs/RetryPostAccountResult.md +22 -0
- data/docs/RssFeed.md +38 -0
- data/docs/RssFeedInput.md +30 -0
- data/docs/RssFeedUpdate.md +30 -0
- data/docs/RunAgent202Response.md +18 -0
- data/docs/SchedulePostRequest.md +9 -1
- data/docs/ScheduleResult.md +4 -2
- data/docs/Subscription.md +5 -5
- data/docs/SubscriptionsApi.md +27 -5
- data/docs/Tag.md +4 -4
- data/docs/TagsApi.md +18 -4
- data/docs/Template.md +22 -0
- data/docs/TemplateContentItem.md +20 -0
- data/docs/TemplateInput.md +20 -0
- data/docs/TemplateInputContentInner.md +20 -0
- data/docs/TemplatesApi.md +372 -0
- data/docs/UpdateMediaRequest.md +6 -2
- data/docs/{UploadChunk200Response.md → UploadChunk201Response.md} +2 -2
- data/docs/User.md +7 -5
- data/docs/UsersApi.md +15 -1
- data/docs/WebhookEventName.md +15 -0
- data/docs/WebhookEventPayload.md +20 -0
- data/docs/WebhookSubscription.md +28 -0
- data/docs/WebhookSubscriptionInput.md +24 -0
- data/docs/WebhooksApi.md +221 -0
- data/docs/Workspace.md +8 -6
- data/docs/WorkspaceAgent.md +34 -0
- data/docs/WorkspaceAgentInput.md +26 -0
- data/docs/WorkspaceAgentSettings.md +26 -0
- data/docs/WorkspaceAgentUpdate.md +24 -0
- data/docs/WorkspaceInput.md +1 -1
- data/docs/WorkspacesApi.md +582 -3
- data/docs/XUsage.md +28 -0
- data/docs/XUsageCounter.md +20 -0
- data/lib/postboost/api/account_groups_api.rb +395 -0
- data/lib/postboost/api/accounts_api.rb +233 -4
- data/lib/postboost/api/activity_api.rb +97 -0
- data/lib/postboost/api/agents_api.rb +771 -0
- data/lib/postboost/api/ai_api.rb +884 -0
- data/lib/postboost/api/analytics_api.rb +910 -0
- data/lib/postboost/api/competitors_api.rb +300 -0
- data/lib/postboost/api/hashtag_groups_api.rb +395 -0
- data/lib/postboost/api/inbox_api.rb +789 -0
- data/lib/postboost/api/media_api.rb +496 -24
- data/lib/postboost/api/mentions_api.rb +397 -0
- data/lib/postboost/api/posting_schedule_api.rb +389 -0
- data/lib/postboost/api/posts_api.rb +1321 -104
- data/lib/postboost/api/receipts_api.rb +17 -2
- data/lib/postboost/api/subscriptions_api.rb +28 -3
- data/lib/postboost/api/tags_api.rb +23 -2
- data/lib/postboost/api/templates_api.rb +395 -0
- data/lib/postboost/api/users_api.rb +17 -2
- data/lib/postboost/api/webhooks_api.rb +228 -0
- data/lib/postboost/api/workspaces_api.rb +545 -2
- data/lib/postboost/api_client.rb +2 -2
- data/lib/postboost/api_error.rb +2 -2
- data/lib/postboost/configuration.rb +2 -2
- data/lib/postboost/models/account.rb +145 -4
- data/lib/postboost/models/account_analytics.rb +308 -0
- data/lib/postboost/models/account_analytics_initial_sync.rb +231 -0
- data/lib/postboost/models/account_connection_health.rb +389 -0
- data/lib/postboost/models/account_errors_inner.rb +105 -0
- data/lib/postboost/models/account_errors_inner_one_of.rb +243 -0
- data/lib/postboost/models/account_group.rb +271 -0
- data/lib/postboost/models/account_group_input.rb +252 -0
- data/lib/postboost/models/account_health.rb +352 -0
- data/lib/postboost/models/account_health_daily_cap.rb +239 -0
- data/lib/postboost/models/account_schedule.rb +255 -0
- data/lib/postboost/models/add_competitor202_response.rb +271 -0
- data/lib/postboost/models/add_competitor409_response.rb +223 -0
- data/lib/postboost/models/add_generic_subscription_request.rb +2 -2
- data/lib/postboost/models/add_post_to_queue_request.rb +215 -0
- data/lib/postboost/models/agent_page_meta.rb +269 -0
- data/lib/postboost/models/agent_proposal.rb +444 -0
- data/lib/postboost/models/agent_proposal_decision.rb +233 -0
- data/lib/postboost/models/agent_run.rb +434 -0
- data/lib/postboost/models/ai_credits.rb +256 -0
- data/lib/postboost/models/ai_usage.rb +237 -0
- data/lib/postboost/models/ai_usage_text.rb +252 -0
- data/lib/postboost/models/analytics_period.rb +270 -0
- data/lib/postboost/models/analytics_summary.rb +237 -0
- data/lib/postboost/models/analytics_summary_data.rb +327 -0
- data/lib/postboost/models/api_activity.rb +359 -0
- data/lib/postboost/models/api_activity_outcome.rb +49 -0
- data/lib/postboost/models/api_key.rb +308 -0
- data/lib/postboost/models/api_key_ability.rb +43 -0
- data/lib/postboost/models/api_key_input.rb +316 -0
- data/lib/postboost/models/approve_agent_proposal200_response.rb +221 -0
- data/lib/postboost/models/approve_agent_proposal409_response.rb +237 -0
- data/lib/postboost/models/approve_inbox_reply_draft403_response.rb +264 -0
- data/lib/postboost/models/approve_post_request.rb +247 -0
- data/lib/postboost/models/best_posting_times.rb +240 -0
- data/lib/postboost/models/best_posting_times_times_inner.rb +269 -0
- data/lib/postboost/models/blog_to_social200_response.rb +223 -0
- data/lib/postboost/models/blog_to_social429_response.rb +214 -0
- data/lib/postboost/models/blog_to_social_caption.rb +265 -0
- data/lib/postboost/models/blog_to_social_input.rb +548 -0
- data/lib/postboost/models/blog_to_social_media.rb +226 -0
- data/lib/postboost/models/blog_to_social_response.rb +276 -0
- data/lib/postboost/models/brand_voice.rb +531 -0
- data/lib/postboost/models/brand_voice_input.rb +646 -0
- data/lib/postboost/models/brand_voice_meta.rb +222 -0
- data/lib/postboost/models/cancel_subscription422_response.rb +223 -0
- data/lib/postboost/models/cancel_subscription422_response_errors.rb +216 -0
- data/lib/postboost/models/cancel_subscription_request.rb +217 -0
- data/lib/postboost/models/change_subscription_plan_request.rb +2 -2
- data/lib/postboost/models/channel_account.rb +380 -0
- data/lib/postboost/models/checkout_subscription200_response.rb +2 -2
- data/lib/postboost/models/checkout_subscription_request.rb +2 -2
- data/lib/postboost/models/coded_error.rb +242 -0
- data/lib/postboost/models/competitor.rb +320 -0
- data/lib/postboost/models/competitor_detail.rb +358 -0
- data/lib/postboost/models/competitor_input.rb +258 -0
- data/lib/postboost/models/competitor_media.rb +263 -0
- data/lib/postboost/models/competitor_snapshot.rb +234 -0
- data/lib/postboost/models/complete_chunked_upload_request.rb +243 -0
- data/lib/postboost/models/connect_channel_input.rb +265 -0
- data/lib/postboost/models/create_account_group201_response.rb +221 -0
- data/lib/postboost/models/create_agent201_response.rb +221 -0
- data/lib/postboost/models/create_api_key201_response.rb +221 -0
- data/lib/postboost/models/create_api_key201_response_data.rb +327 -0
- data/lib/postboost/models/create_hashtag_group201_response.rb +221 -0
- data/lib/postboost/models/create_inbox_reply_draft201_response.rb +221 -0
- data/lib/postboost/models/create_media_folder_request.rb +258 -0
- data/lib/postboost/models/create_mention201_response.rb +214 -0
- data/lib/postboost/models/create_recycling_rule201_response.rb +221 -0
- data/lib/postboost/models/create_report_export201_response.rb +221 -0
- data/lib/postboost/models/create_reseller_client201_response.rb +221 -0
- data/lib/postboost/models/create_rss_feed201_response.rb +221 -0
- data/lib/postboost/models/create_template201_response.rb +221 -0
- data/lib/postboost/models/create_webhook_subscription201_response.rb +221 -0
- data/lib/postboost/models/create_webhook_subscription201_response_data.rb +320 -0
- data/lib/postboost/models/delete_agent200_response.rb +221 -0
- data/lib/postboost/models/delete_media_bulk_request.rb +23 -4
- data/lib/postboost/models/delete_media_bulk_request_items_inner.rb +105 -0
- data/lib/postboost/models/delete_media_folder_request.rb +216 -0
- data/lib/postboost/models/delete_mode.rb +2 -2
- data/lib/postboost/models/delete_post_request.rb +2 -2
- data/lib/postboost/models/delete_posts_bulk_request.rb +2 -2
- data/lib/postboost/models/delete_receipts_bulk_request.rb +2 -2
- data/lib/postboost/models/delete_result.rb +23 -2
- data/lib/postboost/models/delete_user400_response.rb +2 -2
- data/lib/postboost/models/delete_users_bulk_request.rb +2 -2
- data/lib/postboost/models/delete_workspaces_bulk_request.rb +2 -2
- data/lib/postboost/models/get_account_health200_response.rb +223 -0
- data/lib/postboost/models/get_brand_voice200_response.rb +217 -0
- data/lib/postboost/models/get_competitor200_response.rb +221 -0
- data/lib/postboost/models/get_inbox_conversation200_response.rb +221 -0
- data/lib/postboost/models/get_posting_schedule200_response.rb +221 -0
- data/lib/postboost/models/get_remote_upload_status200_response.rb +2 -2
- data/lib/postboost/models/get_report_branding200_response.rb +221 -0
- data/lib/postboost/models/guardrail_error.rb +304 -0
- data/lib/postboost/models/hashtag_group.rb +254 -0
- data/lib/postboost/models/hashtag_group_input.rb +275 -0
- data/lib/postboost/models/image_alt_text200_response.rb +221 -0
- data/lib/postboost/models/image_alt_text_input.rb +221 -0
- data/lib/postboost/models/image_alt_text_response.rb +262 -0
- data/lib/postboost/models/image_credit_balance.rb +295 -0
- data/lib/postboost/models/image_edit_input.rb +387 -0
- data/lib/postboost/models/image_generate200_response.rb +230 -0
- data/lib/postboost/models/image_generate429_response.rb +214 -0
- data/lib/postboost/models/image_generate_input.rb +479 -0
- data/lib/postboost/models/image_generation_response.rb +305 -0
- data/lib/postboost/models/image_prompt200_response.rb +230 -0
- data/lib/postboost/models/image_prompt429_response.rb +214 -0
- data/lib/postboost/models/image_prompt_input.rb +377 -0
- data/lib/postboost/models/image_prompt_response.rb +221 -0
- data/lib/postboost/models/image_variations200_response.rb +221 -0
- data/lib/postboost/models/image_variations_input.rb +328 -0
- data/lib/postboost/models/image_variations_response.rb +280 -0
- data/lib/postboost/models/inbox_author.rb +235 -0
- data/lib/postboost/models/inbox_conversation.rb +425 -0
- data/lib/postboost/models/inbox_conversation_account.rb +241 -0
- data/lib/postboost/models/inbox_conversation_update.rb +257 -0
- data/lib/postboost/models/inbox_message.rb +360 -0
- data/lib/postboost/models/inbox_message_author.rb +235 -0
- data/lib/postboost/models/inbox_reply_draft.rb +410 -0
- data/lib/postboost/models/inbox_reply_draft_approve.rb +215 -0
- data/lib/postboost/models/inbox_reply_draft_edit.rb +221 -0
- data/lib/postboost/models/inbox_reply_draft_input.rb +232 -0
- data/lib/postboost/models/{initiate_chunked_upload200_response.rb → initiate_chunked_upload201_response.rb} +5 -5
- data/lib/postboost/models/initiate_chunked_upload_request.rb +2 -2
- data/lib/postboost/models/{initiate_remote_upload200_response.rb → initiate_remote_upload201_response.rb} +4 -4
- data/lib/postboost/models/{initiate_remote_upload200_response_one_of.rb → initiate_remote_upload201_response_one_of.rb} +5 -5
- data/lib/postboost/models/initiate_remote_upload_request.rb +16 -6
- data/lib/postboost/models/learn_brand_voice_input.rb +300 -0
- data/lib/postboost/models/learn_brand_voice_response.rb +237 -0
- data/lib/postboost/models/learn_brand_voice_response_meta.rb +281 -0
- data/lib/postboost/models/list_account_groups200_response.rb +248 -0
- data/lib/postboost/models/list_accounts200_response.rb +2 -2
- data/lib/postboost/models/list_agent_proposals200_response.rb +239 -0
- data/lib/postboost/models/list_agent_runs200_response.rb +239 -0
- data/lib/postboost/models/list_agents200_response.rb +223 -0
- data/lib/postboost/models/list_api_activity200_response.rb +241 -0
- data/lib/postboost/models/list_api_keys200_response.rb +223 -0
- data/lib/postboost/models/list_competitors200_response.rb +223 -0
- data/lib/postboost/models/list_hashtag_groups200_response.rb +248 -0
- data/lib/postboost/models/list_inbox_conversations200_response.rb +241 -0
- data/lib/postboost/models/list_inbox_reply_drafts200_response.rb +241 -0
- data/lib/postboost/models/list_media200_response.rb +2 -2
- data/lib/postboost/models/list_media_folders200_response.rb +216 -0
- data/lib/postboost/models/list_mentions200_response.rb +241 -0
- data/lib/postboost/models/list_my_workspaces200_response.rb +216 -0
- data/lib/postboost/models/list_posts200_response.rb +2 -2
- data/lib/postboost/models/list_receipts200_response.rb +2 -2
- data/lib/postboost/models/list_recycling_rules200_response.rb +223 -0
- data/lib/postboost/models/list_recycling_runs200_response.rb +223 -0
- data/lib/postboost/models/list_report_exports200_response.rb +223 -0
- data/lib/postboost/models/list_reseller_clients200_response.rb +239 -0
- data/lib/postboost/models/list_rss_feeds200_response.rb +223 -0
- data/lib/postboost/models/list_tags200_response.rb +2 -2
- data/lib/postboost/models/list_templates200_response.rb +248 -0
- data/lib/postboost/models/list_users200_response.rb +2 -2
- data/lib/postboost/models/list_webhook_subscriptions200_response.rb +223 -0
- data/lib/postboost/models/list_workspaces200_response.rb +2 -2
- data/lib/postboost/models/media.rb +128 -3
- data/lib/postboost/models/media_base64_input.rb +295 -0
- data/lib/postboost/models/media_folder.rb +271 -0
- data/lib/postboost/models/media_folder_input.rb +244 -0
- data/lib/postboost/models/media_folder_ref.rb +237 -0
- data/lib/postboost/models/mention.rb +290 -0
- data/lib/postboost/models/mention_identity.rb +257 -0
- data/lib/postboost/models/mention_identity_input.rb +325 -0
- data/lib/postboost/models/mention_input.rb +279 -0
- data/lib/postboost/models/message_only.rb +221 -0
- data/lib/postboost/models/pagination_meta.rb +2 -2
- data/lib/postboost/models/pagination_meta_links.rb +4 -2
- data/lib/postboost/models/pagination_meta_meta.rb +4 -2
- data/lib/postboost/models/poll_rss_feed200_response.rb +255 -0
- data/lib/postboost/models/post.rb +69 -3
- data/lib/postboost/models/post_analytics.rb +252 -0
- data/lib/postboost/models/post_content.rb +4 -3
- data/lib/postboost/models/post_input.rb +41 -6
- data/lib/postboost/models/post_options_instagram.rb +294 -0
- data/lib/postboost/models/post_options_tik_tok.rb +329 -0
- data/lib/postboost/models/post_options_youtube.rb +302 -0
- data/lib/postboost/models/post_status.rb +6 -3
- data/lib/postboost/models/post_version.rb +53 -5
- data/lib/postboost/models/post_version_options.rb +242 -0
- data/lib/postboost/models/posting_schedule.rb +303 -0
- data/lib/postboost/models/posting_schedule_day.rb +285 -0
- data/lib/postboost/models/posting_schedule_day_times_inner.rb +222 -0
- data/lib/postboost/models/posting_schedule_input.rb +312 -0
- data/lib/postboost/models/posting_time_slot.rb +315 -0
- data/lib/postboost/models/posting_times.rb +362 -0
- data/lib/postboost/models/posting_times_best_inner.rb +269 -0
- data/lib/postboost/models/posting_times_day_intervals_inner_inner.rb +370 -0
- data/lib/postboost/models/posting_times_days_inner.rb +366 -0
- data/lib/postboost/models/preflight_result.rb +291 -0
- data/lib/postboost/models/public_workspace.rb +262 -0
- data/lib/postboost/models/public_workspace_pivot.rb +267 -0
- data/lib/postboost/models/publish_progress.rb +254 -0
- data/lib/postboost/models/queue_slots.rb +237 -0
- data/lib/postboost/models/receipt.rb +58 -2
- data/lib/postboost/models/receipt_input.rb +2 -2
- data/lib/postboost/models/receipt_update_input.rb +2 -2
- data/lib/postboost/models/recommended_posting_times.rb +282 -0
- data/lib/postboost/models/reconnect_link.rb +254 -0
- data/lib/postboost/models/recycling_rule.rb +434 -0
- data/lib/postboost/models/recycling_rule_input.rb +435 -0
- data/lib/postboost/models/recycling_rule_settings.rb +381 -0
- data/lib/postboost/models/recycling_rule_update.rb +366 -0
- data/lib/postboost/models/recycling_run.rb +320 -0
- data/lib/postboost/models/remove_generic_subscription422_response.rb +214 -0
- data/lib/postboost/models/remove_user_from_workspace_request.rb +2 -2
- data/lib/postboost/models/report_branding.rb +285 -0
- data/lib/postboost/models/report_branding_input.rb +293 -0
- data/lib/postboost/models/report_export.rb +442 -0
- data/lib/postboost/models/report_export_input.rb +350 -0
- data/lib/postboost/models/repurpose_content200_response.rb +237 -0
- data/lib/postboost/models/repurpose_input.rb +667 -0
- data/lib/postboost/models/repurpose_input_theme.rb +296 -0
- data/lib/postboost/models/repurpose_result.rb +328 -0
- data/lib/postboost/models/repurpose_result_media.rb +224 -0
- data/lib/postboost/models/repurpose_result_source.rb +283 -0
- data/lib/postboost/models/repurpose_slide.rb +239 -0
- data/lib/postboost/models/reseller_client.rb +360 -0
- data/lib/postboost/models/reseller_client_input.rb +240 -0
- data/lib/postboost/models/reseller_client_usage.rb +239 -0
- data/lib/postboost/models/retry_post_account_result.rb +275 -0
- data/lib/postboost/models/rss_feed.rb +402 -0
- data/lib/postboost/models/rss_feed_input.rb +433 -0
- data/lib/postboost/models/rss_feed_update.rb +396 -0
- data/lib/postboost/models/run_agent202_response.rb +221 -0
- data/lib/postboost/models/schedule_post_request.rb +48 -6
- data/lib/postboost/models/schedule_result.rb +23 -6
- data/lib/postboost/models/subscription.rb +37 -2
- data/lib/postboost/models/subscription_input.rb +2 -2
- data/lib/postboost/models/subscription_status.rb +2 -2
- data/lib/postboost/models/subscription_update_input.rb +2 -2
- data/lib/postboost/models/tag.rb +30 -2
- data/lib/postboost/models/tag_input.rb +2 -2
- data/lib/postboost/models/template.rb +256 -0
- data/lib/postboost/models/template_content_item.rb +240 -0
- data/lib/postboost/models/template_input.rb +271 -0
- data/lib/postboost/models/template_input_content_inner.rb +227 -0
- data/lib/postboost/models/update_media_request.rb +61 -11
- data/lib/postboost/models/{upload_chunk200_response.rb → upload_chunk201_response.rb} +5 -5
- data/lib/postboost/models/user.rb +48 -3
- data/lib/postboost/models/user_input.rb +2 -2
- data/lib/postboost/models/user_update_input.rb +2 -2
- data/lib/postboost/models/webhook_event_name.rb +50 -0
- data/lib/postboost/models/webhook_event_payload.rb +262 -0
- data/lib/postboost/models/webhook_subscription.rb +297 -0
- data/lib/postboost/models/webhook_subscription_input.rb +349 -0
- data/lib/postboost/models/workspace.rb +42 -3
- data/lib/postboost/models/workspace_agent.rb +381 -0
- data/lib/postboost/models/workspace_agent_input.rb +326 -0
- data/lib/postboost/models/workspace_agent_settings.rb +340 -0
- data/lib/postboost/models/workspace_agent_update.rb +294 -0
- data/lib/postboost/models/workspace_input.rb +3 -9
- data/lib/postboost/models/workspace_user_input.rb +2 -2
- data/lib/postboost/models/x_usage.rb +303 -0
- data/lib/postboost/models/x_usage_counter.rb +234 -0
- data/lib/postboost/version.rb +3 -3
- data/lib/postboost.rb +219 -6
- data/postboost.gemspec +3 -3
- data/spec/api/account_groups_api_spec.rb +102 -0
- data/spec/api/accounts_api_spec.rb +46 -3
- data/spec/api/activity_api_spec.rb +51 -0
- data/spec/api/agents_api_spec.rb +170 -0
- data/spec/api/ai_api_spec.rb +189 -0
- data/spec/api/analytics_api_spec.rb +201 -0
- data/spec/api/competitors_api_spec.rb +87 -0
- data/spec/api/hashtag_groups_api_spec.rb +102 -0
- data/spec/api/inbox_api_spec.rb +178 -0
- data/spec/api/media_api_spec.rb +92 -11
- data/spec/api/mentions_api_spec.rb +104 -0
- data/spec/api/posting_schedule_api_spec.rb +102 -0
- data/spec/api/posts_api_spec.rb +224 -6
- data/spec/api/receipts_api_spec.rb +9 -2
- data/spec/api/subscriptions_api_spec.rb +12 -2
- data/spec/api/tags_api_spec.rb +8 -2
- data/spec/api/templates_api_spec.rb +102 -0
- data/spec/api/users_api_spec.rb +9 -2
- data/spec/api/webhooks_api_spec.rb +73 -0
- data/spec/api/workspaces_api_spec.rb +108 -2
- data/spec/models/account_analytics_initial_sync_spec.rb +42 -0
- data/spec/models/account_analytics_spec.rb +66 -0
- data/spec/models/account_connection_health_spec.rb +92 -0
- data/spec/models/account_errors_inner_one_of_spec.rb +54 -0
- data/spec/models/account_errors_inner_spec.rb +32 -0
- data/spec/models/account_group_input_spec.rb +42 -0
- data/spec/models/account_group_spec.rb +54 -0
- data/spec/models/account_health_daily_cap_spec.rb +42 -0
- data/spec/models/account_health_spec.rb +84 -0
- data/spec/models/account_schedule_spec.rb +48 -0
- data/spec/models/account_spec.rb +36 -2
- data/spec/models/add_competitor202_response_spec.rb +46 -0
- data/spec/models/add_competitor409_response_spec.rb +42 -0
- data/spec/models/add_generic_subscription_request_spec.rb +2 -2
- data/spec/models/add_post_to_queue_request_spec.rb +36 -0
- data/spec/models/agent_page_meta_spec.rb +54 -0
- data/spec/models/agent_proposal_decision_spec.rb +36 -0
- data/spec/models/agent_proposal_spec.rb +126 -0
- data/spec/models/agent_run_spec.rb +122 -0
- data/spec/models/ai_credits_spec.rb +48 -0
- data/spec/models/ai_usage_spec.rb +42 -0
- data/spec/models/ai_usage_text_spec.rb +54 -0
- data/spec/models/analytics_period_spec.rb +54 -0
- data/spec/models/analytics_summary_data_spec.rb +96 -0
- data/spec/models/analytics_summary_spec.rb +42 -0
- data/spec/models/api_activity_outcome_spec.rb +30 -0
- data/spec/models/api_activity_spec.rb +90 -0
- data/spec/models/api_key_ability_spec.rb +30 -0
- data/spec/models/api_key_input_spec.rb +54 -0
- data/spec/models/api_key_spec.rb +78 -0
- data/spec/models/approve_agent_proposal200_response_spec.rb +36 -0
- data/spec/models/approve_agent_proposal409_response_spec.rb +42 -0
- data/spec/models/approve_inbox_reply_draft403_response_spec.rb +46 -0
- data/spec/models/approve_post_request_spec.rb +54 -0
- data/spec/models/best_posting_times_spec.rb +42 -0
- data/spec/models/best_posting_times_times_inner_spec.rb +54 -0
- data/spec/models/blog_to_social200_response_spec.rb +42 -0
- data/spec/models/blog_to_social429_response_spec.rb +36 -0
- data/spec/models/blog_to_social_caption_spec.rb +66 -0
- data/spec/models/blog_to_social_input_spec.rb +134 -0
- data/spec/models/blog_to_social_media_spec.rb +42 -0
- data/spec/models/blog_to_social_response_spec.rb +72 -0
- data/spec/models/brand_voice_input_spec.rb +128 -0
- data/spec/models/brand_voice_meta_spec.rb +36 -0
- data/spec/models/brand_voice_spec.rb +134 -0
- data/spec/models/cancel_subscription422_response_errors_spec.rb +36 -0
- data/spec/models/cancel_subscription422_response_spec.rb +42 -0
- data/spec/models/cancel_subscription_request_spec.rb +36 -0
- data/spec/models/change_subscription_plan_request_spec.rb +2 -2
- data/spec/models/channel_account_spec.rb +94 -0
- data/spec/models/checkout_subscription200_response_spec.rb +2 -2
- data/spec/models/checkout_subscription_request_spec.rb +2 -2
- data/spec/models/coded_error_spec.rb +48 -0
- data/spec/models/competitor_detail_spec.rb +96 -0
- data/spec/models/competitor_input_spec.rb +42 -0
- data/spec/models/competitor_media_spec.rb +66 -0
- data/spec/models/competitor_snapshot_spec.rb +48 -0
- data/spec/models/competitor_spec.rb +84 -0
- data/spec/models/complete_chunked_upload_request_spec.rb +42 -0
- data/spec/models/connect_channel_input_spec.rb +54 -0
- data/spec/models/create_account_group201_response_spec.rb +36 -0
- data/spec/models/create_agent201_response_spec.rb +36 -0
- data/spec/models/create_api_key201_response_data_spec.rb +84 -0
- data/spec/models/create_api_key201_response_spec.rb +36 -0
- data/spec/models/create_hashtag_group201_response_spec.rb +36 -0
- data/spec/models/create_inbox_reply_draft201_response_spec.rb +36 -0
- data/spec/models/create_media_folder_request_spec.rb +42 -0
- data/spec/models/create_mention201_response_spec.rb +36 -0
- data/spec/models/create_recycling_rule201_response_spec.rb +36 -0
- data/spec/models/create_report_export201_response_spec.rb +36 -0
- data/spec/models/create_reseller_client201_response_spec.rb +36 -0
- data/spec/models/create_rss_feed201_response_spec.rb +36 -0
- data/spec/models/create_template201_response_spec.rb +36 -0
- data/spec/models/create_webhook_subscription201_response_data_spec.rb +72 -0
- data/spec/models/create_webhook_subscription201_response_spec.rb +36 -0
- data/spec/models/delete_agent200_response_spec.rb +36 -0
- data/spec/models/delete_media_bulk_request_items_inner_spec.rb +32 -0
- data/spec/models/delete_media_bulk_request_spec.rb +2 -2
- data/spec/models/delete_media_folder_request_spec.rb +36 -0
- data/spec/models/delete_mode_spec.rb +2 -2
- data/spec/models/delete_post_request_spec.rb +2 -2
- data/spec/models/delete_posts_bulk_request_spec.rb +2 -2
- data/spec/models/delete_receipts_bulk_request_spec.rb +2 -2
- data/spec/models/delete_result_spec.rb +2 -2
- data/spec/models/delete_user400_response_spec.rb +2 -2
- data/spec/models/delete_users_bulk_request_spec.rb +2 -2
- data/spec/models/delete_workspaces_bulk_request_spec.rb +2 -2
- data/spec/models/get_account_health200_response_spec.rb +36 -0
- data/spec/models/get_brand_voice200_response_spec.rb +36 -0
- data/spec/models/get_competitor200_response_spec.rb +36 -0
- data/spec/models/get_inbox_conversation200_response_spec.rb +36 -0
- data/spec/models/get_posting_schedule200_response_spec.rb +36 -0
- data/spec/models/get_remote_upload_status200_response_spec.rb +2 -2
- data/spec/models/get_report_branding200_response_spec.rb +36 -0
- data/spec/models/guardrail_error_spec.rb +70 -0
- data/spec/models/hashtag_group_input_spec.rb +42 -0
- data/spec/models/hashtag_group_spec.rb +48 -0
- data/spec/models/image_alt_text200_response_spec.rb +36 -0
- data/spec/models/image_alt_text_input_spec.rb +36 -0
- data/spec/models/image_alt_text_response_spec.rb +54 -0
- data/spec/models/image_credit_balance_spec.rb +66 -0
- data/spec/models/image_edit_input_spec.rb +80 -0
- data/spec/models/image_generate200_response_spec.rb +42 -0
- data/spec/models/image_generate429_response_spec.rb +36 -0
- data/spec/models/image_generate_input_spec.rb +108 -0
- data/spec/models/image_generation_response_spec.rb +72 -0
- data/spec/models/image_prompt200_response_spec.rb +42 -0
- data/spec/models/image_prompt429_response_spec.rb +36 -0
- data/spec/models/image_prompt_input_spec.rb +76 -0
- data/spec/models/image_prompt_response_spec.rb +36 -0
- data/spec/models/image_variations200_response_spec.rb +36 -0
- data/spec/models/image_variations_input_spec.rb +62 -0
- data/spec/models/image_variations_response_spec.rb +60 -0
- data/spec/models/inbox_author_spec.rb +48 -0
- data/spec/models/inbox_conversation_account_spec.rb +54 -0
- data/spec/models/inbox_conversation_spec.rb +128 -0
- data/spec/models/inbox_conversation_update_spec.rb +46 -0
- data/spec/models/inbox_message_author_spec.rb +48 -0
- data/spec/models/inbox_message_spec.rb +90 -0
- data/spec/models/inbox_reply_draft_approve_spec.rb +36 -0
- data/spec/models/inbox_reply_draft_edit_spec.rb +36 -0
- data/spec/models/inbox_reply_draft_input_spec.rb +42 -0
- data/spec/models/inbox_reply_draft_spec.rb +116 -0
- data/spec/models/initiate_chunked_upload201_response_spec.rb +48 -0
- data/spec/models/initiate_chunked_upload_request_spec.rb +2 -2
- data/spec/models/initiate_remote_upload201_response_one_of_spec.rb +36 -0
- data/spec/models/initiate_remote_upload201_response_spec.rb +32 -0
- data/spec/models/initiate_remote_upload_request_spec.rb +8 -2
- data/spec/models/learn_brand_voice_input_spec.rb +54 -0
- data/spec/models/learn_brand_voice_response_meta_spec.rb +60 -0
- data/spec/models/learn_brand_voice_response_spec.rb +42 -0
- data/spec/models/list_account_groups200_response_spec.rb +48 -0
- data/spec/models/list_accounts200_response_spec.rb +2 -2
- data/spec/models/list_agent_proposals200_response_spec.rb +42 -0
- data/spec/models/list_agent_runs200_response_spec.rb +42 -0
- data/spec/models/list_agents200_response_spec.rb +36 -0
- data/spec/models/list_api_activity200_response_spec.rb +48 -0
- data/spec/models/list_api_keys200_response_spec.rb +36 -0
- data/spec/models/list_competitors200_response_spec.rb +36 -0
- data/spec/models/list_hashtag_groups200_response_spec.rb +48 -0
- data/spec/models/list_inbox_conversations200_response_spec.rb +48 -0
- data/spec/models/list_inbox_reply_drafts200_response_spec.rb +48 -0
- data/spec/models/list_media200_response_spec.rb +2 -2
- data/spec/models/list_media_folders200_response_spec.rb +36 -0
- data/spec/models/list_mentions200_response_spec.rb +48 -0
- data/spec/models/list_my_workspaces200_response_spec.rb +36 -0
- data/spec/models/list_posts200_response_spec.rb +2 -2
- data/spec/models/list_receipts200_response_spec.rb +2 -2
- data/spec/models/list_recycling_rules200_response_spec.rb +36 -0
- data/spec/models/list_recycling_runs200_response_spec.rb +36 -0
- data/spec/models/list_report_exports200_response_spec.rb +36 -0
- data/spec/models/list_reseller_clients200_response_spec.rb +42 -0
- data/spec/models/list_rss_feeds200_response_spec.rb +36 -0
- data/spec/models/list_tags200_response_spec.rb +2 -2
- data/spec/models/list_templates200_response_spec.rb +48 -0
- data/spec/models/list_users200_response_spec.rb +2 -2
- data/spec/models/list_webhook_subscriptions200_response_spec.rb +36 -0
- data/spec/models/list_workspaces200_response_spec.rb +2 -2
- data/spec/models/media_base64_input_spec.rb +54 -0
- data/spec/models/media_folder_input_spec.rb +42 -0
- data/spec/models/media_folder_ref_spec.rb +42 -0
- data/spec/models/media_folder_spec.rb +54 -0
- data/spec/models/media_spec.rb +44 -2
- data/spec/models/mention_identity_input_spec.rb +60 -0
- data/spec/models/mention_identity_spec.rb +54 -0
- data/spec/models/mention_input_spec.rb +48 -0
- data/spec/models/mention_spec.rb +66 -0
- data/spec/models/message_only_spec.rb +36 -0
- data/spec/models/pagination_meta_links_spec.rb +2 -2
- data/spec/models/pagination_meta_meta_spec.rb +2 -2
- data/spec/models/pagination_meta_spec.rb +2 -2
- data/spec/models/poll_rss_feed200_response_spec.rb +48 -0
- data/spec/models/post_analytics_spec.rb +48 -0
- data/spec/models/post_content_spec.rb +2 -2
- data/spec/models/post_input_spec.rb +20 -2
- data/spec/models/post_options_instagram_spec.rb +52 -0
- data/spec/models/post_options_tik_tok_spec.rb +88 -0
- data/spec/models/post_options_youtube_spec.rb +58 -0
- data/spec/models/post_spec.rb +8 -2
- data/spec/models/post_status_spec.rb +2 -2
- data/spec/models/post_version_options_spec.rb +54 -0
- data/spec/models/post_version_spec.rb +8 -2
- data/spec/models/posting_schedule_day_spec.rb +48 -0
- data/spec/models/posting_schedule_day_times_inner_spec.rb +36 -0
- data/spec/models/posting_schedule_input_spec.rb +54 -0
- data/spec/models/posting_schedule_spec.rb +66 -0
- data/spec/models/posting_time_slot_spec.rb +52 -0
- data/spec/models/posting_times_best_inner_spec.rb +54 -0
- data/spec/models/posting_times_day_intervals_inner_inner_spec.rb +70 -0
- data/spec/models/posting_times_days_inner_spec.rb +58 -0
- data/spec/models/posting_times_spec.rb +78 -0
- data/spec/models/preflight_result_spec.rb +60 -0
- data/spec/models/public_workspace_pivot_spec.rb +52 -0
- data/spec/models/public_workspace_spec.rb +54 -0
- data/spec/models/publish_progress_spec.rb +48 -0
- data/spec/models/queue_slots_spec.rb +42 -0
- data/spec/models/receipt_input_spec.rb +2 -2
- data/spec/models/receipt_spec.rb +2 -2
- data/spec/models/receipt_update_input_spec.rb +2 -2
- data/spec/models/recommended_posting_times_spec.rb +60 -0
- data/spec/models/reconnect_link_spec.rb +48 -0
- data/spec/models/recycling_rule_input_spec.rb +92 -0
- data/spec/models/recycling_rule_settings_spec.rb +70 -0
- data/spec/models/recycling_rule_spec.rb +116 -0
- data/spec/models/recycling_rule_update_spec.rb +70 -0
- data/spec/models/recycling_run_spec.rb +70 -0
- data/spec/models/remove_generic_subscription422_response_spec.rb +36 -0
- data/spec/models/remove_user_from_workspace_request_spec.rb +2 -2
- data/spec/models/report_branding_input_spec.rb +54 -0
- data/spec/models/report_branding_spec.rb +66 -0
- data/spec/models/report_export_input_spec.rb +78 -0
- data/spec/models/report_export_spec.rb +120 -0
- data/spec/models/repurpose_content200_response_spec.rb +42 -0
- data/spec/models/repurpose_input_spec.rb +164 -0
- data/spec/models/repurpose_input_theme_spec.rb +48 -0
- data/spec/models/repurpose_result_media_spec.rb +42 -0
- data/spec/models/repurpose_result_source_spec.rb +52 -0
- data/spec/models/repurpose_result_spec.rb +78 -0
- data/spec/models/repurpose_slide_spec.rb +42 -0
- data/spec/models/reseller_client_input_spec.rb +36 -0
- data/spec/models/reseller_client_spec.rb +82 -0
- data/spec/models/reseller_client_usage_spec.rb +42 -0
- data/spec/models/retry_post_account_result_spec.rb +48 -0
- data/spec/models/rss_feed_input_spec.rb +76 -0
- data/spec/models/rss_feed_spec.rb +100 -0
- data/spec/models/rss_feed_update_spec.rb +76 -0
- data/spec/models/run_agent202_response_spec.rb +36 -0
- data/spec/models/schedule_post_request_spec.rb +26 -2
- data/spec/models/schedule_result_spec.rb +8 -2
- data/spec/models/subscription_input_spec.rb +2 -2
- data/spec/models/subscription_spec.rb +2 -2
- data/spec/models/subscription_status_spec.rb +2 -2
- data/spec/models/subscription_update_input_spec.rb +2 -2
- data/spec/models/tag_input_spec.rb +2 -2
- data/spec/models/tag_spec.rb +2 -2
- data/spec/models/template_content_item_spec.rb +42 -0
- data/spec/models/template_input_content_inner_spec.rb +42 -0
- data/spec/models/template_input_spec.rb +42 -0
- data/spec/models/template_spec.rb +48 -0
- data/spec/models/update_media_request_spec.rb +14 -2
- data/spec/models/upload_chunk201_response_spec.rb +36 -0
- data/spec/models/user_input_spec.rb +2 -2
- data/spec/models/user_spec.rb +8 -2
- data/spec/models/user_update_input_spec.rb +2 -2
- data/spec/models/webhook_event_name_spec.rb +30 -0
- data/spec/models/webhook_event_payload_spec.rb +42 -0
- data/spec/models/webhook_subscription_input_spec.rb +58 -0
- data/spec/models/webhook_subscription_spec.rb +66 -0
- data/spec/models/workspace_agent_input_spec.rb +68 -0
- data/spec/models/workspace_agent_settings_spec.rb +60 -0
- data/spec/models/workspace_agent_spec.rb +92 -0
- data/spec/models/workspace_agent_update_spec.rb +58 -0
- data/spec/models/workspace_input_spec.rb +2 -2
- data/spec/models/workspace_spec.rb +8 -2
- data/spec/models/workspace_user_input_spec.rb +2 -2
- data/spec/models/x_usage_counter_spec.rb +42 -0
- data/spec/models/x_usage_spec.rb +66 -0
- data/spec/spec_helper.rb +2 -2
- metadata +943 -76
- data/git_push.sh +0 -57
- data/spec/models/initiate_chunked_upload200_response_spec.rb +0 -48
- data/spec/models/initiate_remote_upload200_response_one_of_spec.rb +0 -36
- data/spec/models/initiate_remote_upload200_response_spec.rb +0 -32
- data/spec/models/upload_chunk200_response_spec.rb +0 -36
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#PostBoost API
|
|
3
3
|
|
|
4
|
-
#The PostBoost REST API lets you publish, schedule, and analyze social media posts across
|
|
4
|
+
#The PostBoost REST API lets you publish, schedule, and analyze social media posts across 12+ platforms from a single integration. No OAuth apps to maintain — PostBoost handles platform authorization for you. ## Base URL All workspace-scoped endpoints are prefixed with `/{workspaceUuid}`. Panel/admin endpoints are prefixed with `/panel`. ## Plan access Every workspace-scoped endpoint returns `403` when the workspace's plan does not include API access (capability `api`). ## Dates and times Post dates and times (`date`, `time`, `accounts_schedule`) are read in the request's `timezone` when one is given, otherwise in the workspace timezone. ## Idempotent requests Send an `Idempotency-Key` header (any unique string, for example a UUID) with a `POST`. Repeating the request with the same key within 24 hours returns the stored response with `Idempotent-Replayed: true` and creates nothing new. Reusing a key with a different body returns `422`; a request still in progress with the same key returns `409`. `5xx` and `429` responses are not stored, so they can be retried with the same key. ## Guardrails for automated clients Create and update requests are checked before anything is written: a post whose content matches one created for the same account in the last 24 hours returns `409` (`code: duplicate_post`, override with `allow_duplicate: true`), scheduling past an account's daily cap returns `429` (`code: account_daily_cap_reached`), and scheduling to an account that must be reconnected returns `422` (`code: account_unauthorized` or `account_token_missing`). Use `POST /{workspaceUuid}/posts/validate` for a dry run and `GET /{workspaceUuid}/activity` to review what API clients did. ## Authentication All requests require a Bearer token in the `Authorization` header. Generate tokens in your PostBoost dashboard under **Settings → Access Tokens**. ``` Authorization: Bearer YOUR_API_TOKEN ```
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 1.
|
|
6
|
+
The version of the OpenAPI document: 1.14.0
|
|
7
7
|
Contact: hi@postboost.co
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.9.0
|
|
@@ -89,10 +89,11 @@ module PostBoost
|
|
|
89
89
|
end
|
|
90
90
|
|
|
91
91
|
# Complete chunked upload
|
|
92
|
-
# Signal that all chunks have been uploaded. Returns the final media object.
|
|
92
|
+
# Signal that all chunks have been uploaded. Returns the final media object. A video may come back with `is_processing` set to `true` while its conversion runs.
|
|
93
93
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
94
94
|
# @param upload_uuid [String]
|
|
95
95
|
# @param [Hash] opts the optional parameters
|
|
96
|
+
# @option opts [CompleteChunkedUploadRequest] :complete_chunked_upload_request
|
|
96
97
|
# @return [Media]
|
|
97
98
|
def complete_chunked_upload(workspace_uuid, upload_uuid, opts = {})
|
|
98
99
|
data, _status_code, _headers = complete_chunked_upload_with_http_info(workspace_uuid, upload_uuid, opts)
|
|
@@ -100,10 +101,11 @@ module PostBoost
|
|
|
100
101
|
end
|
|
101
102
|
|
|
102
103
|
# Complete chunked upload
|
|
103
|
-
# Signal that all chunks have been uploaded. Returns the final media object.
|
|
104
|
+
# Signal that all chunks have been uploaded. Returns the final media object. A video may come back with `is_processing` set to `true` while its conversion runs.
|
|
104
105
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
105
106
|
# @param upload_uuid [String]
|
|
106
107
|
# @param [Hash] opts the optional parameters
|
|
108
|
+
# @option opts [CompleteChunkedUploadRequest] :complete_chunked_upload_request
|
|
107
109
|
# @return [Array<(Media, Integer, Hash)>] Media data, response status code and response headers
|
|
108
110
|
def complete_chunked_upload_with_http_info(workspace_uuid, upload_uuid, opts = {})
|
|
109
111
|
if @api_client.config.debugging
|
|
@@ -127,12 +129,17 @@ module PostBoost
|
|
|
127
129
|
header_params = opts[:header_params] || {}
|
|
128
130
|
# HTTP header 'Accept' (if needed)
|
|
129
131
|
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
132
|
+
# HTTP header 'Content-Type'
|
|
133
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
134
|
+
if !content_type.nil?
|
|
135
|
+
header_params['Content-Type'] = content_type
|
|
136
|
+
end
|
|
130
137
|
|
|
131
138
|
# form parameters
|
|
132
139
|
form_params = opts[:form_params] || {}
|
|
133
140
|
|
|
134
141
|
# http body (model)
|
|
135
|
-
post_body = opts[:debug_body]
|
|
142
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'complete_chunked_upload_request'])
|
|
136
143
|
|
|
137
144
|
# return_type
|
|
138
145
|
return_type = opts[:debug_return_type] || 'Media'
|
|
@@ -157,8 +164,93 @@ module PostBoost
|
|
|
157
164
|
return data, status_code, headers
|
|
158
165
|
end
|
|
159
166
|
|
|
167
|
+
# Create media folder
|
|
168
|
+
# Creates a folder at the top level or under `parent`. The name must be unique among its siblings.
|
|
169
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
170
|
+
# @param create_media_folder_request [CreateMediaFolderRequest]
|
|
171
|
+
# @param [Hash] opts the optional parameters
|
|
172
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
173
|
+
# @return [MediaFolder]
|
|
174
|
+
def create_media_folder(workspace_uuid, create_media_folder_request, opts = {})
|
|
175
|
+
data, _status_code, _headers = create_media_folder_with_http_info(workspace_uuid, create_media_folder_request, opts)
|
|
176
|
+
data
|
|
177
|
+
end
|
|
178
|
+
|
|
179
|
+
# Create media folder
|
|
180
|
+
# Creates a folder at the top level or under `parent`. The name must be unique among its siblings.
|
|
181
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
182
|
+
# @param create_media_folder_request [CreateMediaFolderRequest]
|
|
183
|
+
# @param [Hash] opts the optional parameters
|
|
184
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
185
|
+
# @return [Array<(MediaFolder, Integer, Hash)>] MediaFolder data, response status code and response headers
|
|
186
|
+
def create_media_folder_with_http_info(workspace_uuid, create_media_folder_request, opts = {})
|
|
187
|
+
if @api_client.config.debugging
|
|
188
|
+
@api_client.config.logger.debug 'Calling API: MediaApi.create_media_folder ...'
|
|
189
|
+
end
|
|
190
|
+
# verify the required parameter 'workspace_uuid' is set
|
|
191
|
+
if @api_client.config.client_side_validation && workspace_uuid.nil?
|
|
192
|
+
fail ArgumentError, "Missing the required parameter 'workspace_uuid' when calling MediaApi.create_media_folder"
|
|
193
|
+
end
|
|
194
|
+
# verify the required parameter 'create_media_folder_request' is set
|
|
195
|
+
if @api_client.config.client_side_validation && create_media_folder_request.nil?
|
|
196
|
+
fail ArgumentError, "Missing the required parameter 'create_media_folder_request' when calling MediaApi.create_media_folder"
|
|
197
|
+
end
|
|
198
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
|
|
199
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.create_media_folder, the character length must be smaller than or equal to 255.'
|
|
200
|
+
end
|
|
201
|
+
|
|
202
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
|
|
203
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.create_media_folder, the character length must be great than or equal to 1.'
|
|
204
|
+
end
|
|
205
|
+
|
|
206
|
+
# resource path
|
|
207
|
+
local_var_path = '/{workspaceUuid}/media/folders'.sub('{' + 'workspaceUuid' + '}', CGI.escape(workspace_uuid.to_s))
|
|
208
|
+
|
|
209
|
+
# query parameters
|
|
210
|
+
query_params = opts[:query_params] || {}
|
|
211
|
+
|
|
212
|
+
# header parameters
|
|
213
|
+
header_params = opts[:header_params] || {}
|
|
214
|
+
# HTTP header 'Accept' (if needed)
|
|
215
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
216
|
+
# HTTP header 'Content-Type'
|
|
217
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
218
|
+
if !content_type.nil?
|
|
219
|
+
header_params['Content-Type'] = content_type
|
|
220
|
+
end
|
|
221
|
+
header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
|
|
222
|
+
|
|
223
|
+
# form parameters
|
|
224
|
+
form_params = opts[:form_params] || {}
|
|
225
|
+
|
|
226
|
+
# http body (model)
|
|
227
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(create_media_folder_request)
|
|
228
|
+
|
|
229
|
+
# return_type
|
|
230
|
+
return_type = opts[:debug_return_type] || 'MediaFolder'
|
|
231
|
+
|
|
232
|
+
# auth_names
|
|
233
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
234
|
+
|
|
235
|
+
new_options = opts.merge(
|
|
236
|
+
:operation => :"MediaApi.create_media_folder",
|
|
237
|
+
:header_params => header_params,
|
|
238
|
+
:query_params => query_params,
|
|
239
|
+
:form_params => form_params,
|
|
240
|
+
:body => post_body,
|
|
241
|
+
:auth_names => auth_names,
|
|
242
|
+
:return_type => return_type
|
|
243
|
+
)
|
|
244
|
+
|
|
245
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
246
|
+
if @api_client.config.debugging
|
|
247
|
+
@api_client.config.logger.debug "API called: MediaApi#create_media_folder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
248
|
+
end
|
|
249
|
+
return data, status_code, headers
|
|
250
|
+
end
|
|
251
|
+
|
|
160
252
|
# Delete media (bulk)
|
|
161
|
-
# Delete one or more media items by their IDs.
|
|
253
|
+
# Delete one or more media items by their numeric IDs or UUIDs (both may be mixed, up to 500 per request).
|
|
162
254
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
163
255
|
# @param delete_media_bulk_request [DeleteMediaBulkRequest]
|
|
164
256
|
# @param [Hash] opts the optional parameters
|
|
@@ -169,7 +261,7 @@ module PostBoost
|
|
|
169
261
|
end
|
|
170
262
|
|
|
171
263
|
# Delete media (bulk)
|
|
172
|
-
# Delete one or more media items by their IDs.
|
|
264
|
+
# Delete one or more media items by their numeric IDs or UUIDs (both may be mixed, up to 500 per request).
|
|
173
265
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
174
266
|
# @param delete_media_bulk_request [DeleteMediaBulkRequest]
|
|
175
267
|
# @param [Hash] opts the optional parameters
|
|
@@ -231,6 +323,82 @@ module PostBoost
|
|
|
231
323
|
return data, status_code, headers
|
|
232
324
|
end
|
|
233
325
|
|
|
326
|
+
# Delete media folder
|
|
327
|
+
# Deletes a folder. By default its media and sub-folders move up to the folder's parent; with `delete_media` set to true every media item below the folder is deleted as well.
|
|
328
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
329
|
+
# @param folder_uuid [String] UUID of the media folder.
|
|
330
|
+
# @param [Hash] opts the optional parameters
|
|
331
|
+
# @option opts [DeleteMediaFolderRequest] :delete_media_folder_request
|
|
332
|
+
# @return [Object]
|
|
333
|
+
def delete_media_folder(workspace_uuid, folder_uuid, opts = {})
|
|
334
|
+
data, _status_code, _headers = delete_media_folder_with_http_info(workspace_uuid, folder_uuid, opts)
|
|
335
|
+
data
|
|
336
|
+
end
|
|
337
|
+
|
|
338
|
+
# Delete media folder
|
|
339
|
+
# Deletes a folder. By default its media and sub-folders move up to the folder's parent; with `delete_media` set to true every media item below the folder is deleted as well.
|
|
340
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
341
|
+
# @param folder_uuid [String] UUID of the media folder.
|
|
342
|
+
# @param [Hash] opts the optional parameters
|
|
343
|
+
# @option opts [DeleteMediaFolderRequest] :delete_media_folder_request
|
|
344
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
|
345
|
+
def delete_media_folder_with_http_info(workspace_uuid, folder_uuid, opts = {})
|
|
346
|
+
if @api_client.config.debugging
|
|
347
|
+
@api_client.config.logger.debug 'Calling API: MediaApi.delete_media_folder ...'
|
|
348
|
+
end
|
|
349
|
+
# verify the required parameter 'workspace_uuid' is set
|
|
350
|
+
if @api_client.config.client_side_validation && workspace_uuid.nil?
|
|
351
|
+
fail ArgumentError, "Missing the required parameter 'workspace_uuid' when calling MediaApi.delete_media_folder"
|
|
352
|
+
end
|
|
353
|
+
# verify the required parameter 'folder_uuid' is set
|
|
354
|
+
if @api_client.config.client_side_validation && folder_uuid.nil?
|
|
355
|
+
fail ArgumentError, "Missing the required parameter 'folder_uuid' when calling MediaApi.delete_media_folder"
|
|
356
|
+
end
|
|
357
|
+
# resource path
|
|
358
|
+
local_var_path = '/{workspaceUuid}/media/folders/{folderUuid}'.sub('{' + 'workspaceUuid' + '}', CGI.escape(workspace_uuid.to_s)).sub('{' + 'folderUuid' + '}', CGI.escape(folder_uuid.to_s))
|
|
359
|
+
|
|
360
|
+
# query parameters
|
|
361
|
+
query_params = opts[:query_params] || {}
|
|
362
|
+
|
|
363
|
+
# header parameters
|
|
364
|
+
header_params = opts[:header_params] || {}
|
|
365
|
+
# HTTP header 'Accept' (if needed)
|
|
366
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
367
|
+
# HTTP header 'Content-Type'
|
|
368
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
369
|
+
if !content_type.nil?
|
|
370
|
+
header_params['Content-Type'] = content_type
|
|
371
|
+
end
|
|
372
|
+
|
|
373
|
+
# form parameters
|
|
374
|
+
form_params = opts[:form_params] || {}
|
|
375
|
+
|
|
376
|
+
# http body (model)
|
|
377
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'delete_media_folder_request'])
|
|
378
|
+
|
|
379
|
+
# return_type
|
|
380
|
+
return_type = opts[:debug_return_type] || 'Object'
|
|
381
|
+
|
|
382
|
+
# auth_names
|
|
383
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
384
|
+
|
|
385
|
+
new_options = opts.merge(
|
|
386
|
+
:operation => :"MediaApi.delete_media_folder",
|
|
387
|
+
:header_params => header_params,
|
|
388
|
+
:query_params => query_params,
|
|
389
|
+
:form_params => form_params,
|
|
390
|
+
:body => post_body,
|
|
391
|
+
:auth_names => auth_names,
|
|
392
|
+
:return_type => return_type
|
|
393
|
+
)
|
|
394
|
+
|
|
395
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
396
|
+
if @api_client.config.debugging
|
|
397
|
+
@api_client.config.logger.debug "API called: MediaApi#delete_media_folder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
398
|
+
end
|
|
399
|
+
return data, status_code, headers
|
|
400
|
+
end
|
|
401
|
+
|
|
234
402
|
# Get media
|
|
235
403
|
# Returns a single media asset.
|
|
236
404
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
@@ -374,7 +542,8 @@ module PostBoost
|
|
|
374
542
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
375
543
|
# @param initiate_chunked_upload_request [InitiateChunkedUploadRequest]
|
|
376
544
|
# @param [Hash] opts the optional parameters
|
|
377
|
-
# @
|
|
545
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
546
|
+
# @return [InitiateChunkedUpload201Response]
|
|
378
547
|
def initiate_chunked_upload(workspace_uuid, initiate_chunked_upload_request, opts = {})
|
|
379
548
|
data, _status_code, _headers = initiate_chunked_upload_with_http_info(workspace_uuid, initiate_chunked_upload_request, opts)
|
|
380
549
|
data
|
|
@@ -385,7 +554,8 @@ module PostBoost
|
|
|
385
554
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
386
555
|
# @param initiate_chunked_upload_request [InitiateChunkedUploadRequest]
|
|
387
556
|
# @param [Hash] opts the optional parameters
|
|
388
|
-
# @
|
|
557
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
558
|
+
# @return [Array<(InitiateChunkedUpload201Response, Integer, Hash)>] InitiateChunkedUpload201Response data, response status code and response headers
|
|
389
559
|
def initiate_chunked_upload_with_http_info(workspace_uuid, initiate_chunked_upload_request, opts = {})
|
|
390
560
|
if @api_client.config.debugging
|
|
391
561
|
@api_client.config.logger.debug 'Calling API: MediaApi.initiate_chunked_upload ...'
|
|
@@ -398,6 +568,14 @@ module PostBoost
|
|
|
398
568
|
if @api_client.config.client_side_validation && initiate_chunked_upload_request.nil?
|
|
399
569
|
fail ArgumentError, "Missing the required parameter 'initiate_chunked_upload_request' when calling MediaApi.initiate_chunked_upload"
|
|
400
570
|
end
|
|
571
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
|
|
572
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.initiate_chunked_upload, the character length must be smaller than or equal to 255.'
|
|
573
|
+
end
|
|
574
|
+
|
|
575
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
|
|
576
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.initiate_chunked_upload, the character length must be great than or equal to 1.'
|
|
577
|
+
end
|
|
578
|
+
|
|
401
579
|
# resource path
|
|
402
580
|
local_var_path = '/{workspaceUuid}/media/chunked/initiate'.sub('{' + 'workspaceUuid' + '}', CGI.escape(workspace_uuid.to_s))
|
|
403
581
|
|
|
@@ -413,6 +591,7 @@ module PostBoost
|
|
|
413
591
|
if !content_type.nil?
|
|
414
592
|
header_params['Content-Type'] = content_type
|
|
415
593
|
end
|
|
594
|
+
header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
|
|
416
595
|
|
|
417
596
|
# form parameters
|
|
418
597
|
form_params = opts[:form_params] || {}
|
|
@@ -421,7 +600,7 @@ module PostBoost
|
|
|
421
600
|
post_body = opts[:debug_body] || @api_client.object_to_http_body(initiate_chunked_upload_request)
|
|
422
601
|
|
|
423
602
|
# return_type
|
|
424
|
-
return_type = opts[:debug_return_type] || '
|
|
603
|
+
return_type = opts[:debug_return_type] || 'InitiateChunkedUpload201Response'
|
|
425
604
|
|
|
426
605
|
# auth_names
|
|
427
606
|
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
@@ -448,7 +627,8 @@ module PostBoost
|
|
|
448
627
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
449
628
|
# @param initiate_remote_upload_request [InitiateRemoteUploadRequest]
|
|
450
629
|
# @param [Hash] opts the optional parameters
|
|
451
|
-
# @
|
|
630
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
631
|
+
# @return [InitiateRemoteUpload201Response]
|
|
452
632
|
def initiate_remote_upload(workspace_uuid, initiate_remote_upload_request, opts = {})
|
|
453
633
|
data, _status_code, _headers = initiate_remote_upload_with_http_info(workspace_uuid, initiate_remote_upload_request, opts)
|
|
454
634
|
data
|
|
@@ -459,7 +639,8 @@ module PostBoost
|
|
|
459
639
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
460
640
|
# @param initiate_remote_upload_request [InitiateRemoteUploadRequest]
|
|
461
641
|
# @param [Hash] opts the optional parameters
|
|
462
|
-
# @
|
|
642
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
643
|
+
# @return [Array<(InitiateRemoteUpload201Response, Integer, Hash)>] InitiateRemoteUpload201Response data, response status code and response headers
|
|
463
644
|
def initiate_remote_upload_with_http_info(workspace_uuid, initiate_remote_upload_request, opts = {})
|
|
464
645
|
if @api_client.config.debugging
|
|
465
646
|
@api_client.config.logger.debug 'Calling API: MediaApi.initiate_remote_upload ...'
|
|
@@ -472,6 +653,14 @@ module PostBoost
|
|
|
472
653
|
if @api_client.config.client_side_validation && initiate_remote_upload_request.nil?
|
|
473
654
|
fail ArgumentError, "Missing the required parameter 'initiate_remote_upload_request' when calling MediaApi.initiate_remote_upload"
|
|
474
655
|
end
|
|
656
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
|
|
657
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.initiate_remote_upload, the character length must be smaller than or equal to 255.'
|
|
658
|
+
end
|
|
659
|
+
|
|
660
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
|
|
661
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.initiate_remote_upload, the character length must be great than or equal to 1.'
|
|
662
|
+
end
|
|
663
|
+
|
|
475
664
|
# resource path
|
|
476
665
|
local_var_path = '/{workspaceUuid}/media/remote/initiate'.sub('{' + 'workspaceUuid' + '}', CGI.escape(workspace_uuid.to_s))
|
|
477
666
|
|
|
@@ -487,6 +676,7 @@ module PostBoost
|
|
|
487
676
|
if !content_type.nil?
|
|
488
677
|
header_params['Content-Type'] = content_type
|
|
489
678
|
end
|
|
679
|
+
header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
|
|
490
680
|
|
|
491
681
|
# form parameters
|
|
492
682
|
form_params = opts[:form_params] || {}
|
|
@@ -495,7 +685,7 @@ module PostBoost
|
|
|
495
685
|
post_body = opts[:debug_body] || @api_client.object_to_http_body(initiate_remote_upload_request)
|
|
496
686
|
|
|
497
687
|
# return_type
|
|
498
|
-
return_type = opts[:debug_return_type] || '
|
|
688
|
+
return_type = opts[:debug_return_type] || 'InitiateRemoteUpload201Response'
|
|
499
689
|
|
|
500
690
|
# auth_names
|
|
501
691
|
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
@@ -518,10 +708,18 @@ module PostBoost
|
|
|
518
708
|
end
|
|
519
709
|
|
|
520
710
|
# List media
|
|
521
|
-
# Returns a paginated list of media assets in the workspace library.
|
|
711
|
+
# Returns a paginated list of media assets in the workspace library. Without `folder` every item is listed, whatever folder it is filed in. A `keyword` search always looks at the whole library and ignores `folder` and `favorite`.
|
|
522
712
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
523
713
|
# @param [Hash] opts the optional parameters
|
|
524
|
-
# @option opts [Integer] :page Page number
|
|
714
|
+
# @option opts [Integer] :page Page number. (default to 1)
|
|
715
|
+
# @option opts [Integer] :limit Items per page. Values below 1 fall back to 50; values above 100 are capped at 100. (default to 50)
|
|
716
|
+
# @option opts [String] :folder Media folder UUID, or `root` for items not filed in any folder.
|
|
717
|
+
# @option opts [Array<String>] :mime_types Only these MIME types (for example `image/png`).
|
|
718
|
+
# @option opts [String] :type Only this media type.
|
|
719
|
+
# @option opts [String] :keyword Search media by name.
|
|
720
|
+
# @option opts [String] :usage Filter by how the media is used in posts.
|
|
721
|
+
# @option opts [Boolean] :favorite When `true`, only media the caller marked as favorite.
|
|
722
|
+
# @option opts [String] :sort (default to 'newest')
|
|
525
723
|
# @return [ListMedia200Response]
|
|
526
724
|
def list_media(workspace_uuid, opts = {})
|
|
527
725
|
data, _status_code, _headers = list_media_with_http_info(workspace_uuid, opts)
|
|
@@ -529,10 +727,18 @@ module PostBoost
|
|
|
529
727
|
end
|
|
530
728
|
|
|
531
729
|
# List media
|
|
532
|
-
# Returns a paginated list of media assets in the workspace library.
|
|
730
|
+
# Returns a paginated list of media assets in the workspace library. Without `folder` every item is listed, whatever folder it is filed in. A `keyword` search always looks at the whole library and ignores `folder` and `favorite`.
|
|
533
731
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
534
732
|
# @param [Hash] opts the optional parameters
|
|
535
|
-
# @option opts [Integer] :page Page number
|
|
733
|
+
# @option opts [Integer] :page Page number. (default to 1)
|
|
734
|
+
# @option opts [Integer] :limit Items per page. Values below 1 fall back to 50; values above 100 are capped at 100. (default to 50)
|
|
735
|
+
# @option opts [String] :folder Media folder UUID, or `root` for items not filed in any folder.
|
|
736
|
+
# @option opts [Array<String>] :mime_types Only these MIME types (for example `image/png`).
|
|
737
|
+
# @option opts [String] :type Only this media type.
|
|
738
|
+
# @option opts [String] :keyword Search media by name.
|
|
739
|
+
# @option opts [String] :usage Filter by how the media is used in posts.
|
|
740
|
+
# @option opts [Boolean] :favorite When `true`, only media the caller marked as favorite.
|
|
741
|
+
# @option opts [String] :sort (default to 'newest')
|
|
536
742
|
# @return [Array<(ListMedia200Response, Integer, Hash)>] ListMedia200Response data, response status code and response headers
|
|
537
743
|
def list_media_with_http_info(workspace_uuid, opts = {})
|
|
538
744
|
if @api_client.config.debugging
|
|
@@ -542,12 +748,36 @@ module PostBoost
|
|
|
542
748
|
if @api_client.config.client_side_validation && workspace_uuid.nil?
|
|
543
749
|
fail ArgumentError, "Missing the required parameter 'workspace_uuid' when calling MediaApi.list_media"
|
|
544
750
|
end
|
|
751
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
752
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling MediaApi.list_media, must be smaller than or equal to 100.'
|
|
753
|
+
end
|
|
754
|
+
|
|
755
|
+
allowable_values = ["image", "gif", "video"]
|
|
756
|
+
if @api_client.config.client_side_validation && opts[:'type'] && !allowable_values.include?(opts[:'type'])
|
|
757
|
+
fail ArgumentError, "invalid value for \"type\", must be one of #{allowable_values}"
|
|
758
|
+
end
|
|
759
|
+
allowable_values = ["unused", "draft", "scheduled", "published"]
|
|
760
|
+
if @api_client.config.client_side_validation && opts[:'usage'] && !allowable_values.include?(opts[:'usage'])
|
|
761
|
+
fail ArgumentError, "invalid value for \"usage\", must be one of #{allowable_values}"
|
|
762
|
+
end
|
|
763
|
+
allowable_values = ["newest", "oldest", "name", "size"]
|
|
764
|
+
if @api_client.config.client_side_validation && opts[:'sort'] && !allowable_values.include?(opts[:'sort'])
|
|
765
|
+
fail ArgumentError, "invalid value for \"sort\", must be one of #{allowable_values}"
|
|
766
|
+
end
|
|
545
767
|
# resource path
|
|
546
768
|
local_var_path = '/{workspaceUuid}/media'.sub('{' + 'workspaceUuid' + '}', CGI.escape(workspace_uuid.to_s))
|
|
547
769
|
|
|
548
770
|
# query parameters
|
|
549
771
|
query_params = opts[:query_params] || {}
|
|
550
772
|
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
773
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
774
|
+
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
|
775
|
+
query_params[:'mime_types[]'] = @api_client.build_collection_param(opts[:'mime_types'], :multi) if !opts[:'mime_types'].nil?
|
|
776
|
+
query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
|
|
777
|
+
query_params[:'keyword'] = opts[:'keyword'] if !opts[:'keyword'].nil?
|
|
778
|
+
query_params[:'usage'] = opts[:'usage'] if !opts[:'usage'].nil?
|
|
779
|
+
query_params[:'favorite'] = opts[:'favorite'] if !opts[:'favorite'].nil?
|
|
780
|
+
query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil?
|
|
551
781
|
|
|
552
782
|
# header parameters
|
|
553
783
|
header_params = opts[:header_params] || {}
|
|
@@ -583,8 +813,71 @@ module PostBoost
|
|
|
583
813
|
return data, status_code, headers
|
|
584
814
|
end
|
|
585
815
|
|
|
816
|
+
# List media folders
|
|
817
|
+
# Returns the whole folder tree of the media library in one response (not paginated). Rebuild the tree from each folder's `parent`.
|
|
818
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
819
|
+
# @param [Hash] opts the optional parameters
|
|
820
|
+
# @return [ListMediaFolders200Response]
|
|
821
|
+
def list_media_folders(workspace_uuid, opts = {})
|
|
822
|
+
data, _status_code, _headers = list_media_folders_with_http_info(workspace_uuid, opts)
|
|
823
|
+
data
|
|
824
|
+
end
|
|
825
|
+
|
|
826
|
+
# List media folders
|
|
827
|
+
# Returns the whole folder tree of the media library in one response (not paginated). Rebuild the tree from each folder's `parent`.
|
|
828
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
829
|
+
# @param [Hash] opts the optional parameters
|
|
830
|
+
# @return [Array<(ListMediaFolders200Response, Integer, Hash)>] ListMediaFolders200Response data, response status code and response headers
|
|
831
|
+
def list_media_folders_with_http_info(workspace_uuid, opts = {})
|
|
832
|
+
if @api_client.config.debugging
|
|
833
|
+
@api_client.config.logger.debug 'Calling API: MediaApi.list_media_folders ...'
|
|
834
|
+
end
|
|
835
|
+
# verify the required parameter 'workspace_uuid' is set
|
|
836
|
+
if @api_client.config.client_side_validation && workspace_uuid.nil?
|
|
837
|
+
fail ArgumentError, "Missing the required parameter 'workspace_uuid' when calling MediaApi.list_media_folders"
|
|
838
|
+
end
|
|
839
|
+
# resource path
|
|
840
|
+
local_var_path = '/{workspaceUuid}/media/folders'.sub('{' + 'workspaceUuid' + '}', CGI.escape(workspace_uuid.to_s))
|
|
841
|
+
|
|
842
|
+
# query parameters
|
|
843
|
+
query_params = opts[:query_params] || {}
|
|
844
|
+
|
|
845
|
+
# header parameters
|
|
846
|
+
header_params = opts[:header_params] || {}
|
|
847
|
+
# HTTP header 'Accept' (if needed)
|
|
848
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
849
|
+
|
|
850
|
+
# form parameters
|
|
851
|
+
form_params = opts[:form_params] || {}
|
|
852
|
+
|
|
853
|
+
# http body (model)
|
|
854
|
+
post_body = opts[:debug_body]
|
|
855
|
+
|
|
856
|
+
# return_type
|
|
857
|
+
return_type = opts[:debug_return_type] || 'ListMediaFolders200Response'
|
|
858
|
+
|
|
859
|
+
# auth_names
|
|
860
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
861
|
+
|
|
862
|
+
new_options = opts.merge(
|
|
863
|
+
:operation => :"MediaApi.list_media_folders",
|
|
864
|
+
:header_params => header_params,
|
|
865
|
+
:query_params => query_params,
|
|
866
|
+
:form_params => form_params,
|
|
867
|
+
:body => post_body,
|
|
868
|
+
:auth_names => auth_names,
|
|
869
|
+
:return_type => return_type
|
|
870
|
+
)
|
|
871
|
+
|
|
872
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
873
|
+
if @api_client.config.debugging
|
|
874
|
+
@api_client.config.logger.debug "API called: MediaApi#list_media_folders\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
875
|
+
end
|
|
876
|
+
return data, status_code, headers
|
|
877
|
+
end
|
|
878
|
+
|
|
586
879
|
# Update media
|
|
587
|
-
# Update the alt text of a media asset.
|
|
880
|
+
# Update the name, alt text, or folder of a media asset. Only the keys present in the body are written. Sending `folder: null` moves the item to the library root; omitting `folder` leaves it where it is.
|
|
588
881
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
589
882
|
# @param media_uuid [String] UUID of the media asset.
|
|
590
883
|
# @param update_media_request [UpdateMediaRequest]
|
|
@@ -596,7 +889,7 @@ module PostBoost
|
|
|
596
889
|
end
|
|
597
890
|
|
|
598
891
|
# Update media
|
|
599
|
-
# Update the alt text of a media asset.
|
|
892
|
+
# Update the name, alt text, or folder of a media asset. Only the keys present in the body are written. Sending `folder: null` moves the item to the library root; omitting `folder` leaves it where it is.
|
|
600
893
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
601
894
|
# @param media_uuid [String] UUID of the media asset.
|
|
602
895
|
# @param update_media_request [UpdateMediaRequest]
|
|
@@ -663,6 +956,86 @@ module PostBoost
|
|
|
663
956
|
return data, status_code, headers
|
|
664
957
|
end
|
|
665
958
|
|
|
959
|
+
# Update media folder
|
|
960
|
+
# Renames a folder and/or moves it. Sending `parent` moves the folder (null = top level); omitting it keeps the current parent. A folder cannot be moved into itself or one of its descendants.
|
|
961
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
962
|
+
# @param folder_uuid [String] UUID of the media folder.
|
|
963
|
+
# @param media_folder_input [MediaFolderInput]
|
|
964
|
+
# @param [Hash] opts the optional parameters
|
|
965
|
+
# @return [MediaFolder]
|
|
966
|
+
def update_media_folder(workspace_uuid, folder_uuid, media_folder_input, opts = {})
|
|
967
|
+
data, _status_code, _headers = update_media_folder_with_http_info(workspace_uuid, folder_uuid, media_folder_input, opts)
|
|
968
|
+
data
|
|
969
|
+
end
|
|
970
|
+
|
|
971
|
+
# Update media folder
|
|
972
|
+
# Renames a folder and/or moves it. Sending `parent` moves the folder (null = top level); omitting it keeps the current parent. A folder cannot be moved into itself or one of its descendants.
|
|
973
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
974
|
+
# @param folder_uuid [String] UUID of the media folder.
|
|
975
|
+
# @param media_folder_input [MediaFolderInput]
|
|
976
|
+
# @param [Hash] opts the optional parameters
|
|
977
|
+
# @return [Array<(MediaFolder, Integer, Hash)>] MediaFolder data, response status code and response headers
|
|
978
|
+
def update_media_folder_with_http_info(workspace_uuid, folder_uuid, media_folder_input, opts = {})
|
|
979
|
+
if @api_client.config.debugging
|
|
980
|
+
@api_client.config.logger.debug 'Calling API: MediaApi.update_media_folder ...'
|
|
981
|
+
end
|
|
982
|
+
# verify the required parameter 'workspace_uuid' is set
|
|
983
|
+
if @api_client.config.client_side_validation && workspace_uuid.nil?
|
|
984
|
+
fail ArgumentError, "Missing the required parameter 'workspace_uuid' when calling MediaApi.update_media_folder"
|
|
985
|
+
end
|
|
986
|
+
# verify the required parameter 'folder_uuid' is set
|
|
987
|
+
if @api_client.config.client_side_validation && folder_uuid.nil?
|
|
988
|
+
fail ArgumentError, "Missing the required parameter 'folder_uuid' when calling MediaApi.update_media_folder"
|
|
989
|
+
end
|
|
990
|
+
# verify the required parameter 'media_folder_input' is set
|
|
991
|
+
if @api_client.config.client_side_validation && media_folder_input.nil?
|
|
992
|
+
fail ArgumentError, "Missing the required parameter 'media_folder_input' when calling MediaApi.update_media_folder"
|
|
993
|
+
end
|
|
994
|
+
# resource path
|
|
995
|
+
local_var_path = '/{workspaceUuid}/media/folders/{folderUuid}'.sub('{' + 'workspaceUuid' + '}', CGI.escape(workspace_uuid.to_s)).sub('{' + 'folderUuid' + '}', CGI.escape(folder_uuid.to_s))
|
|
996
|
+
|
|
997
|
+
# query parameters
|
|
998
|
+
query_params = opts[:query_params] || {}
|
|
999
|
+
|
|
1000
|
+
# header parameters
|
|
1001
|
+
header_params = opts[:header_params] || {}
|
|
1002
|
+
# HTTP header 'Accept' (if needed)
|
|
1003
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1004
|
+
# HTTP header 'Content-Type'
|
|
1005
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1006
|
+
if !content_type.nil?
|
|
1007
|
+
header_params['Content-Type'] = content_type
|
|
1008
|
+
end
|
|
1009
|
+
|
|
1010
|
+
# form parameters
|
|
1011
|
+
form_params = opts[:form_params] || {}
|
|
1012
|
+
|
|
1013
|
+
# http body (model)
|
|
1014
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(media_folder_input)
|
|
1015
|
+
|
|
1016
|
+
# return_type
|
|
1017
|
+
return_type = opts[:debug_return_type] || 'MediaFolder'
|
|
1018
|
+
|
|
1019
|
+
# auth_names
|
|
1020
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
1021
|
+
|
|
1022
|
+
new_options = opts.merge(
|
|
1023
|
+
:operation => :"MediaApi.update_media_folder",
|
|
1024
|
+
:header_params => header_params,
|
|
1025
|
+
:query_params => query_params,
|
|
1026
|
+
:form_params => form_params,
|
|
1027
|
+
:body => post_body,
|
|
1028
|
+
:auth_names => auth_names,
|
|
1029
|
+
:return_type => return_type
|
|
1030
|
+
)
|
|
1031
|
+
|
|
1032
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
|
1033
|
+
if @api_client.config.debugging
|
|
1034
|
+
@api_client.config.logger.debug "API called: MediaApi#update_media_folder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1035
|
+
end
|
|
1036
|
+
return data, status_code, headers
|
|
1037
|
+
end
|
|
1038
|
+
|
|
666
1039
|
# Upload a chunk
|
|
667
1040
|
# Upload a single chunk of a chunked upload session.
|
|
668
1041
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
@@ -670,7 +1043,7 @@ module PostBoost
|
|
|
670
1043
|
# @param chunk [File]
|
|
671
1044
|
# @param chunk_index [Integer] Zero-based index of this chunk.
|
|
672
1045
|
# @param [Hash] opts the optional parameters
|
|
673
|
-
# @return [
|
|
1046
|
+
# @return [UploadChunk201Response]
|
|
674
1047
|
def upload_chunk(workspace_uuid, upload_uuid, chunk, chunk_index, opts = {})
|
|
675
1048
|
data, _status_code, _headers = upload_chunk_with_http_info(workspace_uuid, upload_uuid, chunk, chunk_index, opts)
|
|
676
1049
|
data
|
|
@@ -683,7 +1056,7 @@ module PostBoost
|
|
|
683
1056
|
# @param chunk [File]
|
|
684
1057
|
# @param chunk_index [Integer] Zero-based index of this chunk.
|
|
685
1058
|
# @param [Hash] opts the optional parameters
|
|
686
|
-
# @return [Array<(
|
|
1059
|
+
# @return [Array<(UploadChunk201Response, Integer, Hash)>] UploadChunk201Response data, response status code and response headers
|
|
687
1060
|
def upload_chunk_with_http_info(workspace_uuid, upload_uuid, chunk, chunk_index, opts = {})
|
|
688
1061
|
if @api_client.config.debugging
|
|
689
1062
|
@api_client.config.logger.debug 'Calling API: MediaApi.upload_chunk ...'
|
|
@@ -729,7 +1102,7 @@ module PostBoost
|
|
|
729
1102
|
post_body = opts[:debug_body]
|
|
730
1103
|
|
|
731
1104
|
# return_type
|
|
732
|
-
return_type = opts[:debug_return_type] || '
|
|
1105
|
+
return_type = opts[:debug_return_type] || 'UploadChunk201Response'
|
|
733
1106
|
|
|
734
1107
|
# auth_names
|
|
735
1108
|
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
@@ -752,11 +1125,13 @@ module PostBoost
|
|
|
752
1125
|
end
|
|
753
1126
|
|
|
754
1127
|
# Upload media (binary)
|
|
755
|
-
# Upload a file directly as multipart form data.
|
|
1128
|
+
# Upload a file directly as multipart form data. Images and videos, plus a PDF (up to 100 MB) for LinkedIn document posts: a post that attaches a PDF must have it as the only media item and may only go to LinkedIn profiles and pages.
|
|
756
1129
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
757
1130
|
# @param file [File] The file to upload.
|
|
758
1131
|
# @param [Hash] opts the optional parameters
|
|
1132
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
759
1133
|
# @option opts [String] :alt_text Alternative text for accessibility.
|
|
1134
|
+
# @option opts [String] :folder UUID of the media folder to file the upload in. Omit or null for the library root.
|
|
760
1135
|
# @return [Media]
|
|
761
1136
|
def upload_media(workspace_uuid, file, opts = {})
|
|
762
1137
|
data, _status_code, _headers = upload_media_with_http_info(workspace_uuid, file, opts)
|
|
@@ -764,11 +1139,13 @@ module PostBoost
|
|
|
764
1139
|
end
|
|
765
1140
|
|
|
766
1141
|
# Upload media (binary)
|
|
767
|
-
# Upload a file directly as multipart form data.
|
|
1142
|
+
# Upload a file directly as multipart form data. Images and videos, plus a PDF (up to 100 MB) for LinkedIn document posts: a post that attaches a PDF must have it as the only media item and may only go to LinkedIn profiles and pages.
|
|
768
1143
|
# @param workspace_uuid [String] UUID of the workspace.
|
|
769
1144
|
# @param file [File] The file to upload.
|
|
770
1145
|
# @param [Hash] opts the optional parameters
|
|
1146
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
771
1147
|
# @option opts [String] :alt_text Alternative text for accessibility.
|
|
1148
|
+
# @option opts [String] :folder UUID of the media folder to file the upload in. Omit or null for the library root.
|
|
772
1149
|
# @return [Array<(Media, Integer, Hash)>] Media data, response status code and response headers
|
|
773
1150
|
def upload_media_with_http_info(workspace_uuid, file, opts = {})
|
|
774
1151
|
if @api_client.config.debugging
|
|
@@ -782,6 +1159,14 @@ module PostBoost
|
|
|
782
1159
|
if @api_client.config.client_side_validation && file.nil?
|
|
783
1160
|
fail ArgumentError, "Missing the required parameter 'file' when calling MediaApi.upload_media"
|
|
784
1161
|
end
|
|
1162
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
|
|
1163
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.upload_media, the character length must be smaller than or equal to 255.'
|
|
1164
|
+
end
|
|
1165
|
+
|
|
1166
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
|
|
1167
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.upload_media, the character length must be great than or equal to 1.'
|
|
1168
|
+
end
|
|
1169
|
+
|
|
785
1170
|
if @api_client.config.client_side_validation && !opts[:'alt_text'].nil? && opts[:'alt_text'].to_s.length > 255
|
|
786
1171
|
fail ArgumentError, 'invalid value for "opts[:"alt_text"]" when calling MediaApi.upload_media, the character length must be smaller than or equal to 255.'
|
|
787
1172
|
end
|
|
@@ -801,11 +1186,13 @@ module PostBoost
|
|
|
801
1186
|
if !content_type.nil?
|
|
802
1187
|
header_params['Content-Type'] = content_type
|
|
803
1188
|
end
|
|
1189
|
+
header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
|
|
804
1190
|
|
|
805
1191
|
# form parameters
|
|
806
1192
|
form_params = opts[:form_params] || {}
|
|
807
1193
|
form_params['file'] = file
|
|
808
1194
|
form_params['alt_text'] = opts[:'alt_text'] if !opts[:'alt_text'].nil?
|
|
1195
|
+
form_params['folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
|
809
1196
|
|
|
810
1197
|
# http body (model)
|
|
811
1198
|
post_body = opts[:debug_body]
|
|
@@ -832,5 +1219,90 @@ module PostBoost
|
|
|
832
1219
|
end
|
|
833
1220
|
return data, status_code, headers
|
|
834
1221
|
end
|
|
1222
|
+
|
|
1223
|
+
# Upload media (base64 JSON)
|
|
1224
|
+
# Upload a file as base64 inside a JSON body, for agents and tools that cannot send multipart form data. The decoded file is checked exactly like `POST media` (allowed types and size limits; a PDF is accepted for LinkedIn document posts). Decoded size is capped at 20 MB; for larger files use remote upload by URL or chunked upload.
|
|
1225
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
1226
|
+
# @param media_base64_input [MediaBase64Input]
|
|
1227
|
+
# @param [Hash] opts the optional parameters
|
|
1228
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
1229
|
+
# @return [Media]
|
|
1230
|
+
def upload_media_base64(workspace_uuid, media_base64_input, opts = {})
|
|
1231
|
+
data, _status_code, _headers = upload_media_base64_with_http_info(workspace_uuid, media_base64_input, opts)
|
|
1232
|
+
data
|
|
1233
|
+
end
|
|
1234
|
+
|
|
1235
|
+
# Upload media (base64 JSON)
|
|
1236
|
+
# Upload a file as base64 inside a JSON body, for agents and tools that cannot send multipart form data. The decoded file is checked exactly like `POST media` (allowed types and size limits; a PDF is accepted for LinkedIn document posts). Decoded size is capped at 20 MB; for larger files use remote upload by URL or chunked upload.
|
|
1237
|
+
# @param workspace_uuid [String] UUID of the workspace.
|
|
1238
|
+
# @param media_base64_input [MediaBase64Input]
|
|
1239
|
+
# @param [Hash] opts the optional parameters
|
|
1240
|
+
# @option opts [String] :idempotency_key Unique key (for example a UUID) that makes the request safe to retry. A repeat with the same key and body within 24 hours returns the stored response with `Idempotent-Replayed: true` and has no further effect. Keys are scoped to your user, the workspace, the method and the path.
|
|
1241
|
+
# @return [Array<(Media, Integer, Hash)>] Media data, response status code and response headers
|
|
1242
|
+
def upload_media_base64_with_http_info(workspace_uuid, media_base64_input, opts = {})
|
|
1243
|
+
if @api_client.config.debugging
|
|
1244
|
+
@api_client.config.logger.debug 'Calling API: MediaApi.upload_media_base64 ...'
|
|
1245
|
+
end
|
|
1246
|
+
# verify the required parameter 'workspace_uuid' is set
|
|
1247
|
+
if @api_client.config.client_side_validation && workspace_uuid.nil?
|
|
1248
|
+
fail ArgumentError, "Missing the required parameter 'workspace_uuid' when calling MediaApi.upload_media_base64"
|
|
1249
|
+
end
|
|
1250
|
+
# verify the required parameter 'media_base64_input' is set
|
|
1251
|
+
if @api_client.config.client_side_validation && media_base64_input.nil?
|
|
1252
|
+
fail ArgumentError, "Missing the required parameter 'media_base64_input' when calling MediaApi.upload_media_base64"
|
|
1253
|
+
end
|
|
1254
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
|
|
1255
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.upload_media_base64, the character length must be smaller than or equal to 255.'
|
|
1256
|
+
end
|
|
1257
|
+
|
|
1258
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
|
|
1259
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling MediaApi.upload_media_base64, the character length must be great than or equal to 1.'
|
|
1260
|
+
end
|
|
1261
|
+
|
|
1262
|
+
# resource path
|
|
1263
|
+
local_var_path = '/{workspaceUuid}/media/base64'.sub('{' + 'workspaceUuid' + '}', CGI.escape(workspace_uuid.to_s))
|
|
1264
|
+
|
|
1265
|
+
# query parameters
|
|
1266
|
+
query_params = opts[:query_params] || {}
|
|
1267
|
+
|
|
1268
|
+
# header parameters
|
|
1269
|
+
header_params = opts[:header_params] || {}
|
|
1270
|
+
# HTTP header 'Accept' (if needed)
|
|
1271
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1272
|
+
# HTTP header 'Content-Type'
|
|
1273
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1274
|
+
if !content_type.nil?
|
|
1275
|
+
header_params['Content-Type'] = content_type
|
|
1276
|
+
end
|
|
1277
|
+
header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
|
|
1278
|
+
|
|
1279
|
+
# form parameters
|
|
1280
|
+
form_params = opts[:form_params] || {}
|
|
1281
|
+
|
|
1282
|
+
# http body (model)
|
|
1283
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(media_base64_input)
|
|
1284
|
+
|
|
1285
|
+
# return_type
|
|
1286
|
+
return_type = opts[:debug_return_type] || 'Media'
|
|
1287
|
+
|
|
1288
|
+
# auth_names
|
|
1289
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
1290
|
+
|
|
1291
|
+
new_options = opts.merge(
|
|
1292
|
+
:operation => :"MediaApi.upload_media_base64",
|
|
1293
|
+
:header_params => header_params,
|
|
1294
|
+
:query_params => query_params,
|
|
1295
|
+
:form_params => form_params,
|
|
1296
|
+
:body => post_body,
|
|
1297
|
+
:auth_names => auth_names,
|
|
1298
|
+
:return_type => return_type
|
|
1299
|
+
)
|
|
1300
|
+
|
|
1301
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
1302
|
+
if @api_client.config.debugging
|
|
1303
|
+
@api_client.config.logger.debug "API called: MediaApi#upload_media_base64\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1304
|
+
end
|
|
1305
|
+
return data, status_code, headers
|
|
1306
|
+
end
|
|
835
1307
|
end
|
|
836
1308
|
end
|