planvortex 0.16.0 → 0.18.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.
package/dist/index.d.cts CHANGED
@@ -1,5 +1,5 @@
1
- import { P as Paginated, S as SocialNetwork, C as ConnectLink, a as ConnectResult, E as EnableResult, b as ConnectSession, A as Account, c as AccountMetrics, D as Destination, d as PersistentMenu, e as Dashboard, M as MetricName, f as DashboardMetricsResult, g as PublicationsSummaryResult, T as TopPublicationsResult, h as PublicationsStatsResult, i as PlanUse, j as Publication, k as AiPlanResultsSort, l as PlannerTemplateName, m as AiPlanCreateRequest, n as AiPlanCreateResult, o as AiPlan, p as AiPlanResults, q as ClientApp, r as ClientAppInput, s as SocialCapabilities, t as CommentActions, u as SocialLimits, v as PublicationLimits, w as AspectRatiosByNetwork, x as PlannerTemplate, y as CommentNetwork, z as Comment, B as CommentThread, F as CommentReplyResult, G as ContactExtraData, H as Contact, I as ContactCreate, J as ContactUpdate, K as IntegrationProviderName, L as IntegrationProvider, N as Integration, O as IntegrationConnectRequest, Q as IntegrationUpdate, R as IntegrationPickerConfig, U as IntegrationCatalogPage, V as MessageTemplate, W as Conversation, X as ConversationTotals, Y as Message, Z as MessageInput, _ as Client, $ as Organization, a0 as AiSettings, a1 as ClientWithOrganizations, a2 as AccountSelection, a3 as PlanData, a4 as PlanUseData, a5 as ConnectToken, a6 as AiContext, a7 as SocialCredentialsInput, a8 as Product, a9 as ProductInput, aa as ProductCatalog, ab as ProductCatalogInput, ac as PublicationInput, ad as PublicationState, ae as PublicationStats, af as PublicationStatsHistory, ag as Upload } from './index-DgRGeYRl.cjs';
2
- export { ah as AccountError, ai as AccountMetricRow, aj as AccountStateChange, ak as AccountWebhookChangeBase, al as AccountWithError, am as AiImageOrigin, an as AiPlanCostEstimate, ao as AiPlanDestination, ap as AiPlanError, aq as AiPlanNotice, ar as AiPlanOptions, as as AiPlanOptionsInput, at as AiPlanResult, au as AiPlanResultsGroup, av as AiPlanResultsTemplateGroup, aw as AiPlanSource, ax as AiPlanSourceImageInput, ay as AiPlanSourceInput, az as AiPlanSourceProduct, aA as AiPlanState, aB as ApiErrorBody, aC as AspectRatios, aD as AuthError, aE as ClientPlan, aF as CommentAuthor, aG as CommentChange, aH as ConnectSessionAccount, aI as ContactChannel, aJ as ContactError, aK as DashboardAiPlanRef, aL as DashboardPublicationRef, aM as DashboardRange, aN as EngagementBase, aO as FileError, aP as FileFormat, aQ as FileProperties, aR as FileType, aS as IntegrationCatalogProduct, aT as IntegrationConfig, aU as IntegrationError, aV as IntegrationErrorChange, aW as IntegrationFormField, aX as MessageChange, aY as MessageOptions, aZ as MessageType, a_ as MessagingError, a$ as MetricRow, b0 as NO_ERROR_CODE, b1 as OpenApiComponents, b2 as OpenApiOperations, b3 as OpenApiPaths, b4 as OpenApiWebhooks, b5 as OpenEnum, b6 as OrganizationError, b7 as PLANVORTEX_ERROR_RANGES, b8 as PlanLimitError, b9 as PlanVortexAuthenticationError, ba as PlanVortexConfigError, bb as PlanVortexConnectionError, bc as PlanVortexError, bd as PlanVortexErrorOptions, be as PlanVortexErrorRange, bf as PlannerTemplateField, bg as PlannerTemplateFieldType, bh as ProductError, bi as PublicationAiGenerated, bj as PublicationDestination, bk as PublicationError, bl as PublicationErrorDetail, bm as PublicationMetrics, bn as PublicationPending, bo as PublicationStatsPoint, bp as PublicationType, bq as PublicationsSummary, br as RssConfig, bs as SocialAuthorizationMethod, bt as SocialCredentials, bu as SocialIdentifier, bv as SocialIdentifierInput, bw as SocialLimitsMap, bx as TOKEN_ERROR_CODES, by as TopPublication, bz as UnknownWebhookChange, bA as UserError, bB as WebhookAlgorithm, bC as WebhookChange, bD as WebhookEvent, bE as WithAccount, bF as WithPublication, bG as WooCommerceConnectRequest, bH as account, bI as accountId, bJ as errorFamilyForCode, bK as isPlanVortexError, bL as isTokenError, bM as messageContact, bN as messageContactId, bO as messageDirection, bP as messageFileIds, bQ as messageFiles, bR as publication, bS as publicationId } from './index-DgRGeYRl.cjs';
1
+ import { P as Paginated, S as SocialNetwork, C as ConnectLink, a as ConnectResult, E as EnableResult, b as ConnectSession, A as Account, c as AccountMetrics, D as Destination, d as PublishSettings, e as PersistentMenu, f as Dashboard, M as MetricName, g as DashboardMetricsResult, h as PublicationsSummaryResult, T as TopPublicationsResult, i as PublicationsStatsResult, j as PlanUse, k as Publication, l as AiPlanResultsSort, m as PlannerTemplateName, n as AiPlanCreateRequest, o as AiPlanCreateResult, p as AiPlan, q as AiPlanResults, r as ClientApp, s as ClientAppInput, t as SocialCapabilities, u as CommentActions, v as SocialLimits, w as PublicationLimits, x as AspectRatiosByNetwork, y as PlannerTemplate, z as CommentNetwork, B as Comment, F as CommentThread, G as CommentReplyResult, H as ContactExtraData, I as Contact, J as ContactCreate, K as ContactUpdate, L as IntegrationProviderName, N as IntegrationProvider, O as Integration, Q as IntegrationConnectRequest, R as IntegrationUpdate, U as IntegrationPickerConfig, V as IntegrationCatalogPage, W as MessageTemplate, X as Conversation, Y as ConversationTotals, Z as Message, _ as MessageInput, $ as Client, a0 as Organization, a1 as AiSettings, a2 as ClientWithOrganizations, a3 as AccountSelection, a4 as PlanData, a5 as PlanUseData, a6 as ConnectToken, a7 as AiContext, a8 as SocialCredentialsInput, a9 as Product, aa as ProductInput, ab as ProductCatalog, ac as ProductCatalogInput, ad as PublicationInput, ae as PublicationState, af as PublicationStats, ag as PublicationStatsHistory, ah as Upload } from './index-6DpRjLs4.cjs';
2
+ export { ai as AccountError, aj as AccountMetricRow, ak as AccountStateChange, al as AccountWebhookChangeBase, am as AccountWithError, an as AiImageOrigin, ao as AiPlanCostEstimate, ap as AiPlanDestination, aq as AiPlanError, ar as AiPlanNotice, as as AiPlanOptions, at as AiPlanOptionsInput, au as AiPlanResult, av as AiPlanResultsGroup, aw as AiPlanResultsTemplateGroup, ax as AiPlanSource, ay as AiPlanSourceImageInput, az as AiPlanSourceInput, aA as AiPlanSourceProduct, aB as AiPlanState, aC as ApiErrorBody, aD as AspectRatios, aE as AuthError, aF as ClientPlan, aG as CommentAuthor, aH as CommentChange, aI as ConnectSessionAccount, aJ as ContactChannel, aK as ContactError, aL as DashboardAiPlanRef, aM as DashboardPublicationRef, aN as DashboardRange, aO as EngagementBase, aP as FileError, aQ as FileFormat, aR as FileProperties, aS as FileType, aT as IntegrationCatalogProduct, aU as IntegrationConfig, aV as IntegrationError, aW as IntegrationErrorChange, aX as IntegrationFormField, aY as MessageChange, aZ as MessageOptions, a_ as MessageType, a$ as MessagingError, b0 as MetricRow, b1 as NO_ERROR_CODE, b2 as OpenApiComponents, b3 as OpenApiOperations, b4 as OpenApiPaths, b5 as OpenApiWebhooks, b6 as OpenEnum, b7 as OrganizationError, b8 as PLANVORTEX_ERROR_RANGES, b9 as PlanLimitError, ba as PlanVortexAuthenticationError, bb as PlanVortexConfigError, bc as PlanVortexConnectionError, bd as PlanVortexError, be as PlanVortexErrorOptions, bf as PlanVortexErrorRange, bg as PlannerTemplateField, bh as PlannerTemplateFieldType, bi as ProductError, bj as PublicationAiGenerated, bk as PublicationDestination, bl as PublicationError, bm as PublicationErrorDetail, bn as PublicationMetrics, bo as PublicationPending, bp as PublicationStatsPoint, bq as PublicationType, br as PublicationsSummary, bs as RssConfig, bt as SocialAuthorizationMethod, bu as SocialCredentials, bv as SocialIdentifier, bw as SocialIdentifierInput, bx as SocialLimitsMap, by as TOKEN_ERROR_CODES, bz as TopPublication, bA as UnknownWebhookChange, bB as UserError, bC as WebhookAlgorithm, bD as WebhookChange, bE as WebhookEvent, bF as WithAccount, bG as WithPublication, bH as WooCommerceConnectRequest, bI as account, bJ as accountId, bK as errorFamilyForCode, bL as isPlanVortexError, bM as isTokenError, bN as messageContact, bO as messageContactId, bP as messageDirection, bQ as messageFileIds, bR as messageFiles, bS as publication, bT as publicationId } from './index-6DpRjLs4.cjs';
3
3
 
4
4
  /**
5
5
  * Las dos constantes que todo lo demás necesita. Viven aparte de `index.ts` para que `client.ts`
@@ -15,7 +15,7 @@ declare const PLANVORTEX_API_URL = "https://api.planvortex.com/v1.0.0";
15
15
  * de ejecución obliga a empaquetarlo y se rompe distinto en ESM y en CJS. La mantiene sincronizada
16
16
  * un test.
17
17
  */
18
- declare const VERSION = "0.16.0";
18
+ declare const VERSION = "0.18.0";
19
19
 
20
20
  /** `fetch` con la firma que usamos. Se puede sustituir en tests o para meter un proxy. */
21
21
  type FetchLike = (input: string, init: RequestInit) => Promise<Response>;
@@ -363,6 +363,21 @@ declare class AccountsResource extends Resource {
363
363
  * o no en la red.
364
364
  */
365
365
  destination(idOrganization: string, idAccount: string, idDestination: string, options?: AccountDestinationOptions): Promise<Destination>;
366
+ /**
367
+ * Lo que la cuenta admite AL PUBLICAR, leído de la red en el momento. Hoy sólo TikTok: las
368
+ * redes con `publish_settings` en `catalog.socialCapabilities()`; en las demás contesta 2508.
369
+ *
370
+ * Es lo que la guía de TikTok pide enseñar antes de publicar: a qué cuenta va
371
+ * (`creator.nickname`), las privacidades que admite AHORA (`visibility_options`, a ofrecer sin
372
+ * ninguna elegida de antemano), las interacciones que el creador tiene cerradas en la app
373
+ * (`interactions.*.disabled`) y el vídeo más largo que puede publicar. Léelo cada vez que se
374
+ * abre tu pantalla de publicar: una cuenta pasa de pública a privada entre medias.
375
+ *
376
+ * `can_post: false` es que TikTok no acepta ahora un post de esta cuenta (`reason` trae su
377
+ * código): di que se intente más tarde en vez de mandarlo. Si TikTok no contesta es el 919,
378
+ * nunca una lista vacía.
379
+ */
380
+ publishSettings(idOrganization: string, idAccount: string, options?: RequestOptions): Promise<PublishSettings>;
366
381
  /**
367
382
  * El menú fijo del chat, una entrada por idioma.
368
383
  *
@@ -2265,4 +2280,4 @@ interface AuthProvider {
2265
2280
  /** Margen con el que se pide un token nuevo antes de que caduque el que hay. */
2266
2281
  declare const TOKEN_REFRESH_MARGIN_MS = 60000;
2267
2282
 
2268
- export { Account, type AccountCapability, type AccountDestinationOptions, type AccountListOptions, AccountMetrics, type AccountMetricsOptions, AccountSelection, AccountsResource, AiContext, AiPlan, AiPlanCreateRequest, AiPlanCreateResult, type AiPlanListOptions, type AiPlanRegenerateResult, type AiPlanRegenerateTarget, AiPlanResults, type AiPlanResultsOptions, AiPlanResultsSort, AiPlansResource, AiSettings, AppsResource, AspectRatiosByNetwork, type AuthProvider, CatalogResource, type ChildOrganizationListOptions, Client, ClientApp, ClientAppInput, type ClientCredentialsToken, type ClientListOptions, ClientWithOrganizations, ClientsResource, Comment, CommentActions, type CommentListOptions, CommentNetwork, CommentReplyResult, CommentThread, type CommentThreadOptions, type CommentUpdate, CommentsResource, type ConnectCallbackParams, ConnectLink, type ConnectLinkOptions, type ConnectLinksOptions, ConnectResult, ConnectSession, ConnectToken, type ConnectTokenOptions, Contact, ContactCreate, ContactExtraData, type ContactExtraFilter, type ContactListOptions, ContactUpdate, ContactsResource, Conversation, type ConversationGroupBy, ConversationTotals, type ConversationTotalsOptions, DEFAULT_PAGE_SIZE, DEFAULT_RETRY, DEFAULT_TIMEOUT_MS, Dashboard, DashboardMetricsResult, DashboardResource, Destination, EnableResult, type FetchLike, type FileInput, type FileSource, type HttpHooks, type HttpMethod, type HttpRequest, type HttpResponse, type ImportError, type ImportFileInput, type ImportResult, Integration, IntegrationCatalogPage, IntegrationConnectRequest, type IntegrationListOptions, IntegrationPickerConfig, type IntegrationProductsOptions, IntegrationProvider, IntegrationProviderName, IntegrationUpdate, IntegrationsResource, MAX_PAGES, Message, MessageInput, MessageTemplate, type MessageTemplateResult, MessagesResource, MetricName, type MetricsGroupBy, type MetricsOptions, Organization, type OrganizationInput, type OrganizationListOptions, type OrganizationOptions, type OrganizationPlanInput, OrganizationsResource, PLANVORTEX_API_URL, type PageOptions, Paginated, PersistentMenu, PlanData, PlanUse, PlanUseData, PlanVortex, type PlanVortexOptions, PlannerTemplate, PlannerTemplateName, Product, ProductCatalog, ProductCatalogInput, ProductInput, ProductsResource, Publication, PublicationInput, PublicationLimits, type PublicationListOptions, type PublicationRetryResult, PublicationState, PublicationStats, PublicationStatsHistory, PublicationsResource, type PublicationsStatsOptions, PublicationsStatsResult, PublicationsSummaryResult, type QueryValue, type RangeOptions, type RequestInfo, type RequestOptions, type RequestSender, type ResponseInfo, type RetryConfig, type RetryInfo, SocialCapabilities, SocialLimits, SocialNetwork, TOKEN_REFRESH_MARGIN_MS, type TopPublicationsOptions, TopPublicationsResult, Upload, type UploadUpdate, UploadsResource, VERSION, guessContentType };
2283
+ export { Account, type AccountCapability, type AccountDestinationOptions, type AccountListOptions, AccountMetrics, type AccountMetricsOptions, AccountSelection, AccountsResource, AiContext, AiPlan, AiPlanCreateRequest, AiPlanCreateResult, type AiPlanListOptions, type AiPlanRegenerateResult, type AiPlanRegenerateTarget, AiPlanResults, type AiPlanResultsOptions, AiPlanResultsSort, AiPlansResource, AiSettings, AppsResource, AspectRatiosByNetwork, type AuthProvider, CatalogResource, type ChildOrganizationListOptions, Client, ClientApp, ClientAppInput, type ClientCredentialsToken, type ClientListOptions, ClientWithOrganizations, ClientsResource, Comment, CommentActions, type CommentListOptions, CommentNetwork, CommentReplyResult, CommentThread, type CommentThreadOptions, type CommentUpdate, CommentsResource, type ConnectCallbackParams, ConnectLink, type ConnectLinkOptions, type ConnectLinksOptions, ConnectResult, ConnectSession, ConnectToken, type ConnectTokenOptions, Contact, ContactCreate, ContactExtraData, type ContactExtraFilter, type ContactListOptions, ContactUpdate, ContactsResource, Conversation, type ConversationGroupBy, ConversationTotals, type ConversationTotalsOptions, DEFAULT_PAGE_SIZE, DEFAULT_RETRY, DEFAULT_TIMEOUT_MS, Dashboard, DashboardMetricsResult, DashboardResource, Destination, EnableResult, type FetchLike, type FileInput, type FileSource, type HttpHooks, type HttpMethod, type HttpRequest, type HttpResponse, type ImportError, type ImportFileInput, type ImportResult, Integration, IntegrationCatalogPage, IntegrationConnectRequest, type IntegrationListOptions, IntegrationPickerConfig, type IntegrationProductsOptions, IntegrationProvider, IntegrationProviderName, IntegrationUpdate, IntegrationsResource, MAX_PAGES, Message, MessageInput, MessageTemplate, type MessageTemplateResult, MessagesResource, MetricName, type MetricsGroupBy, type MetricsOptions, Organization, type OrganizationInput, type OrganizationListOptions, type OrganizationOptions, type OrganizationPlanInput, OrganizationsResource, PLANVORTEX_API_URL, type PageOptions, Paginated, PersistentMenu, PlanData, PlanUse, PlanUseData, PlanVortex, type PlanVortexOptions, PlannerTemplate, PlannerTemplateName, Product, ProductCatalog, ProductCatalogInput, ProductInput, ProductsResource, Publication, PublicationInput, PublicationLimits, type PublicationListOptions, type PublicationRetryResult, PublicationState, PublicationStats, PublicationStatsHistory, PublicationsResource, type PublicationsStatsOptions, PublicationsStatsResult, PublicationsSummaryResult, PublishSettings, type QueryValue, type RangeOptions, type RequestInfo, type RequestOptions, type RequestSender, type ResponseInfo, type RetryConfig, type RetryInfo, SocialCapabilities, SocialLimits, SocialNetwork, TOKEN_REFRESH_MARGIN_MS, type TopPublicationsOptions, TopPublicationsResult, Upload, type UploadUpdate, UploadsResource, VERSION, guessContentType };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { P as Paginated, S as SocialNetwork, C as ConnectLink, a as ConnectResult, E as EnableResult, b as ConnectSession, A as Account, c as AccountMetrics, D as Destination, d as PersistentMenu, e as Dashboard, M as MetricName, f as DashboardMetricsResult, g as PublicationsSummaryResult, T as TopPublicationsResult, h as PublicationsStatsResult, i as PlanUse, j as Publication, k as AiPlanResultsSort, l as PlannerTemplateName, m as AiPlanCreateRequest, n as AiPlanCreateResult, o as AiPlan, p as AiPlanResults, q as ClientApp, r as ClientAppInput, s as SocialCapabilities, t as CommentActions, u as SocialLimits, v as PublicationLimits, w as AspectRatiosByNetwork, x as PlannerTemplate, y as CommentNetwork, z as Comment, B as CommentThread, F as CommentReplyResult, G as ContactExtraData, H as Contact, I as ContactCreate, J as ContactUpdate, K as IntegrationProviderName, L as IntegrationProvider, N as Integration, O as IntegrationConnectRequest, Q as IntegrationUpdate, R as IntegrationPickerConfig, U as IntegrationCatalogPage, V as MessageTemplate, W as Conversation, X as ConversationTotals, Y as Message, Z as MessageInput, _ as Client, $ as Organization, a0 as AiSettings, a1 as ClientWithOrganizations, a2 as AccountSelection, a3 as PlanData, a4 as PlanUseData, a5 as ConnectToken, a6 as AiContext, a7 as SocialCredentialsInput, a8 as Product, a9 as ProductInput, aa as ProductCatalog, ab as ProductCatalogInput, ac as PublicationInput, ad as PublicationState, ae as PublicationStats, af as PublicationStatsHistory, ag as Upload } from './index-DgRGeYRl.js';
2
- export { ah as AccountError, ai as AccountMetricRow, aj as AccountStateChange, ak as AccountWebhookChangeBase, al as AccountWithError, am as AiImageOrigin, an as AiPlanCostEstimate, ao as AiPlanDestination, ap as AiPlanError, aq as AiPlanNotice, ar as AiPlanOptions, as as AiPlanOptionsInput, at as AiPlanResult, au as AiPlanResultsGroup, av as AiPlanResultsTemplateGroup, aw as AiPlanSource, ax as AiPlanSourceImageInput, ay as AiPlanSourceInput, az as AiPlanSourceProduct, aA as AiPlanState, aB as ApiErrorBody, aC as AspectRatios, aD as AuthError, aE as ClientPlan, aF as CommentAuthor, aG as CommentChange, aH as ConnectSessionAccount, aI as ContactChannel, aJ as ContactError, aK as DashboardAiPlanRef, aL as DashboardPublicationRef, aM as DashboardRange, aN as EngagementBase, aO as FileError, aP as FileFormat, aQ as FileProperties, aR as FileType, aS as IntegrationCatalogProduct, aT as IntegrationConfig, aU as IntegrationError, aV as IntegrationErrorChange, aW as IntegrationFormField, aX as MessageChange, aY as MessageOptions, aZ as MessageType, a_ as MessagingError, a$ as MetricRow, b0 as NO_ERROR_CODE, b1 as OpenApiComponents, b2 as OpenApiOperations, b3 as OpenApiPaths, b4 as OpenApiWebhooks, b5 as OpenEnum, b6 as OrganizationError, b7 as PLANVORTEX_ERROR_RANGES, b8 as PlanLimitError, b9 as PlanVortexAuthenticationError, ba as PlanVortexConfigError, bb as PlanVortexConnectionError, bc as PlanVortexError, bd as PlanVortexErrorOptions, be as PlanVortexErrorRange, bf as PlannerTemplateField, bg as PlannerTemplateFieldType, bh as ProductError, bi as PublicationAiGenerated, bj as PublicationDestination, bk as PublicationError, bl as PublicationErrorDetail, bm as PublicationMetrics, bn as PublicationPending, bo as PublicationStatsPoint, bp as PublicationType, bq as PublicationsSummary, br as RssConfig, bs as SocialAuthorizationMethod, bt as SocialCredentials, bu as SocialIdentifier, bv as SocialIdentifierInput, bw as SocialLimitsMap, bx as TOKEN_ERROR_CODES, by as TopPublication, bz as UnknownWebhookChange, bA as UserError, bB as WebhookAlgorithm, bC as WebhookChange, bD as WebhookEvent, bE as WithAccount, bF as WithPublication, bG as WooCommerceConnectRequest, bH as account, bI as accountId, bJ as errorFamilyForCode, bK as isPlanVortexError, bL as isTokenError, bM as messageContact, bN as messageContactId, bO as messageDirection, bP as messageFileIds, bQ as messageFiles, bR as publication, bS as publicationId } from './index-DgRGeYRl.js';
1
+ import { P as Paginated, S as SocialNetwork, C as ConnectLink, a as ConnectResult, E as EnableResult, b as ConnectSession, A as Account, c as AccountMetrics, D as Destination, d as PublishSettings, e as PersistentMenu, f as Dashboard, M as MetricName, g as DashboardMetricsResult, h as PublicationsSummaryResult, T as TopPublicationsResult, i as PublicationsStatsResult, j as PlanUse, k as Publication, l as AiPlanResultsSort, m as PlannerTemplateName, n as AiPlanCreateRequest, o as AiPlanCreateResult, p as AiPlan, q as AiPlanResults, r as ClientApp, s as ClientAppInput, t as SocialCapabilities, u as CommentActions, v as SocialLimits, w as PublicationLimits, x as AspectRatiosByNetwork, y as PlannerTemplate, z as CommentNetwork, B as Comment, F as CommentThread, G as CommentReplyResult, H as ContactExtraData, I as Contact, J as ContactCreate, K as ContactUpdate, L as IntegrationProviderName, N as IntegrationProvider, O as Integration, Q as IntegrationConnectRequest, R as IntegrationUpdate, U as IntegrationPickerConfig, V as IntegrationCatalogPage, W as MessageTemplate, X as Conversation, Y as ConversationTotals, Z as Message, _ as MessageInput, $ as Client, a0 as Organization, a1 as AiSettings, a2 as ClientWithOrganizations, a3 as AccountSelection, a4 as PlanData, a5 as PlanUseData, a6 as ConnectToken, a7 as AiContext, a8 as SocialCredentialsInput, a9 as Product, aa as ProductInput, ab as ProductCatalog, ac as ProductCatalogInput, ad as PublicationInput, ae as PublicationState, af as PublicationStats, ag as PublicationStatsHistory, ah as Upload } from './index-6DpRjLs4.js';
2
+ export { ai as AccountError, aj as AccountMetricRow, ak as AccountStateChange, al as AccountWebhookChangeBase, am as AccountWithError, an as AiImageOrigin, ao as AiPlanCostEstimate, ap as AiPlanDestination, aq as AiPlanError, ar as AiPlanNotice, as as AiPlanOptions, at as AiPlanOptionsInput, au as AiPlanResult, av as AiPlanResultsGroup, aw as AiPlanResultsTemplateGroup, ax as AiPlanSource, ay as AiPlanSourceImageInput, az as AiPlanSourceInput, aA as AiPlanSourceProduct, aB as AiPlanState, aC as ApiErrorBody, aD as AspectRatios, aE as AuthError, aF as ClientPlan, aG as CommentAuthor, aH as CommentChange, aI as ConnectSessionAccount, aJ as ContactChannel, aK as ContactError, aL as DashboardAiPlanRef, aM as DashboardPublicationRef, aN as DashboardRange, aO as EngagementBase, aP as FileError, aQ as FileFormat, aR as FileProperties, aS as FileType, aT as IntegrationCatalogProduct, aU as IntegrationConfig, aV as IntegrationError, aW as IntegrationErrorChange, aX as IntegrationFormField, aY as MessageChange, aZ as MessageOptions, a_ as MessageType, a$ as MessagingError, b0 as MetricRow, b1 as NO_ERROR_CODE, b2 as OpenApiComponents, b3 as OpenApiOperations, b4 as OpenApiPaths, b5 as OpenApiWebhooks, b6 as OpenEnum, b7 as OrganizationError, b8 as PLANVORTEX_ERROR_RANGES, b9 as PlanLimitError, ba as PlanVortexAuthenticationError, bb as PlanVortexConfigError, bc as PlanVortexConnectionError, bd as PlanVortexError, be as PlanVortexErrorOptions, bf as PlanVortexErrorRange, bg as PlannerTemplateField, bh as PlannerTemplateFieldType, bi as ProductError, bj as PublicationAiGenerated, bk as PublicationDestination, bl as PublicationError, bm as PublicationErrorDetail, bn as PublicationMetrics, bo as PublicationPending, bp as PublicationStatsPoint, bq as PublicationType, br as PublicationsSummary, bs as RssConfig, bt as SocialAuthorizationMethod, bu as SocialCredentials, bv as SocialIdentifier, bw as SocialIdentifierInput, bx as SocialLimitsMap, by as TOKEN_ERROR_CODES, bz as TopPublication, bA as UnknownWebhookChange, bB as UserError, bC as WebhookAlgorithm, bD as WebhookChange, bE as WebhookEvent, bF as WithAccount, bG as WithPublication, bH as WooCommerceConnectRequest, bI as account, bJ as accountId, bK as errorFamilyForCode, bL as isPlanVortexError, bM as isTokenError, bN as messageContact, bO as messageContactId, bP as messageDirection, bQ as messageFileIds, bR as messageFiles, bS as publication, bT as publicationId } from './index-6DpRjLs4.js';
3
3
 
4
4
  /**
5
5
  * Las dos constantes que todo lo demás necesita. Viven aparte de `index.ts` para que `client.ts`
@@ -15,7 +15,7 @@ declare const PLANVORTEX_API_URL = "https://api.planvortex.com/v1.0.0";
15
15
  * de ejecución obliga a empaquetarlo y se rompe distinto en ESM y en CJS. La mantiene sincronizada
16
16
  * un test.
17
17
  */
18
- declare const VERSION = "0.16.0";
18
+ declare const VERSION = "0.18.0";
19
19
 
20
20
  /** `fetch` con la firma que usamos. Se puede sustituir en tests o para meter un proxy. */
21
21
  type FetchLike = (input: string, init: RequestInit) => Promise<Response>;
@@ -363,6 +363,21 @@ declare class AccountsResource extends Resource {
363
363
  * o no en la red.
364
364
  */
365
365
  destination(idOrganization: string, idAccount: string, idDestination: string, options?: AccountDestinationOptions): Promise<Destination>;
366
+ /**
367
+ * Lo que la cuenta admite AL PUBLICAR, leído de la red en el momento. Hoy sólo TikTok: las
368
+ * redes con `publish_settings` en `catalog.socialCapabilities()`; en las demás contesta 2508.
369
+ *
370
+ * Es lo que la guía de TikTok pide enseñar antes de publicar: a qué cuenta va
371
+ * (`creator.nickname`), las privacidades que admite AHORA (`visibility_options`, a ofrecer sin
372
+ * ninguna elegida de antemano), las interacciones que el creador tiene cerradas en la app
373
+ * (`interactions.*.disabled`) y el vídeo más largo que puede publicar. Léelo cada vez que se
374
+ * abre tu pantalla de publicar: una cuenta pasa de pública a privada entre medias.
375
+ *
376
+ * `can_post: false` es que TikTok no acepta ahora un post de esta cuenta (`reason` trae su
377
+ * código): di que se intente más tarde en vez de mandarlo. Si TikTok no contesta es el 919,
378
+ * nunca una lista vacía.
379
+ */
380
+ publishSettings(idOrganization: string, idAccount: string, options?: RequestOptions): Promise<PublishSettings>;
366
381
  /**
367
382
  * El menú fijo del chat, una entrada por idioma.
368
383
  *
@@ -2265,4 +2280,4 @@ interface AuthProvider {
2265
2280
  /** Margen con el que se pide un token nuevo antes de que caduque el que hay. */
2266
2281
  declare const TOKEN_REFRESH_MARGIN_MS = 60000;
2267
2282
 
2268
- export { Account, type AccountCapability, type AccountDestinationOptions, type AccountListOptions, AccountMetrics, type AccountMetricsOptions, AccountSelection, AccountsResource, AiContext, AiPlan, AiPlanCreateRequest, AiPlanCreateResult, type AiPlanListOptions, type AiPlanRegenerateResult, type AiPlanRegenerateTarget, AiPlanResults, type AiPlanResultsOptions, AiPlanResultsSort, AiPlansResource, AiSettings, AppsResource, AspectRatiosByNetwork, type AuthProvider, CatalogResource, type ChildOrganizationListOptions, Client, ClientApp, ClientAppInput, type ClientCredentialsToken, type ClientListOptions, ClientWithOrganizations, ClientsResource, Comment, CommentActions, type CommentListOptions, CommentNetwork, CommentReplyResult, CommentThread, type CommentThreadOptions, type CommentUpdate, CommentsResource, type ConnectCallbackParams, ConnectLink, type ConnectLinkOptions, type ConnectLinksOptions, ConnectResult, ConnectSession, ConnectToken, type ConnectTokenOptions, Contact, ContactCreate, ContactExtraData, type ContactExtraFilter, type ContactListOptions, ContactUpdate, ContactsResource, Conversation, type ConversationGroupBy, ConversationTotals, type ConversationTotalsOptions, DEFAULT_PAGE_SIZE, DEFAULT_RETRY, DEFAULT_TIMEOUT_MS, Dashboard, DashboardMetricsResult, DashboardResource, Destination, EnableResult, type FetchLike, type FileInput, type FileSource, type HttpHooks, type HttpMethod, type HttpRequest, type HttpResponse, type ImportError, type ImportFileInput, type ImportResult, Integration, IntegrationCatalogPage, IntegrationConnectRequest, type IntegrationListOptions, IntegrationPickerConfig, type IntegrationProductsOptions, IntegrationProvider, IntegrationProviderName, IntegrationUpdate, IntegrationsResource, MAX_PAGES, Message, MessageInput, MessageTemplate, type MessageTemplateResult, MessagesResource, MetricName, type MetricsGroupBy, type MetricsOptions, Organization, type OrganizationInput, type OrganizationListOptions, type OrganizationOptions, type OrganizationPlanInput, OrganizationsResource, PLANVORTEX_API_URL, type PageOptions, Paginated, PersistentMenu, PlanData, PlanUse, PlanUseData, PlanVortex, type PlanVortexOptions, PlannerTemplate, PlannerTemplateName, Product, ProductCatalog, ProductCatalogInput, ProductInput, ProductsResource, Publication, PublicationInput, PublicationLimits, type PublicationListOptions, type PublicationRetryResult, PublicationState, PublicationStats, PublicationStatsHistory, PublicationsResource, type PublicationsStatsOptions, PublicationsStatsResult, PublicationsSummaryResult, type QueryValue, type RangeOptions, type RequestInfo, type RequestOptions, type RequestSender, type ResponseInfo, type RetryConfig, type RetryInfo, SocialCapabilities, SocialLimits, SocialNetwork, TOKEN_REFRESH_MARGIN_MS, type TopPublicationsOptions, TopPublicationsResult, Upload, type UploadUpdate, UploadsResource, VERSION, guessContentType };
2283
+ export { Account, type AccountCapability, type AccountDestinationOptions, type AccountListOptions, AccountMetrics, type AccountMetricsOptions, AccountSelection, AccountsResource, AiContext, AiPlan, AiPlanCreateRequest, AiPlanCreateResult, type AiPlanListOptions, type AiPlanRegenerateResult, type AiPlanRegenerateTarget, AiPlanResults, type AiPlanResultsOptions, AiPlanResultsSort, AiPlansResource, AiSettings, AppsResource, AspectRatiosByNetwork, type AuthProvider, CatalogResource, type ChildOrganizationListOptions, Client, ClientApp, ClientAppInput, type ClientCredentialsToken, type ClientListOptions, ClientWithOrganizations, ClientsResource, Comment, CommentActions, type CommentListOptions, CommentNetwork, CommentReplyResult, CommentThread, type CommentThreadOptions, type CommentUpdate, CommentsResource, type ConnectCallbackParams, ConnectLink, type ConnectLinkOptions, type ConnectLinksOptions, ConnectResult, ConnectSession, ConnectToken, type ConnectTokenOptions, Contact, ContactCreate, ContactExtraData, type ContactExtraFilter, type ContactListOptions, ContactUpdate, ContactsResource, Conversation, type ConversationGroupBy, ConversationTotals, type ConversationTotalsOptions, DEFAULT_PAGE_SIZE, DEFAULT_RETRY, DEFAULT_TIMEOUT_MS, Dashboard, DashboardMetricsResult, DashboardResource, Destination, EnableResult, type FetchLike, type FileInput, type FileSource, type HttpHooks, type HttpMethod, type HttpRequest, type HttpResponse, type ImportError, type ImportFileInput, type ImportResult, Integration, IntegrationCatalogPage, IntegrationConnectRequest, type IntegrationListOptions, IntegrationPickerConfig, type IntegrationProductsOptions, IntegrationProvider, IntegrationProviderName, IntegrationUpdate, IntegrationsResource, MAX_PAGES, Message, MessageInput, MessageTemplate, type MessageTemplateResult, MessagesResource, MetricName, type MetricsGroupBy, type MetricsOptions, Organization, type OrganizationInput, type OrganizationListOptions, type OrganizationOptions, type OrganizationPlanInput, OrganizationsResource, PLANVORTEX_API_URL, type PageOptions, Paginated, PersistentMenu, PlanData, PlanUse, PlanUseData, PlanVortex, type PlanVortexOptions, PlannerTemplate, PlannerTemplateName, Product, ProductCatalog, ProductCatalogInput, ProductInput, ProductsResource, Publication, PublicationInput, PublicationLimits, type PublicationListOptions, type PublicationRetryResult, PublicationState, PublicationStats, PublicationStatsHistory, PublicationsResource, type PublicationsStatsOptions, PublicationsStatsResult, PublicationsSummaryResult, PublishSettings, type QueryValue, type RangeOptions, type RequestInfo, type RequestOptions, type RequestSender, type ResponseInfo, type RetryConfig, type RetryInfo, SocialCapabilities, SocialLimits, SocialNetwork, TOKEN_REFRESH_MARGIN_MS, type TopPublicationsOptions, TopPublicationsResult, Upload, type UploadUpdate, UploadsResource, VERSION, guessContentType };
package/dist/index.js CHANGED
@@ -1,10 +1,10 @@
1
- import { createErrorFromResponse, NO_ERROR_CODE, PlanVortexError, PlanVortexConfigError, isTokenError, PlanVortexConnectionError, PlanVortexAuthenticationError, isPlanVortexError } from './chunk-CXCJAVXQ.js';
2
- export { AccountError, AiPlanError, AuthError, ContactError, FileError, IntegrationError, MessagingError, NO_ERROR_CODE, OrganizationError, PLANVORTEX_ERROR_RANGES, PlanLimitError, PlanVortexAuthenticationError, PlanVortexConfigError, PlanVortexConnectionError, PlanVortexError, ProductError, PublicationError, TOKEN_ERROR_CODES, UserError, errorFamilyForCode, isPlanVortexError, isTokenError } from './chunk-CXCJAVXQ.js';
1
+ import { createErrorFromResponse, NO_ERROR_CODE, PlanVortexError, PlanVortexConfigError, isTokenError, PlanVortexConnectionError, PlanVortexAuthenticationError, isPlanVortexError } from './chunk-ZHS7FY3T.js';
2
+ export { AccountError, AiPlanError, AuthError, ContactError, FileError, IntegrationError, MessagingError, NO_ERROR_CODE, OrganizationError, PLANVORTEX_ERROR_RANGES, PlanLimitError, PlanVortexAuthenticationError, PlanVortexConfigError, PlanVortexConnectionError, PlanVortexError, ProductError, PublicationError, TOKEN_ERROR_CODES, UserError, errorFamilyForCode, isPlanVortexError, isTokenError } from './chunk-ZHS7FY3T.js';
3
3
  import { basename } from 'path';
4
4
 
5
5
  // src/version.ts
6
6
  var PLANVORTEX_API_URL = "https://api.planvortex.com/v1.0.0";
7
- var VERSION = "0.16.0";
7
+ var VERSION = "0.18.0";
8
8
 
9
9
  // src/core/auth.ts
10
10
  var TOKEN_REFRESH_MARGIN_MS = 6e4;
@@ -699,6 +699,30 @@ var AccountsResource = class extends Resource {
699
699
  "destination"
700
700
  );
701
701
  }
702
+ /**
703
+ * Lo que la cuenta admite AL PUBLICAR, leído de la red en el momento. Hoy sólo TikTok: las
704
+ * redes con `publish_settings` en `catalog.socialCapabilities()`; en las demás contesta 2508.
705
+ *
706
+ * Es lo que la guía de TikTok pide enseñar antes de publicar: a qué cuenta va
707
+ * (`creator.nickname`), las privacidades que admite AHORA (`visibility_options`, a ofrecer sin
708
+ * ninguna elegida de antemano), las interacciones que el creador tiene cerradas en la app
709
+ * (`interactions.*.disabled`) y el vídeo más largo que puede publicar. Léelo cada vez que se
710
+ * abre tu pantalla de publicar: una cuenta pasa de pública a privada entre medias.
711
+ *
712
+ * `can_post: false` es que TikTok no acepta ahora un post de esta cuenta (`reason` trae su
713
+ * código): di que se intente más tarde en vez de mandarlo. Si TikTok no contesta es el 919,
714
+ * nunca una lista vacía.
715
+ */
716
+ async publishSettings(idOrganization, idAccount, options = {}) {
717
+ return unwrapOne(
718
+ await this.httpGet(
719
+ `${this.path(idOrganization, idAccount)}/publish_settings`,
720
+ void 0,
721
+ options
722
+ ),
723
+ "publish_settings"
724
+ );
725
+ }
702
726
  /**
703
727
  * El menú fijo del chat, una entrada por idioma.
704
728
  *