@apotech-os/cli 7.6.0 → 7.7.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.js CHANGED
@@ -23855,22 +23855,26 @@ var INTEGRATION_CATALOG = {
23855
23855
  {
23856
23856
  name: "write_inbound_shipments",
23857
23857
  label: "G\xE9rer les r\xE9ceptions de marchandise",
23858
- description: "D\xE9clarer, modifier et supprimer des r\xE9ceptions fournisseurs. Une r\xE9ception finalis\xE9e est transmise \xE0 l\u2019entrep\xF4t, qui planifie un quai."
23858
+ description: "D\xE9clarer, modifier et supprimer des r\xE9ceptions fournisseurs. Une r\xE9ception finalis\xE9e est transmise \xE0 l\u2019entrep\xF4t, qui planifie un quai.",
23859
+ implies: ["read_inbound_shipments"]
23859
23860
  },
23860
23861
  {
23861
23862
  name: "write_orders",
23862
23863
  label: "Cr\xE9er, modifier et annuler des commandes",
23863
- description: "Envoyer une commande \xE0 pr\xE9parer et \xE0 exp\xE9dier par l\u2019entrep\xF4t (avec l\u2019adresse et les coordonn\xE9es du destinataire), la modifier avant sa pr\xE9paration, ou l\u2019annuler."
23864
+ description: "Envoyer une commande \xE0 pr\xE9parer et \xE0 exp\xE9dier par l\u2019entrep\xF4t (avec l\u2019adresse et les coordonn\xE9es du destinataire), la modifier avant sa pr\xE9paration, ou l\u2019annuler.",
23865
+ implies: ["read_orders"]
23864
23866
  },
23865
23867
  {
23866
23868
  name: "write_products",
23867
23869
  label: "Modifier le catalogue logistique",
23868
- description: "Cr\xE9er, modifier et supprimer des produits et des bundles chez Bigblue. Un produit d\xE9j\xE0 stock\xE9 ne peut pas \xEAtre supprim\xE9."
23870
+ description: "Cr\xE9er, modifier et supprimer des produits et des bundles chez Bigblue. Un produit d\xE9j\xE0 stock\xE9 ne peut pas \xEAtre supprim\xE9.",
23871
+ implies: ["read_products"]
23869
23872
  },
23870
23873
  {
23871
23874
  name: "write_returns",
23872
23875
  label: "G\xE9rer les retours",
23873
- description: "D\xE9clarer un retour et en modifier la r\xE9solution (moyen de remboursement, statut)."
23876
+ description: "D\xE9clarer un retour et en modifier la r\xE9solution (moyen de remboursement, statut).",
23877
+ implies: ["read_returns"]
23874
23878
  }
23875
23879
  ],
23876
23880
  actions: {
@@ -24461,7 +24465,8 @@ var INTEGRATION_CATALOG = {
24461
24465
  {
24462
24466
  name: "write_drive_files",
24463
24467
  label: "D\xE9poser des fichiers dans les dossiers Drive autoris\xE9s",
24464
- description: "Cr\xE9er des dossiers et d\xE9poser de NOUVEAUX fichiers dans les dossiers autoris\xE9s. Jamais d\u2019\xE9crasement, de renommage, de d\xE9placement, de suppression ni de changement de partage."
24468
+ description: "Cr\xE9er des dossiers et d\xE9poser de NOUVEAUX fichiers dans les dossiers autoris\xE9s. Jamais d\u2019\xE9crasement, de renommage, de d\xE9placement, de suppression ni de changement de partage.",
24469
+ implies: ["read_drive_files"]
24465
24470
  }
24466
24471
  ],
24467
24472
  actions: {
@@ -24561,12 +24566,14 @@ var INTEGRATION_CATALOG = {
24561
24566
  {
24562
24567
  name: "write_sitemaps",
24563
24568
  label: "G\xE9rer les sitemaps",
24564
- description: "Soumettre un sitemap ou retirer sa d\xE9claration de Search Console, sans supprimer le fichier."
24569
+ description: "Soumettre un sitemap ou retirer sa d\xE9claration de Search Console, sans supprimer le fichier.",
24570
+ implies: ["read_sitemaps"]
24565
24571
  },
24566
24572
  {
24567
24573
  name: "write_sites",
24568
24574
  label: "G\xE9rer les propri\xE9t\xE9s",
24569
- description: "Ajouter ou retirer une propri\xE9t\xE9 du compte Google connect\xE9, sans v\xE9rifier sa propri\xE9t\xE9 ni supprimer le site web."
24575
+ description: "Ajouter ou retirer une propri\xE9t\xE9 du compte Google connect\xE9, sans v\xE9rifier sa propri\xE9t\xE9 ni supprimer le site web.",
24576
+ implies: ["read_sites"]
24570
24577
  }
24571
24578
  ],
24572
24579
  actions: {
@@ -24728,7 +24735,8 @@ var INTEGRATION_CATALOG = {
24728
24735
  {
24729
24736
  name: "write_spreadsheets",
24730
24737
  label: "\xC9crire dans les Google Sheets partag\xE9s",
24731
- description: "Ajouter des lignes et mettre \xE0 jour des valeurs dans les fichiers partag\xE9s en \xC9diteur avec le compte de service. Ni suppression, ni effacement, ni changement de structure."
24738
+ description: "Ajouter des lignes et mettre \xE0 jour des valeurs dans les fichiers partag\xE9s en \xC9diteur avec le compte de service. Ni suppression, ni effacement, ni changement de structure.",
24739
+ implies: ["read_spreadsheets"]
24732
24740
  }
24733
24741
  ],
24734
24742
  actions: {
@@ -24832,17 +24840,20 @@ var INTEGRATION_CATALOG = {
24832
24840
  {
24833
24841
  name: "write_customers",
24834
24842
  label: "\xC9crire les clients du support",
24835
- description: "Cr\xE9er ou modifier une fiche client du support."
24843
+ description: "Cr\xE9er ou modifier une fiche client du support.",
24844
+ implies: ["read_customers"]
24836
24845
  },
24837
24846
  {
24838
24847
  name: "write_tags",
24839
24848
  label: "\xC9crire les \xE9tiquettes",
24840
- description: "Poser une \xE9tiquette sur un ticket, en cr\xE9er une si besoin."
24849
+ description: "Poser une \xE9tiquette sur un ticket, en cr\xE9er une si besoin.",
24850
+ implies: ["read_tags"]
24841
24851
  },
24842
24852
  {
24843
24853
  name: "write_tickets",
24844
24854
  label: "\xC9crire les tickets",
24845
- description: "R\xE9pondre \xE0 un ticket, le renommer, changer son statut ou son assign\xE9."
24855
+ description: "R\xE9pondre \xE0 un ticket, le renommer, changer son statut ou son assign\xE9.",
24856
+ implies: ["read_tickets"]
24846
24857
  },
24847
24858
  {
24848
24859
  name: "write_widgets",
@@ -25144,12 +25155,14 @@ var INTEGRATION_CATALOG = {
25144
25155
  {
25145
25156
  name: "write_reviewers",
25146
25157
  label: "Modifier les auteurs d\u2019avis",
25147
- description: "Modifier l\u2019identit\xE9, les tags et le consentement marketing d\u2019un auteur d\u2019avis."
25158
+ description: "Modifier l\u2019identit\xE9, les tags et le consentement marketing d\u2019un auteur d\u2019avis.",
25159
+ implies: ["read_reviewers"]
25148
25160
  },
25149
25161
  {
25150
25162
  name: "write_reviews",
25151
25163
  label: "Mod\xE9rer et cr\xE9er des avis",
25152
- description: "Publier ou masquer un avis existant, et d\xE9poser un nouvel avis au nom d\u2019un client."
25164
+ description: "Publier ou masquer un avis existant, et d\xE9poser un nouvel avis au nom d\u2019un client.",
25165
+ implies: ["read_reviews"]
25153
25166
  }
25154
25167
  ],
25155
25168
  actions: {
@@ -25346,57 +25359,68 @@ var INTEGRATION_CATALOG = {
25346
25359
  {
25347
25360
  name: "write_campaigns",
25348
25361
  label: "\xC9crire les campagnes",
25349
- description: "Cr\xE9er, modifier, planifier ou envoyer une campagne."
25362
+ description: "Cr\xE9er, modifier, planifier ou envoyer une campagne.",
25363
+ implies: ["read_campaigns"]
25350
25364
  },
25351
25365
  {
25352
25366
  name: "write_catalogs",
25353
25367
  label: "\xC9crire le catalogue",
25354
- description: "Cr\xE9er ou modifier un article, une variante ou une cat\xE9gorie."
25368
+ description: "Cr\xE9er ou modifier un article, une variante ou une cat\xE9gorie.",
25369
+ implies: ["read_catalogs"]
25355
25370
  },
25356
25371
  {
25357
25372
  name: "write_coupons",
25358
25373
  label: "\xC9crire les coupons",
25359
- description: "Cr\xE9er ou modifier un coupon et ses codes."
25374
+ description: "Cr\xE9er ou modifier un coupon et ses codes.",
25375
+ implies: ["read_coupons"]
25360
25376
  },
25361
25377
  {
25362
25378
  name: "write_events",
25363
25379
  label: "\xC9mettre des \xE9v\xE9nements",
25364
- description: "Enregistrer un \xE9v\xE9nement de suivi sur un profil."
25380
+ description: "Enregistrer un \xE9v\xE9nement de suivi sur un profil.",
25381
+ implies: ["read_events"]
25365
25382
  },
25366
25383
  {
25367
25384
  name: "write_flows",
25368
25385
  label: "\xC9crire les sc\xE9narios",
25369
- description: "Modifier le statut ou les actions d\u2019un sc\xE9nario."
25386
+ description: "Modifier le statut ou les actions d\u2019un sc\xE9nario.",
25387
+ implies: ["read_flows"]
25370
25388
  },
25371
25389
  {
25372
25390
  name: "write_images",
25373
25391
  label: "T\xE9l\xE9verser des images",
25374
- description: "Ajouter ou renommer une image de la biblioth\xE8que."
25392
+ description: "Ajouter ou renommer une image de la biblioth\xE8que.",
25393
+ implies: ["read_images"]
25375
25394
  },
25376
25395
  {
25377
25396
  name: "write_lists",
25378
25397
  label: "\xC9crire les listes",
25379
- description: "Cr\xE9er une liste, y ajouter ou en retirer des profils."
25398
+ description: "Cr\xE9er une liste, y ajouter ou en retirer des profils.",
25399
+ implies: ["read_lists"]
25380
25400
  },
25381
25401
  {
25382
25402
  name: "write_profiles",
25383
25403
  label: "\xC9crire les profils",
25384
- description: "Cr\xE9er, modifier ou fusionner un profil, g\xE9rer ses consentements."
25404
+ description: "Cr\xE9er, modifier ou fusionner un profil, g\xE9rer ses consentements.",
25405
+ implies: ["read_profiles"]
25385
25406
  },
25386
25407
  {
25387
25408
  name: "write_segments",
25388
25409
  label: "\xC9crire les segments",
25389
- description: "Cr\xE9er ou modifier un segment et sa d\xE9finition."
25410
+ description: "Cr\xE9er ou modifier un segment et sa d\xE9finition.",
25411
+ implies: ["read_segments"]
25390
25412
  },
25391
25413
  {
25392
25414
  name: "write_tags",
25393
25415
  label: "\xC9crire les \xE9tiquettes",
25394
- description: "Cr\xE9er une \xE9tiquette et la poser sur une campagne ou un sc\xE9nario."
25416
+ description: "Cr\xE9er une \xE9tiquette et la poser sur une campagne ou un sc\xE9nario.",
25417
+ implies: ["read_tags"]
25395
25418
  },
25396
25419
  {
25397
25420
  name: "write_templates",
25398
25421
  label: "\xC9crire les mod\xE8les",
25399
- description: "Cr\xE9er, modifier ou rendre un mod\xE8le d\u2019e-mail."
25422
+ description: "Cr\xE9er, modifier ou rendre un mod\xE8le d\u2019e-mail.",
25423
+ implies: ["read_templates"]
25400
25424
  }
25401
25425
  ],
25402
25426
  actions: {
@@ -25600,6 +25624,13 @@ var INTEGRATION_CATALOG = {
25600
25624
  }
25601
25625
  ],
25602
25626
  actions: {
25627
+ getAd: {
25628
+ description: "Read one Meta ad (status, ad set, creative id) of the connected ad account by id.",
25629
+ destructive: false,
25630
+ agentExposable: true,
25631
+ requiresApproval: false,
25632
+ scopes: ["read_ads"]
25633
+ },
25603
25634
  getAdAccount: {
25604
25635
  description: "Get the configured Meta ad account identity, status, currency and timezone.",
25605
25636
  destructive: false,
@@ -25607,6 +25638,20 @@ var INTEGRATION_CATALOG = {
25607
25638
  requiresApproval: false,
25608
25639
  scopes: ["read_adaccounts"]
25609
25640
  },
25641
+ getAdCreative: {
25642
+ description: "Read one Meta ad creative (texts, links, object type, video id, underlying Facebook / Instagram post ids) by id.",
25643
+ destructive: false,
25644
+ agentExposable: true,
25645
+ requiresApproval: false,
25646
+ scopes: ["read_adcreatives"]
25647
+ },
25648
+ getAdSet: {
25649
+ description: "Read one Meta ad set (targeting, budget, optimisation) of the connected ad account by id.",
25650
+ destructive: false,
25651
+ agentExposable: true,
25652
+ requiresApproval: false,
25653
+ scopes: ["read_adsets"]
25654
+ },
25610
25655
  getAdsInsights: {
25611
25656
  description: "Meta Ads performance at campaign, ad set or ad level, optionally split by age, gender, country, region, placement or device. Row count multiplies with level, breakdowns and daily granularity.",
25612
25657
  destructive: false,
@@ -25614,6 +25659,20 @@ var INTEGRATION_CATALOG = {
25614
25659
  requiresApproval: false,
25615
25660
  scopes: ["read_ads", "read_adsets", "read_campaigns", "read_insights"]
25616
25661
  },
25662
+ getAdVideo: {
25663
+ description: "Get the video of a Meta ad: a signed, short-lived playable `source` link, thumbnail and duration \u2014 or `hasVideo: false` with the reason (image, carousel). Read on demand; never store the links.",
25664
+ destructive: false,
25665
+ agentExposable: false,
25666
+ requiresApproval: false,
25667
+ scopes: ["read_adassets", "read_adcreatives", "read_ads"]
25668
+ },
25669
+ getCampaign: {
25670
+ description: "Read one Meta campaign of the connected ad account by id.",
25671
+ destructive: false,
25672
+ agentExposable: true,
25673
+ requiresApproval: false,
25674
+ scopes: ["read_campaigns"]
25675
+ },
25617
25676
  getCampaignInsights: {
25618
25677
  description: "Get campaign performance for an inclusive date range, as totals or daily rows.",
25619
25678
  destructive: false,
@@ -25621,6 +25680,13 @@ var INTEGRATION_CATALOG = {
25621
25680
  requiresApproval: false,
25622
25681
  scopes: ["read_campaigns", "read_insights"]
25623
25682
  },
25683
+ getCustomAudience: {
25684
+ description: "Read one custom or lookalike audience of the connected ad account by id.",
25685
+ destructive: false,
25686
+ agentExposable: true,
25687
+ requiresApproval: false,
25688
+ scopes: ["read_audiences"]
25689
+ },
25624
25690
  getFacebookPageAudience: {
25625
25691
  description: "Facebook Page follower demographics by city and country. Meta retired age and gender for Pages, so those come back null.",
25626
25692
  destructive: false,
@@ -25656,6 +25722,27 @@ var INTEGRATION_CATALOG = {
25656
25722
  requiresApproval: false,
25657
25723
  scopes: ["read_social_insights"]
25658
25724
  },
25725
+ getInstagramMedia: {
25726
+ description: "Read one media of the connected Instagram professional account by id (e.g. an ad creative effective_instagram_media_id).",
25727
+ destructive: false,
25728
+ agentExposable: true,
25729
+ requiresApproval: false,
25730
+ scopes: ["read_social_content"]
25731
+ },
25732
+ getPagePost: {
25733
+ description: "Read one post of the connected Facebook Page by id (`{pageId}_{postId}`, e.g. an ad creative effective_object_story_id).",
25734
+ destructive: false,
25735
+ agentExposable: true,
25736
+ requiresApproval: false,
25737
+ scopes: ["read_social_content"]
25738
+ },
25739
+ getVideo: {
25740
+ description: "Read one video owned by the connected Facebook Page by id: signed, short-lived playable `source` link, thumbnail and duration. Never store the links. For the video of an ad, use getAdVideo.",
25741
+ destructive: false,
25742
+ agentExposable: false,
25743
+ requiresApproval: false,
25744
+ scopes: ["read_adassets"]
25745
+ },
25659
25746
  listAds: {
25660
25747
  description: "List Meta ads with their status and creative (name and thumbnail).",
25661
25748
  destructive: false,
@@ -25765,7 +25852,8 @@ var INTEGRATION_CATALOG = {
25765
25852
  {
25766
25853
  name: "read_items",
25767
25854
  label: "Lire les items",
25768
- description: "Consulter les items des boards, leurs sous-\xE9l\xE9ments et les valeurs de leurs colonnes."
25855
+ description: "Consulter les items des boards, leurs sous-\xE9l\xE9ments et les valeurs de leurs colonnes.",
25856
+ implies: ["read_boards"]
25769
25857
  },
25770
25858
  {
25771
25859
  name: "read_updates",
@@ -25780,12 +25868,14 @@ var INTEGRATION_CATALOG = {
25780
25868
  {
25781
25869
  name: "write_items",
25782
25870
  label: "Cr\xE9er et modifier des items",
25783
- description: "Cr\xE9er un item ou un sous-\xE9l\xE9ment, modifier les valeurs de ses colonnes, le d\xE9placer de groupe. Sans suppression ni archivage."
25871
+ description: "Cr\xE9er un item ou un sous-\xE9l\xE9ment, modifier les valeurs de ses colonnes, le d\xE9placer de groupe. Sans suppression ni archivage.",
25872
+ implies: ["read_boards", "read_items"]
25784
25873
  },
25785
25874
  {
25786
25875
  name: "write_updates",
25787
25876
  label: "Publier des commentaires",
25788
- description: "Poster une update sur un item, r\xE9pondre \xE0 une update ou modifier une update publi\xE9e par le compte."
25877
+ description: "Poster une update sur un item, r\xE9pondre \xE0 une update ou modifier une update publi\xE9e par le compte.",
25878
+ implies: ["read_updates"]
25789
25879
  }
25790
25880
  ],
25791
25881
  actions: {
@@ -26348,52 +26438,62 @@ var INTEGRATION_CATALOG = {
26348
26438
  {
26349
26439
  name: "write_activities",
26350
26440
  label: "\xC9crire les activit\xE9s",
26351
- description: "Cr\xE9er ou modifier une activit\xE9."
26441
+ description: "Cr\xE9er ou modifier une activit\xE9.",
26442
+ implies: ["read_activities"]
26352
26443
  },
26353
26444
  {
26354
26445
  name: "write_deals",
26355
26446
  label: "\xC9crire les affaires",
26356
- description: "Cr\xE9er ou modifier une affaire et ses champs personnalis\xE9s."
26447
+ description: "Cr\xE9er ou modifier une affaire et ses champs personnalis\xE9s.",
26448
+ implies: ["read_deals"]
26357
26449
  },
26358
26450
  {
26359
26451
  name: "write_files",
26360
26452
  label: "\xC9crire les fichiers",
26361
- description: "Joindre ou remplacer un fichier."
26453
+ description: "Joindre ou remplacer un fichier.",
26454
+ implies: ["read_files"]
26362
26455
  },
26363
26456
  {
26364
26457
  name: "write_leads",
26365
26458
  label: "\xC9crire les prospects",
26366
- description: "Cr\xE9er ou modifier un prospect et le convertir en affaire."
26459
+ description: "Cr\xE9er ou modifier un prospect et le convertir en affaire.",
26460
+ implies: ["read_leads"]
26367
26461
  },
26368
26462
  {
26369
26463
  name: "write_notes",
26370
26464
  label: "\xC9crire les notes",
26371
- description: "Ajouter ou modifier une note."
26465
+ description: "Ajouter ou modifier une note.",
26466
+ implies: ["read_notes"]
26372
26467
  },
26373
26468
  {
26374
26469
  name: "write_organizations",
26375
26470
  label: "\xC9crire les organisations",
26376
- description: "Cr\xE9er ou modifier une organisation."
26471
+ description: "Cr\xE9er ou modifier une organisation.",
26472
+ implies: ["read_organizations"]
26377
26473
  },
26378
26474
  {
26379
26475
  name: "write_persons",
26380
26476
  label: "\xC9crire les personnes",
26381
- description: "Cr\xE9er ou modifier une fiche personne."
26477
+ description: "Cr\xE9er ou modifier une fiche personne.",
26478
+ implies: ["read_persons"]
26382
26479
  },
26383
26480
  {
26384
26481
  name: "write_products",
26385
26482
  label: "\xC9crire les produits",
26386
- description: "Cr\xE9er ou modifier un produit et l\u2019attacher \xE0 une affaire."
26483
+ description: "Cr\xE9er ou modifier un produit et l\u2019attacher \xE0 une affaire.",
26484
+ implies: ["read_products"]
26387
26485
  },
26388
26486
  {
26389
26487
  name: "write_projects",
26390
26488
  label: "\xC9crire les projets",
26391
- description: "Cr\xE9er ou modifier un projet et ses phases."
26489
+ description: "Cr\xE9er ou modifier un projet et ses phases.",
26490
+ implies: ["read_projects"]
26392
26491
  },
26393
26492
  {
26394
26493
  name: "write_tasks",
26395
26494
  label: "\xC9crire les t\xE2ches",
26396
- description: "Cr\xE9er ou modifier une t\xE2che de projet."
26495
+ description: "Cr\xE9er ou modifier une t\xE2che de projet.",
26496
+ implies: ["read_tasks"]
26397
26497
  }
26398
26498
  ],
26399
26499
  actions: {
@@ -26618,6 +26718,175 @@ var INTEGRATION_CATALOG = {
26618
26718
  }
26619
26719
  }
26620
26720
  },
26721
+ ringover: {
26722
+ displayName: "Ringover",
26723
+ description: "T\xE9l\xE9phonie cloud \u2014 historique et transcriptions d\u2019appels, appels en cours, SMS, contacts, utilisateurs et num\xE9ros de l\u2019\xE9quipe.",
26724
+ authKind: "api_key",
26725
+ events: [],
26726
+ hasWebhooks: false,
26727
+ supportsGenericRequest: true,
26728
+ scopeCatalog: [
26729
+ {
26730
+ name: "read_calls",
26731
+ label: "Lire les appels",
26732
+ description: "Consulter l\u2019historique des appels de TOUTE l\u2019\xE9quipe, quels que soient les r\xE9glages de la cl\xE9 (num\xE9ros, dur\xE9es, statut, notes, tags, liens d\u2019enregistrement et de messagerie vocale), leurs r\xE9sum\xE9s et transcriptions, et les appels en cours."
26733
+ },
26734
+ {
26735
+ name: "read_contacts",
26736
+ label: "Lire les contacts",
26737
+ description: "Consulter le carnet d\u2019adresses Ringover : noms, soci\xE9t\xE9s, num\xE9ros et emails."
26738
+ },
26739
+ {
26740
+ name: "read_messages",
26741
+ label: "Lire les SMS",
26742
+ description: "Consulter les conversations SMS et de chat, leurs participants et leurs messages."
26743
+ },
26744
+ {
26745
+ name: "read_users",
26746
+ label: "Lire l\u2019\xE9quipe t\xE9l\xE9phonique",
26747
+ description: "Consulter les utilisateurs, groupes d\u2019appel et num\xE9ros de l\u2019\xE9quipe, ainsi que la pr\xE9sence de chacun (en ligne, en communication, ne pas d\xE9ranger)."
26748
+ },
26749
+ {
26750
+ name: "write_calls",
26751
+ label: "D\xE9clencher des rappels",
26752
+ description: "Lancer un appel sortant par rappel : le poste de l\u2019utilisateur de la cl\xE9 sonne, puis le num\xE9ro du destinataire est compos\xE9. Chaque rappel est factur\xE9 par Ringover.",
26753
+ implies: ["read_calls"]
26754
+ },
26755
+ {
26756
+ name: "write_contacts",
26757
+ label: "Cr\xE9er et modifier les contacts",
26758
+ description: "Ajouter des contacts au carnet d\u2019adresses Ringover et modifier leurs informations.",
26759
+ implies: ["read_contacts"]
26760
+ },
26761
+ {
26762
+ name: "write_messages",
26763
+ label: "Envoyer des SMS",
26764
+ description: "Envoyer des SMS depuis un num\xE9ro de l\u2019\xE9quipe et g\xE9rer les conversations (archivage, renommage). Chaque SMS est factur\xE9 par Ringover.",
26765
+ implies: ["read_messages"]
26766
+ }
26767
+ ],
26768
+ actions: {
26769
+ createCallback: {
26770
+ description: "Start an outbound call by callback: the API key owner\u2019s phone rings first, then `to` (E.164) is dialled once they pick up. `from` (E.164, a team number) sets the presented number. Billed by Ringover. Returns the call id as a string.",
26771
+ destructive: true,
26772
+ agentExposable: true,
26773
+ requiresApproval: true,
26774
+ scopes: ["write_calls"]
26775
+ },
26776
+ createContact: {
26777
+ description: "Create an address-book contact with at least one E.164 number. `shared: true` makes it visible to the whole team. Returns the stored contact.",
26778
+ destructive: true,
26779
+ agentExposable: true,
26780
+ requiresApproval: false,
26781
+ scopes: ["write_contacts"]
26782
+ },
26783
+ getCall: {
26784
+ description: "Get one call by `callId` with ALL its legs (one row per CDR: transfers, group ringing, voicemail).",
26785
+ destructive: false,
26786
+ agentExposable: true,
26787
+ requiresApproval: false,
26788
+ scopes: ["read_calls"]
26789
+ },
26790
+ getContact: {
26791
+ description: "Get one contact by numeric `contactId`.",
26792
+ destructive: false,
26793
+ agentExposable: true,
26794
+ requiresApproval: false,
26795
+ scopes: ["read_contacts"]
26796
+ },
26797
+ getUser: {
26798
+ description: "Get one user by numeric `userId`.",
26799
+ destructive: false,
26800
+ agentExposable: true,
26801
+ requiresApproval: false,
26802
+ scopes: ["read_users"]
26803
+ },
26804
+ listCalls: {
26805
+ description: "List terminated calls, most recent first: direction, final state (ANSWERED, MISSED, VOICEMAIL\u2026), numbers, user, contact, IVR, durations (total, talk, ringing, queue, hold), note, tags, recording and voicemail links. `startDate` and `endDate` go together and span at most 15 days (default: last 15 days). `include` adds the AI summary and/or transcript. Offset-paginated: pass back `nextOffset` as `offset` for the next page. Past offset 9000 Ringover refuses the request: `hasMore` stays true with `nextOffset: null` \u2014 narrow the date window instead. Returns ALL team calls whatever the key\u2019s Monitoring flag.",
26806
+ destructive: false,
26807
+ agentExposable: true,
26808
+ requiresApproval: false,
26809
+ scopes: ["read_calls"]
26810
+ },
26811
+ listContacts: {
26812
+ description: "List address-book contacts (own and shared). `search` (2+ characters) matches first name, last name, company and number \u2014 prefer it to paging: Ringover returns contacts in NO stable order, so offset pages can overlap or skip contacts and `total` is unknown. Up to 500 per page.",
26813
+ destructive: false,
26814
+ agentExposable: true,
26815
+ requiresApproval: false,
26816
+ scopes: ["read_contacts"]
26817
+ },
26818
+ listConversations: {
26819
+ description: "List SMS (EXTERNAL) and chat (INTERNAL, COLLABORATIVE) conversations with participants, unread count and last message. Offset-paginated: pass back `nextOffset` as `offset` for the next page. Scope depends on the API key: without the Monitoring flag Ringover only returns the key owner\u2019s own data; with it, the whole team\u2019s.",
26820
+ destructive: false,
26821
+ agentExposable: true,
26822
+ requiresApproval: false,
26823
+ scopes: ["read_messages"]
26824
+ },
26825
+ listCurrentCalls: {
26826
+ description: "List calls in progress right now (ringing or answered): numbers, user, IVR, device, recording / mute / hold state. Visibility follows the API key owner\u2019s role (admins and supervisors see the team), not the Monitoring flag.",
26827
+ destructive: false,
26828
+ agentExposable: true,
26829
+ requiresApproval: false,
26830
+ scopes: ["read_calls"]
26831
+ },
26832
+ listGroups: {
26833
+ description: "List call groups (how inbound calls are distributed between users) with their member count. Offset-paginated: pass back `nextOffset` as `offset` for the next page. Scope depends on the API key: without the Monitoring flag Ringover only returns the key owner\u2019s own data; with it, the whole team\u2019s.",
26834
+ destructive: false,
26835
+ agentExposable: true,
26836
+ requiresApproval: false,
26837
+ scopes: ["read_users"]
26838
+ },
26839
+ listMessages: {
26840
+ description: "List the messages of one conversation, most recent first. Cursor-paginated: pass back `nextCursor` as `cursor`.",
26841
+ destructive: false,
26842
+ agentExposable: true,
26843
+ requiresApproval: false,
26844
+ scopes: ["read_messages"]
26845
+ },
26846
+ listNumbers: {
26847
+ description: "List the team\u2019s phone numbers with their assignment (user, IVR, conference, fax or available) and capabilities; `smsSendEnabled` tells which ones can send SMS. All assignments by default; narrow with `include`. Scope depends on the API key: without the Monitoring flag Ringover only returns the key owner\u2019s own data; with it, the whole team\u2019s.",
26848
+ destructive: false,
26849
+ agentExposable: true,
26850
+ requiresApproval: false,
26851
+ scopes: ["read_users"]
26852
+ },
26853
+ listPresences: {
26854
+ description: "List every user\u2019s live presence: in a call, connected devices, inside working-hours planning, do-not-disturb. Requires the Monitoring flag on the API key.",
26855
+ destructive: false,
26856
+ agentExposable: true,
26857
+ requiresApproval: false,
26858
+ scopes: ["read_users"]
26859
+ },
26860
+ listTags: {
26861
+ description: "List the call tags defined for the team (name, color, description).",
26862
+ destructive: false,
26863
+ agentExposable: true,
26864
+ requiresApproval: false,
26865
+ scopes: ["read_calls"]
26866
+ },
26867
+ listUsers: {
26868
+ description: "List the team\u2019s users with their email, company, plan and phone numbers. Scope depends on the API key: without the Monitoring flag Ringover only returns the key owner\u2019s own data; with it, the whole team\u2019s.",
26869
+ destructive: false,
26870
+ agentExposable: true,
26871
+ requiresApproval: false,
26872
+ scopes: ["read_users"]
26873
+ },
26874
+ sendSms: {
26875
+ description: "Send an SMS to an external number. `from` must be a team number able to send SMS (see listNumbers `smsSendEnabled`); both numbers in E.164. `scheduledAt` (UTC) defers sending. Billed by Ringover and irreversible once sent.",
26876
+ destructive: true,
26877
+ agentExposable: true,
26878
+ requiresApproval: true,
26879
+ scopes: ["write_messages"]
26880
+ },
26881
+ updateContact: {
26882
+ description: "Update a contact: omitted fields keep their current value; `numbers`, when given, REPLACES all the contact\u2019s numbers. Returns the stored contact.",
26883
+ destructive: true,
26884
+ agentExposable: true,
26885
+ requiresApproval: false,
26886
+ scopes: ["write_contacts"]
26887
+ }
26888
+ }
26889
+ },
26621
26890
  shopify: {
26622
26891
  displayName: "Shopify",
26623
26892
  description: "Commerce platform \u2014 orders, products, inventory.",
@@ -26769,127 +27038,152 @@ var INTEGRATION_CATALOG = {
26769
27038
  {
26770
27039
  name: "write_companies",
26771
27040
  label: "\xC9crire les entreprises (B2B)",
26772
- description: "Cr\xE9er ou modifier une entreprise, ses contacts et ses lieux."
27041
+ description: "Cr\xE9er ou modifier une entreprise, ses contacts et ses lieux.",
27042
+ implies: ["read_companies"]
26773
27043
  },
26774
27044
  {
26775
27045
  name: "write_content",
26776
27046
  label: "\xC9crire les contenus",
26777
- description: "Cr\xE9er ou modifier les pages, les blogs, les articles, les menus et les redirections."
27047
+ description: "Cr\xE9er ou modifier les pages, les blogs, les articles, les menus et les redirections.",
27048
+ implies: ["read_content"]
26778
27049
  },
26779
27050
  {
26780
27051
  name: "write_customers",
26781
27052
  label: "\xC9crire les clients",
26782
- description: "Cr\xE9er ou modifier une fiche client, ses segments et ses consentements marketing."
27053
+ description: "Cr\xE9er ou modifier une fiche client, ses segments et ses consentements marketing.",
27054
+ implies: ["read_customers"]
26783
27055
  },
26784
27056
  {
26785
27057
  name: "write_discounts",
26786
27058
  label: "\xC9crire les remises",
26787
- description: "Cr\xE9er, modifier, activer ou d\xE9sactiver une remise."
27059
+ description: "Cr\xE9er, modifier, activer ou d\xE9sactiver une remise.",
27060
+ implies: ["read_discounts"]
26788
27061
  },
26789
27062
  {
26790
27063
  name: "write_draft_orders",
26791
27064
  label: "\xC9crire les commandes brouillon",
26792
- description: "Cr\xE9er, modifier, finaliser ou facturer une commande brouillon."
27065
+ description: "Cr\xE9er, modifier, finaliser ou facturer une commande brouillon.",
27066
+ implies: ["read_draft_orders"]
26793
27067
  },
26794
27068
  {
26795
27069
  name: "write_files",
26796
27070
  label: "\xC9crire les fichiers",
26797
- description: "T\xE9l\xE9verser ou modifier un fichier de la boutique."
27071
+ description: "T\xE9l\xE9verser ou modifier un fichier de la boutique.",
27072
+ implies: ["read_files"]
26798
27073
  },
26799
27074
  {
26800
27075
  name: "write_fulfillments",
26801
27076
  label: "\xC9crire les exp\xE9ditions",
26802
- description: "Cr\xE9er une exp\xE9dition, mettre \xE0 jour un suivi, d\xE9placer ou suspendre une commande d'ex\xE9cution."
27077
+ description: "Cr\xE9er une exp\xE9dition, mettre \xE0 jour un suivi, d\xE9placer ou suspendre une commande d'ex\xE9cution.",
27078
+ implies: ["read_fulfillments"]
26803
27079
  },
26804
27080
  {
26805
27081
  name: "write_gift_cards",
26806
27082
  label: "\xC9mettre des cartes cadeaux",
26807
- description: "Cr\xE9er, cr\xE9diter ou envoyer une carte cadeau \u2014 c'est de la monnaie au porteur."
27083
+ description: "Cr\xE9er, cr\xE9diter ou envoyer une carte cadeau \u2014 c'est de la monnaie au porteur.",
27084
+ implies: ["read_gift_cards"]
26808
27085
  },
26809
27086
  {
26810
27087
  name: "write_inventory",
26811
27088
  label: "\xC9crire les stocks",
26812
- description: "Ajuster les quantit\xE9s, d\xE9placer du stock, activer un article sur un emplacement."
27089
+ description: "Ajuster les quantit\xE9s, d\xE9placer du stock, activer un article sur un emplacement.",
27090
+ implies: ["read_inventory"]
26813
27091
  },
26814
27092
  {
26815
27093
  name: "write_locales",
26816
27094
  label: "\xC9crire les langues",
26817
- description: "Activer ou modifier une langue de la boutique."
27095
+ description: "Activer ou modifier une langue de la boutique.",
27096
+ implies: ["read_locales"]
26818
27097
  },
26819
27098
  {
26820
27099
  name: "write_locations",
26821
27100
  label: "\xC9crire les emplacements",
26822
- description: "Cr\xE9er, modifier, activer ou d\xE9sactiver un emplacement."
27101
+ description: "Cr\xE9er, modifier, activer ou d\xE9sactiver un emplacement.",
27102
+ implies: ["read_locations"]
26823
27103
  },
26824
27104
  {
26825
27105
  name: "write_marketing_events",
26826
27106
  label: "\xC9crire les activit\xE9s marketing",
26827
- description: "D\xE9clarer ou mettre \xE0 jour une activit\xE9 marketing et ses engagements."
27107
+ description: "D\xE9clarer ou mettre \xE0 jour une activit\xE9 marketing et ses engagements.",
27108
+ implies: ["read_marketing_events"]
26828
27109
  },
26829
27110
  {
26830
27111
  name: "write_markets",
26831
27112
  label: "\xC9crire les march\xE9s",
26832
- description: "Cr\xE9er ou modifier un march\xE9, ses r\xE9gions et ses devises."
27113
+ description: "Cr\xE9er ou modifier un march\xE9, ses r\xE9gions et ses devises.",
27114
+ implies: ["read_markets"]
26833
27115
  },
26834
27116
  {
26835
27117
  name: "write_metafields",
26836
27118
  label: "\xC9crire les m\xE9tachamps",
26837
- description: "Poser ou modifier un m\xE9tachamp (par exemple `custom.article_summary`)."
27119
+ description: "Poser ou modifier un m\xE9tachamp (par exemple `custom.article_summary`).",
27120
+ implies: ["read_metafields"]
26838
27121
  },
26839
27122
  {
26840
27123
  name: "write_metaobject_definitions",
26841
27124
  label: "\xC9crire les d\xE9finitions de m\xE9taobjet",
26842
- description: "Cr\xE9er ou modifier un type de m\xE9taobjet et ses champs."
27125
+ description: "Cr\xE9er ou modifier un type de m\xE9taobjet et ses champs.",
27126
+ implies: ["read_metaobject_definitions"]
26843
27127
  },
26844
27128
  {
26845
27129
  name: "write_metaobjects",
26846
27130
  label: "\xC9crire les m\xE9taobjets",
26847
- description: "Cr\xE9er ou modifier des m\xE9taobjets."
27131
+ description: "Cr\xE9er ou modifier des m\xE9taobjets.",
27132
+ implies: ["read_metaobjects"]
26848
27133
  },
26849
27134
  {
26850
27135
  name: "write_order_edits",
26851
27136
  label: "\xC9diter les commandes",
26852
- description: "Ajouter, retirer ou requantifier une ligne d'une commande d\xE9j\xE0 pass\xE9e."
27137
+ description: "Ajouter, retirer ou requantifier une ligne d'une commande d\xE9j\xE0 pass\xE9e.",
27138
+ implies: ["read_order_edits"]
26853
27139
  },
26854
27140
  {
26855
27141
  name: "write_orders",
26856
27142
  label: "\xC9crire les commandes",
26857
- description: "Cr\xE9er des commandes et modifier les commandes existantes (\xE9tiquettes, notes, encaissement, statut)."
27143
+ description: "Cr\xE9er des commandes et modifier les commandes existantes (\xE9tiquettes, notes, encaissement, statut).",
27144
+ implies: ["read_orders"]
26858
27145
  },
26859
27146
  {
26860
27147
  name: "write_price_rules",
26861
27148
  label: "\xC9crire les r\xE8gles de prix",
26862
- description: "Cr\xE9er ou modifier une r\xE8gle de prix et ses codes."
27149
+ description: "Cr\xE9er ou modifier une r\xE8gle de prix et ses codes.",
27150
+ implies: ["read_price_rules"]
26863
27151
  },
26864
27152
  {
26865
27153
  name: "write_products",
26866
27154
  label: "\xC9crire le catalogue",
26867
- description: "Cr\xE9er ou modifier des produits, des d\xE9clinaisons, des m\xE9dias et des collections."
27155
+ description: "Cr\xE9er ou modifier des produits, des d\xE9clinaisons, des m\xE9dias et des collections.",
27156
+ implies: ["read_products"]
26868
27157
  },
26869
27158
  {
26870
27159
  name: "write_publications",
26871
27160
  label: "Publier sur les canaux de vente",
26872
- description: "Publier ou d\xE9publier un produit ou une collection sur un canal."
27161
+ description: "Publier ou d\xE9publier un produit ou une collection sur un canal.",
27162
+ implies: ["read_publications"]
26873
27163
  },
26874
27164
  {
26875
27165
  name: "write_purchase_options",
26876
27166
  label: "\xC9crire les options d'achat",
26877
- description: "Cr\xE9er ou modifier un groupe d'abonnement et l'attacher \xE0 des produits."
27167
+ description: "Cr\xE9er ou modifier un groupe d'abonnement et l'attacher \xE0 des produits.",
27168
+ implies: ["read_purchase_options"]
26878
27169
  },
26879
27170
  {
26880
27171
  name: "write_returns",
26881
27172
  label: "\xC9crire les retours",
26882
- description: "Cr\xE9er un retour, approuver ou refuser une demande, d\xE9clencher un remboursement."
27173
+ description: "Cr\xE9er un retour, approuver ou refuser une demande, d\xE9clencher un remboursement.",
27174
+ implies: ["read_returns"]
26883
27175
  },
26884
27176
  {
26885
27177
  name: "write_shipping",
26886
27178
  label: "\xC9crire les profils de livraison",
26887
- description: "Cr\xE9er ou modifier un profil d'exp\xE9dition, ses zones et ses tarifs."
27179
+ description: "Cr\xE9er ou modifier un profil d'exp\xE9dition, ses zones et ses tarifs.",
27180
+ implies: ["read_shipping"]
26888
27181
  },
26889
27182
  {
26890
27183
  name: "write_store_credit_accounts",
26891
27184
  label: "\xC9crire les avoirs client",
26892
- description: "Cr\xE9diter ou d\xE9biter un compte d'avoir \u2014 c'est de la monnaie au porteur."
27185
+ description: "Cr\xE9diter ou d\xE9biter un compte d'avoir \u2014 c'est de la monnaie au porteur.",
27186
+ implies: ["read_store_credit_accounts"]
26893
27187
  },
26894
27188
  {
26895
27189
  name: "write_tags",
@@ -26899,7 +27193,8 @@ var INTEGRATION_CATALOG = {
26899
27193
  {
26900
27194
  name: "write_translations",
26901
27195
  label: "\xC9crire les traductions",
26902
- description: "Enregistrer ou modifier une traduction."
27196
+ description: "Enregistrer ou modifier une traduction.",
27197
+ implies: ["read_translations"]
26903
27198
  }
26904
27199
  ],
26905
27200
  actions: {
@@ -26957,7 +27252,7 @@ var INTEGRATION_CATALOG = {
26957
27252
  destructive: false,
26958
27253
  agentExposable: true,
26959
27254
  requiresApproval: false,
26960
- scopes: ["read_orders"]
27255
+ scopes: ["read_orders", "read_returns"]
26961
27256
  },
26962
27257
  listProducts: {
26963
27258
  description: "List catalog products with their variants (price, SKU, inventory) with cursor paging; omit updatedAtMin for a full sweep.",
@@ -27005,7 +27300,8 @@ var INTEGRATION_CATALOG = {
27005
27300
  {
27006
27301
  name: "write_channels",
27007
27302
  label: "Publier des messages",
27008
- description: "Envoyer des notifications et des alertes dans Slack, y compris dans un fil de discussion."
27303
+ description: "Envoyer des notifications et des alertes dans Slack, y compris dans un fil de discussion.",
27304
+ implies: ["read_channels"]
27009
27305
  }
27010
27306
  ],
27011
27307
  actions: {
@@ -27066,11 +27362,18 @@ function integrationActionScopes(provider, action) {
27066
27362
  const entry = INTEGRATION_CATALOG[provider]?.actions[action];
27067
27363
  return entry?.scopes ?? [];
27068
27364
  }
27069
- function expandDeclaredScopes(scopes) {
27365
+ function expandDeclaredScopes(scopes, provider) {
27366
+ const catalog = provider === void 0 ? void 0 : INTEGRATION_CATALOG[provider]?.scopeCatalog;
27070
27367
  const out = /* @__PURE__ */ new Set();
27071
27368
  for (const scope of scopes) {
27072
27369
  out.add(scope);
27073
- if (scope.startsWith("write_")) out.add(`read_${scope.slice("write_".length)}`);
27370
+ if (catalog) {
27371
+ for (const implied of catalog.find((entry) => entry.name === scope)?.implies ?? []) {
27372
+ out.add(implied);
27373
+ }
27374
+ } else if (scope.startsWith("write_")) {
27375
+ out.add(`read_${scope.slice("write_".length)}`);
27376
+ }
27074
27377
  }
27075
27378
  return [...out].sort();
27076
27379
  }
@@ -40400,6 +40703,46 @@ var INTEGRATION_ACTION_SCHEMAS = {
40400
40703
  }
40401
40704
  },
40402
40705
  meta: {
40706
+ getAd: {
40707
+ input: {
40708
+ $schema: "http://json-schema.org/draft-07/schema#",
40709
+ type: "object",
40710
+ properties: {
40711
+ id: { type: "string", pattern: "^\\d+$" },
40712
+ fields: {
40713
+ minItems: 1,
40714
+ type: "array",
40715
+ items: {
40716
+ type: "string",
40717
+ enum: [
40718
+ "id",
40719
+ "name",
40720
+ "adset_id",
40721
+ "campaign_id",
40722
+ "status",
40723
+ "effective_status",
40724
+ "configured_status",
40725
+ "creative",
40726
+ "tracking_specs",
40727
+ "created_time",
40728
+ "updated_time"
40729
+ ]
40730
+ }
40731
+ }
40732
+ },
40733
+ required: ["id"]
40734
+ },
40735
+ output: {
40736
+ $schema: "http://json-schema.org/draft-07/schema#",
40737
+ type: "object",
40738
+ properties: {
40739
+ id: { type: "string" },
40740
+ data: { type: "object", propertyNames: { type: "string" }, additionalProperties: {} }
40741
+ },
40742
+ required: ["id", "data"],
40743
+ additionalProperties: false
40744
+ }
40745
+ },
40403
40746
  getAdAccount: {
40404
40747
  input: { $schema: "http://json-schema.org/draft-07/schema#", type: "object", properties: {} },
40405
40748
  output: {
@@ -40416,6 +40759,103 @@ var INTEGRATION_ACTION_SCHEMAS = {
40416
40759
  additionalProperties: false
40417
40760
  }
40418
40761
  },
40762
+ getAdCreative: {
40763
+ input: {
40764
+ $schema: "http://json-schema.org/draft-07/schema#",
40765
+ type: "object",
40766
+ properties: {
40767
+ id: { type: "string", pattern: "^\\d+$" },
40768
+ fields: {
40769
+ minItems: 1,
40770
+ type: "array",
40771
+ items: {
40772
+ type: "string",
40773
+ enum: [
40774
+ "id",
40775
+ "name",
40776
+ "status",
40777
+ "object_type",
40778
+ "title",
40779
+ "body",
40780
+ "call_to_action_type",
40781
+ "link_url",
40782
+ "url_tags",
40783
+ "image_hash",
40784
+ "image_url",
40785
+ "thumbnail_url",
40786
+ "video_id",
40787
+ "object_story_spec",
40788
+ "asset_feed_spec",
40789
+ "effective_object_story_id",
40790
+ "effective_instagram_media_id",
40791
+ "instagram_permalink_url",
40792
+ "product_set_id"
40793
+ ]
40794
+ }
40795
+ }
40796
+ },
40797
+ required: ["id"]
40798
+ },
40799
+ output: {
40800
+ $schema: "http://json-schema.org/draft-07/schema#",
40801
+ type: "object",
40802
+ properties: {
40803
+ id: { type: "string" },
40804
+ data: { type: "object", propertyNames: { type: "string" }, additionalProperties: {} }
40805
+ },
40806
+ required: ["id", "data"],
40807
+ additionalProperties: false
40808
+ }
40809
+ },
40810
+ getAdSet: {
40811
+ input: {
40812
+ $schema: "http://json-schema.org/draft-07/schema#",
40813
+ type: "object",
40814
+ properties: {
40815
+ id: { type: "string", pattern: "^\\d+$" },
40816
+ fields: {
40817
+ minItems: 1,
40818
+ type: "array",
40819
+ items: {
40820
+ type: "string",
40821
+ enum: [
40822
+ "id",
40823
+ "name",
40824
+ "campaign_id",
40825
+ "status",
40826
+ "effective_status",
40827
+ "configured_status",
40828
+ "optimization_goal",
40829
+ "billing_event",
40830
+ "bid_strategy",
40831
+ "bid_amount",
40832
+ "daily_budget",
40833
+ "lifetime_budget",
40834
+ "budget_remaining",
40835
+ "targeting",
40836
+ "promoted_object",
40837
+ "destination_type",
40838
+ "start_time",
40839
+ "end_time",
40840
+ "created_time",
40841
+ "updated_time"
40842
+ ]
40843
+ }
40844
+ }
40845
+ },
40846
+ required: ["id"]
40847
+ },
40848
+ output: {
40849
+ $schema: "http://json-schema.org/draft-07/schema#",
40850
+ type: "object",
40851
+ properties: {
40852
+ id: { type: "string" },
40853
+ data: { type: "object", propertyNames: { type: "string" }, additionalProperties: {} }
40854
+ },
40855
+ required: ["id", "data"],
40856
+ additionalProperties: false
40857
+ }
40858
+ },
40419
40859
  getAdsInsights: {
40420
40860
  input: {
40421
40861
  $schema: "http://json-schema.org/draft-07/schema#",
@@ -40547,26 +40987,105 @@ var INTEGRATION_ACTION_SCHEMAS = {
40547
40987
  additionalProperties: false
40548
40988
  }
40549
40989
  },
40550
- getCampaignInsights: {
40990
+ getAdVideo: {
40551
40991
  input: {
40552
40992
  $schema: "http://json-schema.org/draft-07/schema#",
40553
40993
  type: "object",
40554
- properties: {
40555
- since: { type: "string" },
40556
- until: { type: "string" },
40557
- campaignIds: { maxItems: 100, type: "array", items: { type: "string", minLength: 1 } },
40558
- granularity: { default: "total", type: "string", enum: ["total", "daily"] },
40559
- limit: { default: 100, type: "integer", exclusiveMinimum: 0, maximum: 100 },
40560
- cursor: { type: "string", minLength: 1 }
40561
- },
40562
- required: ["since", "until"]
40994
+ properties: { adId: { type: "string", pattern: "^\\d+$" } },
40995
+ required: ["adId"]
40563
40996
  },
40564
40997
  output: {
40998
+ $schema: "http://json-schema.org/draft-07/schema#",
40999
+ oneOf: [
41000
+ {
41001
+ type: "object",
41002
+ properties: {
41003
+ hasVideo: { type: "boolean", const: true },
41004
+ videoId: { type: "string" },
41005
+ source: { type: "string" },
41006
+ picture: { anyOf: [{ type: "string" }, { type: "null" }] },
41007
+ length: { anyOf: [{ type: "number" }, { type: "null" }] }
41008
+ },
41009
+ required: ["hasVideo", "videoId", "source", "picture", "length"],
41010
+ additionalProperties: false
41011
+ },
41012
+ {
41013
+ type: "object",
41014
+ properties: {
41015
+ hasVideo: { type: "boolean", const: false },
41016
+ reason: { type: "string", enum: ["image", "carousel", "no_video"] }
41017
+ },
41018
+ required: ["hasVideo", "reason"],
41019
+ additionalProperties: false
41020
+ }
41021
+ ]
41022
+ }
41023
+ },
41024
+ getCampaign: {
41025
+ input: {
40565
41026
  $schema: "http://json-schema.org/draft-07/schema#",
40566
41027
  type: "object",
40567
41028
  properties: {
40568
- since: { type: "string" },
40569
- until: { type: "string" },
41029
+ id: { type: "string", pattern: "^\\d+$" },
41030
+ fields: {
41031
+ minItems: 1,
41032
+ type: "array",
41033
+ items: {
41034
+ type: "string",
41035
+ enum: [
41036
+ "id",
41037
+ "name",
41038
+ "objective",
41039
+ "status",
41040
+ "effective_status",
41041
+ "configured_status",
41042
+ "buying_type",
41043
+ "bid_strategy",
41044
+ "daily_budget",
41045
+ "lifetime_budget",
41046
+ "budget_remaining",
41047
+ "special_ad_categories",
41048
+ "start_time",
41049
+ "stop_time",
41050
+ "created_time",
41051
+ "updated_time"
41052
+ ]
41053
+ }
41054
+ }
41055
+ },
41056
+ required: ["id"]
41057
+ },
41058
+ output: {
41059
+ $schema: "http://json-schema.org/draft-07/schema#",
41060
+ type: "object",
41061
+ properties: {
41062
+ id: { type: "string" },
41063
+ data: { type: "object", propertyNames: { type: "string" }, additionalProperties: {} }
41064
+ },
41065
+ required: ["id", "data"],
41066
+ additionalProperties: false
41067
+ }
41068
+ },
41069
+ getCampaignInsights: {
41070
+ input: {
41071
+ $schema: "http://json-schema.org/draft-07/schema#",
41072
+ type: "object",
41073
+ properties: {
41074
+ since: { type: "string" },
41075
+ until: { type: "string" },
41076
+ campaignIds: { maxItems: 100, type: "array", items: { type: "string", minLength: 1 } },
41077
+ granularity: { default: "total", type: "string", enum: ["total", "daily"] },
41078
+ limit: { default: 100, type: "integer", exclusiveMinimum: 0, maximum: 100 },
41079
+ cursor: { type: "string", minLength: 1 }
41080
+ },
41081
+ required: ["since", "until"]
41082
+ },
41083
+ output: {
41084
+ $schema: "http://json-schema.org/draft-07/schema#",
41085
+ type: "object",
41086
+ properties: {
41087
+ since: { type: "string" },
41088
+ until: { type: "string" },
40570
41089
  granularity: { type: "string", enum: ["total", "daily"] },
40571
41090
  currency: { anyOf: [{ type: "string" }, { type: "null" }] },
40572
41091
  rows: {
@@ -40614,6 +41133,46 @@ var INTEGRATION_ACTION_SCHEMAS = {
40614
41133
  additionalProperties: false
40615
41134
  }
40616
41135
  },
41136
+ getCustomAudience: {
41137
+ input: {
41138
+ $schema: "http://json-schema.org/draft-07/schema#",
41139
+ type: "object",
41140
+ properties: {
41141
+ id: { type: "string", pattern: "^\\d+$" },
41142
+ fields: {
41143
+ minItems: 1,
41144
+ type: "array",
41145
+ items: {
41146
+ type: "string",
41147
+ enum: [
41148
+ "id",
41149
+ "name",
41150
+ "description",
41151
+ "subtype",
41152
+ "approximate_count_lower_bound",
41153
+ "approximate_count_upper_bound",
41154
+ "retention_days",
41155
+ "delivery_status",
41156
+ "operation_status",
41157
+ "time_created",
41158
+ "time_updated"
41159
+ ]
41160
+ }
41161
+ }
41162
+ },
41163
+ required: ["id"]
41164
+ },
41165
+ output: {
41166
+ $schema: "http://json-schema.org/draft-07/schema#",
41167
+ type: "object",
41168
+ properties: {
41169
+ id: { type: "string" },
41170
+ data: { type: "object", propertyNames: { type: "string" }, additionalProperties: {} }
41171
+ },
41172
+ required: ["id", "data"],
41173
+ additionalProperties: false
41174
+ }
41175
+ },
40617
41176
  getFacebookPageAudience: {
40618
41177
  input: { $schema: "http://json-schema.org/draft-07/schema#", type: "object", properties: {} },
40619
41178
  output: {
@@ -41065,6 +41624,123 @@ var INTEGRATION_ACTION_SCHEMAS = {
41065
41624
  additionalProperties: false
41066
41625
  }
41067
41626
  },
41627
+ getInstagramMedia: {
41628
+ input: {
41629
+ $schema: "http://json-schema.org/draft-07/schema#",
41630
+ type: "object",
41631
+ properties: {
41632
+ id: { type: "string", pattern: "^\\d+$" },
41633
+ fields: {
41634
+ minItems: 1,
41635
+ type: "array",
41636
+ items: {
41637
+ type: "string",
41638
+ enum: [
41639
+ "id",
41640
+ "caption",
41641
+ "media_type",
41642
+ "media_product_type",
41643
+ "media_url",
41644
+ "thumbnail_url",
41645
+ "permalink",
41646
+ "timestamp",
41647
+ "username",
41648
+ "like_count",
41649
+ "comments_count"
41650
+ ]
41651
+ }
41652
+ }
41653
+ },
41654
+ required: ["id"]
41655
+ },
41656
+ output: {
41657
+ $schema: "http://json-schema.org/draft-07/schema#",
41658
+ type: "object",
41659
+ properties: {
41660
+ id: { type: "string" },
41661
+ data: { type: "object", propertyNames: { type: "string" }, additionalProperties: {} }
41662
+ },
41663
+ required: ["id", "data"],
41664
+ additionalProperties: false
41665
+ }
41666
+ },
41667
+ getPagePost: {
41668
+ input: {
41669
+ $schema: "http://json-schema.org/draft-07/schema#",
41670
+ type: "object",
41671
+ properties: {
41672
+ id: { type: "string", pattern: "^\\d+_\\d+$" },
41673
+ fields: {
41674
+ minItems: 1,
41675
+ type: "array",
41676
+ items: {
41677
+ type: "string",
41678
+ enum: [
41679
+ "id",
41680
+ "message",
41681
+ "story",
41682
+ "created_time",
41683
+ "updated_time",
41684
+ "permalink_url",
41685
+ "full_picture",
41686
+ "status_type",
41687
+ "is_published",
41688
+ "attachments"
41689
+ ]
41690
+ }
41691
+ }
41692
+ },
41693
+ required: ["id"]
41694
+ },
41695
+ output: {
41696
+ $schema: "http://json-schema.org/draft-07/schema#",
41697
+ type: "object",
41698
+ properties: {
41699
+ id: { type: "string" },
41700
+ data: { type: "object", propertyNames: { type: "string" }, additionalProperties: {} }
41701
+ },
41702
+ required: ["id", "data"],
41703
+ additionalProperties: false
41704
+ }
41705
+ },
41706
+ getVideo: {
41707
+ input: {
41708
+ $schema: "http://json-schema.org/draft-07/schema#",
41709
+ type: "object",
41710
+ properties: {
41711
+ id: { type: "string", pattern: "^\\d+$" },
41712
+ fields: {
41713
+ minItems: 1,
41714
+ type: "array",
41715
+ items: {
41716
+ type: "string",
41717
+ enum: [
41718
+ "id",
41719
+ "title",
41720
+ "description",
41721
+ "source",
41722
+ "picture",
41723
+ "length",
41724
+ "permalink_url",
41725
+ "created_time",
41726
+ "updated_time"
41727
+ ]
41728
+ }
41729
+ }
41730
+ },
41731
+ required: ["id"]
41732
+ },
41733
+ output: {
41734
+ $schema: "http://json-schema.org/draft-07/schema#",
41735
+ type: "object",
41736
+ properties: {
41737
+ id: { type: "string" },
41738
+ data: { type: "object", propertyNames: { type: "string" }, additionalProperties: {} }
41739
+ },
41740
+ required: ["id", "data"],
41741
+ additionalProperties: false
41742
+ }
41743
+ },
41068
41744
  listAds: {
41069
41745
  input: {
41070
41746
  $schema: "http://json-schema.org/draft-07/schema#",
@@ -48608,88 +49284,1720 @@ var INTEGRATION_ACTION_SCHEMAS = {
48608
49284
  }
48609
49285
  }
48610
49286
  },
48611
- shopify: {
48612
- addTagToOrder: {
49287
+ ringover: {
49288
+ createCallback: {
48613
49289
  input: {
48614
49290
  $schema: "http://json-schema.org/draft-07/schema#",
48615
49291
  type: "object",
48616
- properties: { orderId: { type: "string" }, tag: { type: "string" } },
48617
- required: ["orderId", "tag"]
49292
+ properties: {
49293
+ to: { type: "string", pattern: "^\\+[1-9]\\d{6,14}$" },
49294
+ from: { type: "string", pattern: "^\\+[1-9]\\d{6,14}$" },
49295
+ device: {
49296
+ default: "ALL",
49297
+ type: "string",
49298
+ enum: ["ALL", "APP", "WEB", "SIP", "MOB", "EXT"]
49299
+ },
49300
+ timeoutSeconds: { type: "integer", minimum: 1, maximum: 120 },
49301
+ hideCallerId: { type: "boolean" }
49302
+ },
49303
+ required: ["to"]
48618
49304
  },
48619
49305
  output: {
48620
49306
  $schema: "http://json-schema.org/draft-07/schema#",
48621
49307
  type: "object",
48622
- properties: { ok: { type: "boolean" } },
48623
- required: ["ok"],
49308
+ properties: {
49309
+ callId: { type: "string" },
49310
+ channelId: { anyOf: [{ type: "string" }, { type: "null" }] }
49311
+ },
49312
+ required: ["callId", "channelId"],
48624
49313
  additionalProperties: false
48625
49314
  }
48626
49315
  },
48627
- createGiftCard: {
49316
+ createContact: {
48628
49317
  input: {
48629
49318
  $schema: "http://json-schema.org/draft-07/schema#",
48630
49319
  type: "object",
48631
49320
  properties: {
48632
- initialValue: { type: "string", minLength: 1 },
48633
- customerId: { type: "string", minLength: 1 },
48634
- note: { type: "string" },
48635
- expiresOn: { type: "string" }
49321
+ firstName: { type: "string", maxLength: 255 },
49322
+ lastName: { type: "string", maxLength: 255 },
49323
+ company: { type: "string", maxLength: 255 },
49324
+ shared: { default: false, type: "boolean" },
49325
+ numbers: {
49326
+ minItems: 1,
49327
+ maxItems: 20,
49328
+ type: "array",
49329
+ items: {
49330
+ type: "object",
49331
+ properties: {
49332
+ number: { type: "string", pattern: "^\\+[1-9]\\d{6,14}$" },
49333
+ type: {
49334
+ default: "mobile",
49335
+ type: "string",
49336
+ enum: ["mobile", "office", "home", "fax", "other"]
49337
+ }
49338
+ },
49339
+ required: ["number"]
49340
+ }
49341
+ }
48636
49342
  },
48637
- required: ["initialValue", "customerId"]
49343
+ required: ["numbers"]
48638
49344
  },
48639
49345
  output: {
48640
49346
  $schema: "http://json-schema.org/draft-07/schema#",
48641
49347
  type: "object",
48642
49348
  properties: {
48643
- id: { type: "string" },
48644
- numericId: { type: "string" },
48645
- code: { type: "string" },
48646
- lastCharacters: { type: "string" },
48647
- amount: { type: "string" },
48648
- currency: { type: "string" },
48649
- customerId: { anyOf: [{ type: "string" }, { type: "null" }] },
48650
- expiresOn: { anyOf: [{ type: "string" }, { type: "null" }] }
49349
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
49350
+ firstName: { anyOf: [{ type: "string" }, { type: "null" }] },
49351
+ lastName: { anyOf: [{ type: "string" }, { type: "null" }] },
49352
+ company: { anyOf: [{ type: "string" }, { type: "null" }] },
49353
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
49354
+ shared: { anyOf: [{ type: "boolean" }, { type: "null" }] },
49355
+ owned: { anyOf: [{ type: "boolean" }, { type: "null" }] },
49356
+ emails: { type: "array", items: { type: "string" } },
49357
+ numbers: {
49358
+ type: "array",
49359
+ items: {
49360
+ type: "object",
49361
+ properties: {
49362
+ number: { type: "string" },
49363
+ e164: { anyOf: [{ type: "string" }, { type: "null" }] },
49364
+ national: { anyOf: [{ type: "string" }, { type: "null" }] },
49365
+ international: { anyOf: [{ type: "string" }, { type: "null" }] },
49366
+ countryCode: { anyOf: [{ type: "string" }, { type: "null" }] },
49367
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
49368
+ label: { anyOf: [{ type: "string" }, { type: "null" }] }
49369
+ },
49370
+ required: [
49371
+ "number",
49372
+ "e164",
49373
+ "national",
49374
+ "international",
49375
+ "countryCode",
49376
+ "type",
49377
+ "label"
49378
+ ],
49379
+ additionalProperties: false
49380
+ }
49381
+ },
49382
+ createdAt: { anyOf: [{ type: "string" }, { type: "null" }] },
49383
+ ref: {
49384
+ type: "object",
49385
+ properties: {
49386
+ provider: { type: "string" },
49387
+ type: { type: "string" },
49388
+ id: { type: "string" },
49389
+ label: { type: "string" },
49390
+ url: { type: "string" }
49391
+ },
49392
+ required: ["provider", "type", "id", "label"],
49393
+ additionalProperties: false
49394
+ }
48651
49395
  },
48652
49396
  required: [
48653
49397
  "id",
48654
- "numericId",
48655
- "code",
48656
- "lastCharacters",
48657
- "amount",
48658
- "currency",
48659
- "customerId",
48660
- "expiresOn"
49398
+ "firstName",
49399
+ "lastName",
49400
+ "company",
49401
+ "name",
49402
+ "shared",
49403
+ "owned",
49404
+ "emails",
49405
+ "numbers",
49406
+ "createdAt",
49407
+ "ref"
48661
49408
  ],
48662
49409
  additionalProperties: false
48663
49410
  }
48664
49411
  },
48665
- ensureCustomerByEmail: {
49412
+ getCall: {
48666
49413
  input: {
48667
49414
  $schema: "http://json-schema.org/draft-07/schema#",
48668
49415
  type: "object",
48669
- properties: {
48670
- email: { type: "string", minLength: 1 },
48671
- firstName: { type: "string" },
48672
- lastName: { type: "string" }
48673
- },
48674
- required: ["email"]
49416
+ properties: { callId: { type: "string", minLength: 1 } },
49417
+ required: ["callId"]
48675
49418
  },
48676
49419
  output: {
48677
49420
  $schema: "http://json-schema.org/draft-07/schema#",
48678
49421
  type: "object",
48679
49422
  properties: {
48680
- id: { type: "string" },
48681
- email: { anyOf: [{ type: "string" }, { type: "null" }] },
48682
- firstName: { anyOf: [{ type: "string" }, { type: "null" }] },
48683
- lastName: { anyOf: [{ type: "string" }, { type: "null" }] },
48684
- created: { type: "boolean" }
48685
- },
48686
- required: ["id", "email", "firstName", "lastName", "created"],
48687
- additionalProperties: false
48688
- }
48689
- },
48690
- getAdminUrl: {
48691
- input: {
48692
- $schema: "http://json-schema.org/draft-07/schema#",
49423
+ callId: { type: "string" },
49424
+ legs: {
49425
+ type: "array",
49426
+ items: {
49427
+ type: "object",
49428
+ properties: {
49429
+ callId: { type: "string" },
49430
+ cdrId: {
49431
+ anyOf: [
49432
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
49433
+ { type: "null" }
49434
+ ]
49435
+ },
49436
+ channelId: { anyOf: [{ type: "string" }, { type: "null" }] },
49437
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
49438
+ direction: { anyOf: [{ type: "string" }, { type: "null" }] },
49439
+ answered: { anyOf: [{ type: "boolean" }, { type: "null" }] },
49440
+ lastState: { anyOf: [{ type: "string" }, { type: "null" }] },
49441
+ startTime: { anyOf: [{ type: "string" }, { type: "null" }] },
49442
+ answeredTime: { anyOf: [{ type: "string" }, { type: "null" }] },
49443
+ endTime: { anyOf: [{ type: "string" }, { type: "null" }] },
49444
+ totalSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49445
+ talkSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49446
+ ringingSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49447
+ queueSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49448
+ holdSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49449
+ fromNumber: { anyOf: [{ type: "string" }, { type: "null" }] },
49450
+ toNumber: { anyOf: [{ type: "string" }, { type: "null" }] },
49451
+ contactNumber: { anyOf: [{ type: "string" }, { type: "null" }] },
49452
+ hangupBy: { anyOf: [{ type: "string" }, { type: "null" }] },
49453
+ note: { anyOf: [{ type: "string" }, { type: "null" }] },
49454
+ tags: {
49455
+ type: "array",
49456
+ items: {
49457
+ type: "object",
49458
+ properties: {
49459
+ id: {
49460
+ type: "integer",
49461
+ minimum: -9007199254740991,
49462
+ maximum: 9007199254740991
49463
+ },
49464
+ name: { type: "string" },
49465
+ color: { anyOf: [{ type: "string" }, { type: "null" }] },
49466
+ description: { anyOf: [{ type: "string" }, { type: "null" }] }
49467
+ },
49468
+ required: ["id", "name", "color", "description"],
49469
+ additionalProperties: false
49470
+ }
49471
+ },
49472
+ recordingUrl: { anyOf: [{ type: "string" }, { type: "null" }] },
49473
+ voicemailUrl: { anyOf: [{ type: "string" }, { type: "null" }] },
49474
+ user: {
49475
+ anyOf: [
49476
+ {
49477
+ type: "object",
49478
+ properties: {
49479
+ id: {
49480
+ type: "integer",
49481
+ minimum: -9007199254740991,
49482
+ maximum: 9007199254740991
49483
+ },
49484
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
49485
+ email: { anyOf: [{ type: "string" }, { type: "null" }] }
49486
+ },
49487
+ required: ["id", "name", "email"],
49488
+ additionalProperties: false
49489
+ },
49490
+ { type: "null" }
49491
+ ]
49492
+ },
49493
+ ivr: {
49494
+ anyOf: [
49495
+ {
49496
+ type: "object",
49497
+ properties: {
49498
+ id: {
49499
+ type: "integer",
49500
+ minimum: -9007199254740991,
49501
+ maximum: 9007199254740991
49502
+ },
49503
+ name: { anyOf: [{ type: "string" }, { type: "null" }] }
49504
+ },
49505
+ required: ["id", "name"],
49506
+ additionalProperties: false
49507
+ },
49508
+ { type: "null" }
49509
+ ]
49510
+ },
49511
+ contact: {
49512
+ anyOf: [
49513
+ {
49514
+ type: "object",
49515
+ properties: {
49516
+ id: {
49517
+ type: "integer",
49518
+ minimum: -9007199254740991,
49519
+ maximum: 9007199254740991
49520
+ },
49521
+ name: { anyOf: [{ type: "string" }, { type: "null" }] }
49522
+ },
49523
+ required: ["id", "name"],
49524
+ additionalProperties: false
49525
+ },
49526
+ { type: "null" }
49527
+ ]
49528
+ },
49529
+ summary: { anyOf: [{ type: "string" }, { type: "null" }] },
49530
+ transcription: {
49531
+ anyOf: [
49532
+ {
49533
+ type: "array",
49534
+ items: {
49535
+ type: "object",
49536
+ properties: {
49537
+ speakerId: {
49538
+ anyOf: [
49539
+ {
49540
+ type: "integer",
49541
+ minimum: -9007199254740991,
49542
+ maximum: 9007199254740991
49543
+ },
49544
+ { type: "null" }
49545
+ ]
49546
+ },
49547
+ channelId: {
49548
+ anyOf: [
49549
+ {
49550
+ type: "integer",
49551
+ minimum: -9007199254740991,
49552
+ maximum: 9007199254740991
49553
+ },
49554
+ { type: "null" }
49555
+ ]
49556
+ },
49557
+ start: { anyOf: [{ type: "number" }, { type: "null" }] },
49558
+ end: { anyOf: [{ type: "number" }, { type: "null" }] },
49559
+ text: { type: "string" }
49560
+ },
49561
+ required: ["speakerId", "channelId", "start", "end", "text"],
49562
+ additionalProperties: false
49563
+ }
49564
+ },
49565
+ { type: "null" }
49566
+ ]
49567
+ },
49568
+ ref: {
49569
+ type: "object",
49570
+ properties: {
49571
+ provider: { type: "string" },
49572
+ type: { type: "string" },
49573
+ id: { type: "string" },
49574
+ label: { type: "string" },
49575
+ url: { type: "string" }
49576
+ },
49577
+ required: ["provider", "type", "id", "label"],
49578
+ additionalProperties: false
49579
+ }
49580
+ },
49581
+ required: [
49582
+ "callId",
49583
+ "cdrId",
49584
+ "channelId",
49585
+ "type",
49586
+ "direction",
49587
+ "answered",
49588
+ "lastState",
49589
+ "startTime",
49590
+ "answeredTime",
49591
+ "endTime",
49592
+ "totalSeconds",
49593
+ "talkSeconds",
49594
+ "ringingSeconds",
49595
+ "queueSeconds",
49596
+ "holdSeconds",
49597
+ "fromNumber",
49598
+ "toNumber",
49599
+ "contactNumber",
49600
+ "hangupBy",
49601
+ "note",
49602
+ "tags",
49603
+ "recordingUrl",
49604
+ "voicemailUrl",
49605
+ "user",
49606
+ "ivr",
49607
+ "contact",
49608
+ "summary",
49609
+ "transcription",
49610
+ "ref"
49611
+ ],
49612
+ additionalProperties: false
49613
+ }
49614
+ }
49615
+ },
49616
+ required: ["callId", "legs"],
49617
+ additionalProperties: false
49618
+ }
49619
+ },
49620
+ getContact: {
49621
+ input: {
49622
+ $schema: "http://json-schema.org/draft-07/schema#",
49623
+ type: "object",
49624
+ properties: {
49625
+ contactId: { type: "integer", exclusiveMinimum: 0, maximum: 9007199254740991 }
49626
+ },
49627
+ required: ["contactId"]
49628
+ },
49629
+ output: {
49630
+ $schema: "http://json-schema.org/draft-07/schema#",
49631
+ type: "object",
49632
+ properties: {
49633
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
49634
+ firstName: { anyOf: [{ type: "string" }, { type: "null" }] },
49635
+ lastName: { anyOf: [{ type: "string" }, { type: "null" }] },
49636
+ company: { anyOf: [{ type: "string" }, { type: "null" }] },
49637
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
49638
+ shared: { anyOf: [{ type: "boolean" }, { type: "null" }] },
49639
+ owned: { anyOf: [{ type: "boolean" }, { type: "null" }] },
49640
+ emails: { type: "array", items: { type: "string" } },
49641
+ numbers: {
49642
+ type: "array",
49643
+ items: {
49644
+ type: "object",
49645
+ properties: {
49646
+ number: { type: "string" },
49647
+ e164: { anyOf: [{ type: "string" }, { type: "null" }] },
49648
+ national: { anyOf: [{ type: "string" }, { type: "null" }] },
49649
+ international: { anyOf: [{ type: "string" }, { type: "null" }] },
49650
+ countryCode: { anyOf: [{ type: "string" }, { type: "null" }] },
49651
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
49652
+ label: { anyOf: [{ type: "string" }, { type: "null" }] }
49653
+ },
49654
+ required: [
49655
+ "number",
49656
+ "e164",
49657
+ "national",
49658
+ "international",
49659
+ "countryCode",
49660
+ "type",
49661
+ "label"
49662
+ ],
49663
+ additionalProperties: false
49664
+ }
49665
+ },
49666
+ createdAt: { anyOf: [{ type: "string" }, { type: "null" }] },
49667
+ ref: {
49668
+ type: "object",
49669
+ properties: {
49670
+ provider: { type: "string" },
49671
+ type: { type: "string" },
49672
+ id: { type: "string" },
49673
+ label: { type: "string" },
49674
+ url: { type: "string" }
49675
+ },
49676
+ required: ["provider", "type", "id", "label"],
49677
+ additionalProperties: false
49678
+ }
49679
+ },
49680
+ required: [
49681
+ "id",
49682
+ "firstName",
49683
+ "lastName",
49684
+ "company",
49685
+ "name",
49686
+ "shared",
49687
+ "owned",
49688
+ "emails",
49689
+ "numbers",
49690
+ "createdAt",
49691
+ "ref"
49692
+ ],
49693
+ additionalProperties: false
49694
+ }
49695
+ },
49696
+ getUser: {
49697
+ input: {
49698
+ $schema: "http://json-schema.org/draft-07/schema#",
49699
+ type: "object",
49700
+ properties: { userId: { type: "integer", exclusiveMinimum: 0, maximum: 9007199254740991 } },
49701
+ required: ["userId"]
49702
+ },
49703
+ output: {
49704
+ $schema: "http://json-schema.org/draft-07/schema#",
49705
+ type: "object",
49706
+ properties: {
49707
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
49708
+ firstName: { anyOf: [{ type: "string" }, { type: "null" }] },
49709
+ lastName: { anyOf: [{ type: "string" }, { type: "null" }] },
49710
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
49711
+ email: { anyOf: [{ type: "string" }, { type: "null" }] },
49712
+ company: { anyOf: [{ type: "string" }, { type: "null" }] },
49713
+ numbers: {
49714
+ type: "array",
49715
+ items: {
49716
+ type: "object",
49717
+ properties: {
49718
+ number: { type: "string" },
49719
+ e164: { anyOf: [{ type: "string" }, { type: "null" }] },
49720
+ national: { anyOf: [{ type: "string" }, { type: "null" }] },
49721
+ international: { anyOf: [{ type: "string" }, { type: "null" }] },
49722
+ countryCode: { anyOf: [{ type: "string" }, { type: "null" }] },
49723
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
49724
+ label: { anyOf: [{ type: "string" }, { type: "null" }] }
49725
+ },
49726
+ required: [
49727
+ "number",
49728
+ "e164",
49729
+ "national",
49730
+ "international",
49731
+ "countryCode",
49732
+ "type",
49733
+ "label"
49734
+ ],
49735
+ additionalProperties: false
49736
+ }
49737
+ },
49738
+ plan: { anyOf: [{ type: "string" }, { type: "null" }] },
49739
+ ref: {
49740
+ type: "object",
49741
+ properties: {
49742
+ provider: { type: "string" },
49743
+ type: { type: "string" },
49744
+ id: { type: "string" },
49745
+ label: { type: "string" },
49746
+ url: { type: "string" }
49747
+ },
49748
+ required: ["provider", "type", "id", "label"],
49749
+ additionalProperties: false
49750
+ }
49751
+ },
49752
+ required: [
49753
+ "id",
49754
+ "firstName",
49755
+ "lastName",
49756
+ "name",
49757
+ "email",
49758
+ "company",
49759
+ "numbers",
49760
+ "plan",
49761
+ "ref"
49762
+ ],
49763
+ additionalProperties: false
49764
+ }
49765
+ },
49766
+ listCalls: {
49767
+ input: {
49768
+ $schema: "http://json-schema.org/draft-07/schema#",
49769
+ type: "object",
49770
+ properties: {
49771
+ startDate: {
49772
+ type: "string",
49773
+ pattern: "^\\d{4}-\\d{2}-\\d{2}(?:T\\d{2}:\\d{2}(?::\\d{2}(?:\\.\\d+)?)?(?:Z|[+-]\\d{2}:\\d{2})?)?$"
49774
+ },
49775
+ endDate: {
49776
+ type: "string",
49777
+ pattern: "^\\d{4}-\\d{2}-\\d{2}(?:T\\d{2}:\\d{2}(?::\\d{2}(?:\\.\\d+)?)?(?:Z|[+-]\\d{2}:\\d{2})?)?$"
49778
+ },
49779
+ callTypes: {
49780
+ minItems: 1,
49781
+ type: "array",
49782
+ items: { type: "string", enum: ["ANSWERED", "MISSED", "OUT", "VOICEMAIL"] }
49783
+ },
49784
+ include: { type: "array", items: { type: "string", enum: ["summary", "transcription"] } },
49785
+ limit: { default: 100, type: "integer", minimum: 1, maximum: 1e3 },
49786
+ offset: { default: 0, type: "integer", minimum: 0, maximum: 9e3 }
49787
+ }
49788
+ },
49789
+ output: {
49790
+ $schema: "http://json-schema.org/draft-07/schema#",
49791
+ type: "object",
49792
+ properties: {
49793
+ items: {
49794
+ type: "array",
49795
+ items: {
49796
+ type: "object",
49797
+ properties: {
49798
+ callId: { type: "string" },
49799
+ cdrId: {
49800
+ anyOf: [
49801
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
49802
+ { type: "null" }
49803
+ ]
49804
+ },
49805
+ channelId: { anyOf: [{ type: "string" }, { type: "null" }] },
49806
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
49807
+ direction: { anyOf: [{ type: "string" }, { type: "null" }] },
49808
+ answered: { anyOf: [{ type: "boolean" }, { type: "null" }] },
49809
+ lastState: { anyOf: [{ type: "string" }, { type: "null" }] },
49810
+ startTime: { anyOf: [{ type: "string" }, { type: "null" }] },
49811
+ answeredTime: { anyOf: [{ type: "string" }, { type: "null" }] },
49812
+ endTime: { anyOf: [{ type: "string" }, { type: "null" }] },
49813
+ totalSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49814
+ talkSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49815
+ ringingSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49816
+ queueSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49817
+ holdSeconds: { anyOf: [{ type: "number" }, { type: "null" }] },
49818
+ fromNumber: { anyOf: [{ type: "string" }, { type: "null" }] },
49819
+ toNumber: { anyOf: [{ type: "string" }, { type: "null" }] },
49820
+ contactNumber: { anyOf: [{ type: "string" }, { type: "null" }] },
49821
+ hangupBy: { anyOf: [{ type: "string" }, { type: "null" }] },
49822
+ note: { anyOf: [{ type: "string" }, { type: "null" }] },
49823
+ tags: {
49824
+ type: "array",
49825
+ items: {
49826
+ type: "object",
49827
+ properties: {
49828
+ id: {
49829
+ type: "integer",
49830
+ minimum: -9007199254740991,
49831
+ maximum: 9007199254740991
49832
+ },
49833
+ name: { type: "string" },
49834
+ color: { anyOf: [{ type: "string" }, { type: "null" }] },
49835
+ description: { anyOf: [{ type: "string" }, { type: "null" }] }
49836
+ },
49837
+ required: ["id", "name", "color", "description"],
49838
+ additionalProperties: false
49839
+ }
49840
+ },
49841
+ recordingUrl: { anyOf: [{ type: "string" }, { type: "null" }] },
49842
+ voicemailUrl: { anyOf: [{ type: "string" }, { type: "null" }] },
49843
+ user: {
49844
+ anyOf: [
49845
+ {
49846
+ type: "object",
49847
+ properties: {
49848
+ id: {
49849
+ type: "integer",
49850
+ minimum: -9007199254740991,
49851
+ maximum: 9007199254740991
49852
+ },
49853
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
49854
+ email: { anyOf: [{ type: "string" }, { type: "null" }] }
49855
+ },
49856
+ required: ["id", "name", "email"],
49857
+ additionalProperties: false
49858
+ },
49859
+ { type: "null" }
49860
+ ]
49861
+ },
49862
+ ivr: {
49863
+ anyOf: [
49864
+ {
49865
+ type: "object",
49866
+ properties: {
49867
+ id: {
49868
+ type: "integer",
49869
+ minimum: -9007199254740991,
49870
+ maximum: 9007199254740991
49871
+ },
49872
+ name: { anyOf: [{ type: "string" }, { type: "null" }] }
49873
+ },
49874
+ required: ["id", "name"],
49875
+ additionalProperties: false
49876
+ },
49877
+ { type: "null" }
49878
+ ]
49879
+ },
49880
+ contact: {
49881
+ anyOf: [
49882
+ {
49883
+ type: "object",
49884
+ properties: {
49885
+ id: {
49886
+ type: "integer",
49887
+ minimum: -9007199254740991,
49888
+ maximum: 9007199254740991
49889
+ },
49890
+ name: { anyOf: [{ type: "string" }, { type: "null" }] }
49891
+ },
49892
+ required: ["id", "name"],
49893
+ additionalProperties: false
49894
+ },
49895
+ { type: "null" }
49896
+ ]
49897
+ },
49898
+ summary: { anyOf: [{ type: "string" }, { type: "null" }] },
49899
+ transcription: {
49900
+ anyOf: [
49901
+ {
49902
+ type: "array",
49903
+ items: {
49904
+ type: "object",
49905
+ properties: {
49906
+ speakerId: {
49907
+ anyOf: [
49908
+ {
49909
+ type: "integer",
49910
+ minimum: -9007199254740991,
49911
+ maximum: 9007199254740991
49912
+ },
49913
+ { type: "null" }
49914
+ ]
49915
+ },
49916
+ channelId: {
49917
+ anyOf: [
49918
+ {
49919
+ type: "integer",
49920
+ minimum: -9007199254740991,
49921
+ maximum: 9007199254740991
49922
+ },
49923
+ { type: "null" }
49924
+ ]
49925
+ },
49926
+ start: { anyOf: [{ type: "number" }, { type: "null" }] },
49927
+ end: { anyOf: [{ type: "number" }, { type: "null" }] },
49928
+ text: { type: "string" }
49929
+ },
49930
+ required: ["speakerId", "channelId", "start", "end", "text"],
49931
+ additionalProperties: false
49932
+ }
49933
+ },
49934
+ { type: "null" }
49935
+ ]
49936
+ },
49937
+ ref: {
49938
+ type: "object",
49939
+ properties: {
49940
+ provider: { type: "string" },
49941
+ type: { type: "string" },
49942
+ id: { type: "string" },
49943
+ label: { type: "string" },
49944
+ url: { type: "string" }
49945
+ },
49946
+ required: ["provider", "type", "id", "label"],
49947
+ additionalProperties: false
49948
+ }
49949
+ },
49950
+ required: [
49951
+ "callId",
49952
+ "cdrId",
49953
+ "channelId",
49954
+ "type",
49955
+ "direction",
49956
+ "answered",
49957
+ "lastState",
49958
+ "startTime",
49959
+ "answeredTime",
49960
+ "endTime",
49961
+ "totalSeconds",
49962
+ "talkSeconds",
49963
+ "ringingSeconds",
49964
+ "queueSeconds",
49965
+ "holdSeconds",
49966
+ "fromNumber",
49967
+ "toNumber",
49968
+ "contactNumber",
49969
+ "hangupBy",
49970
+ "note",
49971
+ "tags",
49972
+ "recordingUrl",
49973
+ "voicemailUrl",
49974
+ "user",
49975
+ "ivr",
49976
+ "contact",
49977
+ "summary",
49978
+ "transcription",
49979
+ "ref"
49980
+ ],
49981
+ additionalProperties: false
49982
+ }
49983
+ },
49984
+ total: {
49985
+ anyOf: [
49986
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
49987
+ { type: "null" }
49988
+ ]
49989
+ },
49990
+ hasMore: { type: "boolean" },
49991
+ nextOffset: {
49992
+ anyOf: [
49993
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
49994
+ { type: "null" }
49995
+ ]
49996
+ }
49997
+ },
49998
+ required: ["items", "total", "hasMore", "nextOffset"],
49999
+ additionalProperties: false
50000
+ }
50001
+ },
50002
+ listContacts: {
50003
+ input: {
50004
+ $schema: "http://json-schema.org/draft-07/schema#",
50005
+ type: "object",
50006
+ properties: {
50007
+ search: { type: "string", minLength: 2 },
50008
+ limit: { default: 100, type: "integer", minimum: 1, maximum: 500 },
50009
+ offset: { default: 0, type: "integer", minimum: 0, maximum: 9007199254740991 }
50010
+ }
50011
+ },
50012
+ output: {
50013
+ $schema: "http://json-schema.org/draft-07/schema#",
50014
+ type: "object",
50015
+ properties: {
50016
+ items: {
50017
+ type: "array",
50018
+ items: {
50019
+ type: "object",
50020
+ properties: {
50021
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50022
+ firstName: { anyOf: [{ type: "string" }, { type: "null" }] },
50023
+ lastName: { anyOf: [{ type: "string" }, { type: "null" }] },
50024
+ company: { anyOf: [{ type: "string" }, { type: "null" }] },
50025
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
50026
+ shared: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50027
+ owned: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50028
+ emails: { type: "array", items: { type: "string" } },
50029
+ numbers: {
50030
+ type: "array",
50031
+ items: {
50032
+ type: "object",
50033
+ properties: {
50034
+ number: { type: "string" },
50035
+ e164: { anyOf: [{ type: "string" }, { type: "null" }] },
50036
+ national: { anyOf: [{ type: "string" }, { type: "null" }] },
50037
+ international: { anyOf: [{ type: "string" }, { type: "null" }] },
50038
+ countryCode: { anyOf: [{ type: "string" }, { type: "null" }] },
50039
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
50040
+ label: { anyOf: [{ type: "string" }, { type: "null" }] }
50041
+ },
50042
+ required: [
50043
+ "number",
50044
+ "e164",
50045
+ "national",
50046
+ "international",
50047
+ "countryCode",
50048
+ "type",
50049
+ "label"
50050
+ ],
50051
+ additionalProperties: false
50052
+ }
50053
+ },
50054
+ createdAt: { anyOf: [{ type: "string" }, { type: "null" }] },
50055
+ ref: {
50056
+ type: "object",
50057
+ properties: {
50058
+ provider: { type: "string" },
50059
+ type: { type: "string" },
50060
+ id: { type: "string" },
50061
+ label: { type: "string" },
50062
+ url: { type: "string" }
50063
+ },
50064
+ required: ["provider", "type", "id", "label"],
50065
+ additionalProperties: false
50066
+ }
50067
+ },
50068
+ required: [
50069
+ "id",
50070
+ "firstName",
50071
+ "lastName",
50072
+ "company",
50073
+ "name",
50074
+ "shared",
50075
+ "owned",
50076
+ "emails",
50077
+ "numbers",
50078
+ "createdAt",
50079
+ "ref"
50080
+ ],
50081
+ additionalProperties: false
50082
+ }
50083
+ },
50084
+ total: {
50085
+ anyOf: [
50086
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50087
+ { type: "null" }
50088
+ ]
50089
+ },
50090
+ hasMore: { type: "boolean" },
50091
+ nextOffset: {
50092
+ anyOf: [
50093
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50094
+ { type: "null" }
50095
+ ]
50096
+ }
50097
+ },
50098
+ required: ["items", "total", "hasMore", "nextOffset"],
50099
+ additionalProperties: false
50100
+ }
50101
+ },
50102
+ listConversations: {
50103
+ input: {
50104
+ $schema: "http://json-schema.org/draft-07/schema#",
50105
+ type: "object",
50106
+ properties: {
50107
+ type: {
50108
+ default: "ALL",
50109
+ type: "string",
50110
+ enum: ["ALL", "INTERNAL", "EXTERNAL", "COLLABORATIVE"]
50111
+ },
50112
+ limit: { default: 100, type: "integer", minimum: 1, maximum: 1e3 },
50113
+ offset: { default: 0, type: "integer", minimum: 0, maximum: 9007199254740991 }
50114
+ }
50115
+ },
50116
+ output: {
50117
+ $schema: "http://json-schema.org/draft-07/schema#",
50118
+ type: "object",
50119
+ properties: {
50120
+ items: {
50121
+ type: "array",
50122
+ items: {
50123
+ type: "object",
50124
+ properties: {
50125
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50126
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
50127
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
50128
+ purpose: { anyOf: [{ type: "string" }, { type: "null" }] },
50129
+ smsSendEnabled: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50130
+ unreadCount: {
50131
+ anyOf: [
50132
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50133
+ { type: "null" }
50134
+ ]
50135
+ },
50136
+ messageCount: {
50137
+ anyOf: [
50138
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50139
+ { type: "null" }
50140
+ ]
50141
+ },
50142
+ archived: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50143
+ tags: { type: "array", items: { type: "string" } },
50144
+ participants: {
50145
+ type: "array",
50146
+ items: {
50147
+ type: "object",
50148
+ properties: {
50149
+ kind: { type: "string", enum: ["user", "contact", "number", "ivr", "group"] },
50150
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
50151
+ number: { anyOf: [{ type: "string" }, { type: "null" }] },
50152
+ userId: {
50153
+ anyOf: [
50154
+ {
50155
+ type: "integer",
50156
+ minimum: -9007199254740991,
50157
+ maximum: 9007199254740991
50158
+ },
50159
+ { type: "null" }
50160
+ ]
50161
+ },
50162
+ contactId: {
50163
+ anyOf: [
50164
+ {
50165
+ type: "integer",
50166
+ minimum: -9007199254740991,
50167
+ maximum: 9007199254740991
50168
+ },
50169
+ { type: "null" }
50170
+ ]
50171
+ }
50172
+ },
50173
+ required: ["kind", "name", "number", "userId", "contactId"],
50174
+ additionalProperties: false
50175
+ }
50176
+ },
50177
+ lastMessage: {
50178
+ anyOf: [
50179
+ {
50180
+ type: "object",
50181
+ properties: {
50182
+ id: {
50183
+ type: "integer",
50184
+ minimum: -9007199254740991,
50185
+ maximum: 9007199254740991
50186
+ },
50187
+ conversationId: {
50188
+ anyOf: [
50189
+ {
50190
+ type: "integer",
50191
+ minimum: -9007199254740991,
50192
+ maximum: 9007199254740991
50193
+ },
50194
+ { type: "null" }
50195
+ ]
50196
+ },
50197
+ direction: { anyOf: [{ type: "string" }, { type: "null" }] },
50198
+ body: { anyOf: [{ type: "string" }, { type: "null" }] },
50199
+ failed: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50200
+ segments: {
50201
+ anyOf: [
50202
+ {
50203
+ type: "integer",
50204
+ minimum: -9007199254740991,
50205
+ maximum: 9007199254740991
50206
+ },
50207
+ { type: "null" }
50208
+ ]
50209
+ },
50210
+ archived: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50211
+ number: { anyOf: [{ type: "string" }, { type: "null" }] },
50212
+ user: {
50213
+ anyOf: [
50214
+ {
50215
+ type: "object",
50216
+ properties: {
50217
+ id: {
50218
+ type: "integer",
50219
+ minimum: -9007199254740991,
50220
+ maximum: 9007199254740991
50221
+ },
50222
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
50223
+ email: { anyOf: [{ type: "string" }, { type: "null" }] }
50224
+ },
50225
+ required: ["id", "name", "email"],
50226
+ additionalProperties: false
50227
+ },
50228
+ { type: "null" }
50229
+ ]
50230
+ },
50231
+ contact: {
50232
+ anyOf: [
50233
+ {
50234
+ type: "object",
50235
+ properties: {
50236
+ id: {
50237
+ type: "integer",
50238
+ minimum: -9007199254740991,
50239
+ maximum: 9007199254740991
50240
+ },
50241
+ name: { anyOf: [{ type: "string" }, { type: "null" }] }
50242
+ },
50243
+ required: ["id", "name"],
50244
+ additionalProperties: false
50245
+ },
50246
+ { type: "null" }
50247
+ ]
50248
+ },
50249
+ createdAt: { anyOf: [{ type: "string" }, { type: "null" }] }
50250
+ },
50251
+ required: [
50252
+ "id",
50253
+ "conversationId",
50254
+ "direction",
50255
+ "body",
50256
+ "failed",
50257
+ "segments",
50258
+ "archived",
50259
+ "number",
50260
+ "user",
50261
+ "contact",
50262
+ "createdAt"
50263
+ ],
50264
+ additionalProperties: false
50265
+ },
50266
+ { type: "null" }
50267
+ ]
50268
+ },
50269
+ createdAt: { anyOf: [{ type: "string" }, { type: "null" }] },
50270
+ updatedAt: { anyOf: [{ type: "string" }, { type: "null" }] },
50271
+ ref: {
50272
+ type: "object",
50273
+ properties: {
50274
+ provider: { type: "string" },
50275
+ type: { type: "string" },
50276
+ id: { type: "string" },
50277
+ label: { type: "string" },
50278
+ url: { type: "string" }
50279
+ },
50280
+ required: ["provider", "type", "id", "label"],
50281
+ additionalProperties: false
50282
+ }
50283
+ },
50284
+ required: [
50285
+ "id",
50286
+ "type",
50287
+ "name",
50288
+ "purpose",
50289
+ "smsSendEnabled",
50290
+ "unreadCount",
50291
+ "messageCount",
50292
+ "archived",
50293
+ "tags",
50294
+ "participants",
50295
+ "lastMessage",
50296
+ "createdAt",
50297
+ "updatedAt",
50298
+ "ref"
50299
+ ],
50300
+ additionalProperties: false
50301
+ }
50302
+ },
50303
+ total: {
50304
+ anyOf: [
50305
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50306
+ { type: "null" }
50307
+ ]
50308
+ },
50309
+ hasMore: { type: "boolean" },
50310
+ nextOffset: {
50311
+ anyOf: [
50312
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50313
+ { type: "null" }
50314
+ ]
50315
+ }
50316
+ },
50317
+ required: ["items", "total", "hasMore", "nextOffset"],
50318
+ additionalProperties: false
50319
+ }
50320
+ },
50321
+ listCurrentCalls: {
50322
+ input: {
50323
+ $schema: "http://json-schema.org/draft-07/schema#",
50324
+ type: "object",
50325
+ properties: {
50326
+ direction: { type: "string", enum: ["IN", "OUT"] },
50327
+ limit: { default: 100, type: "integer", minimum: 1, maximum: 1e3 },
50328
+ offset: { default: 0, type: "integer", minimum: 0, maximum: 9007199254740991 }
50329
+ }
50330
+ },
50331
+ output: {
50332
+ $schema: "http://json-schema.org/draft-07/schema#",
50333
+ type: "object",
50334
+ properties: {
50335
+ items: {
50336
+ type: "array",
50337
+ items: {
50338
+ type: "object",
50339
+ properties: {
50340
+ callId: { type: "string" },
50341
+ channelId: { anyOf: [{ type: "string" }, { type: "null" }] },
50342
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
50343
+ direction: { anyOf: [{ type: "string" }, { type: "null" }] },
50344
+ userId: {
50345
+ anyOf: [
50346
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50347
+ { type: "null" }
50348
+ ]
50349
+ },
50350
+ ivrId: {
50351
+ anyOf: [
50352
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50353
+ { type: "null" }
50354
+ ]
50355
+ },
50356
+ fromNumber: { anyOf: [{ type: "string" }, { type: "null" }] },
50357
+ toNumber: { anyOf: [{ type: "string" }, { type: "null" }] },
50358
+ device: { anyOf: [{ type: "string" }, { type: "null" }] },
50359
+ status: { anyOf: [{ type: "string" }, { type: "null" }] },
50360
+ recording: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50361
+ muted: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50362
+ onHold: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50363
+ startedAt: { anyOf: [{ type: "string" }, { type: "null" }] }
50364
+ },
50365
+ required: [
50366
+ "callId",
50367
+ "channelId",
50368
+ "type",
50369
+ "direction",
50370
+ "userId",
50371
+ "ivrId",
50372
+ "fromNumber",
50373
+ "toNumber",
50374
+ "device",
50375
+ "status",
50376
+ "recording",
50377
+ "muted",
50378
+ "onHold",
50379
+ "startedAt"
50380
+ ],
50381
+ additionalProperties: false
50382
+ }
50383
+ },
50384
+ total: {
50385
+ anyOf: [
50386
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50387
+ { type: "null" }
50388
+ ]
50389
+ },
50390
+ hasMore: { type: "boolean" },
50391
+ nextOffset: {
50392
+ anyOf: [
50393
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50394
+ { type: "null" }
50395
+ ]
50396
+ }
50397
+ },
50398
+ required: ["items", "total", "hasMore", "nextOffset"],
50399
+ additionalProperties: false
50400
+ }
50401
+ },
50402
+ listGroups: {
50403
+ input: {
50404
+ $schema: "http://json-schema.org/draft-07/schema#",
50405
+ type: "object",
50406
+ properties: {
50407
+ limit: { default: 100, type: "integer", minimum: 1, maximum: 1e3 },
50408
+ offset: { default: 0, type: "integer", minimum: 0, maximum: 9007199254740991 }
50409
+ }
50410
+ },
50411
+ output: {
50412
+ $schema: "http://json-schema.org/draft-07/schema#",
50413
+ type: "object",
50414
+ properties: {
50415
+ items: {
50416
+ type: "array",
50417
+ items: {
50418
+ type: "object",
50419
+ properties: {
50420
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50421
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
50422
+ userCount: {
50423
+ anyOf: [
50424
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50425
+ { type: "null" }
50426
+ ]
50427
+ },
50428
+ color: { anyOf: [{ type: "string" }, { type: "null" }] },
50429
+ freeAccess: { anyOf: [{ type: "boolean" }, { type: "null" }] }
50430
+ },
50431
+ required: ["id", "name", "userCount", "color", "freeAccess"],
50432
+ additionalProperties: false
50433
+ }
50434
+ },
50435
+ total: {
50436
+ anyOf: [
50437
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50438
+ { type: "null" }
50439
+ ]
50440
+ },
50441
+ hasMore: { type: "boolean" },
50442
+ nextOffset: {
50443
+ anyOf: [
50444
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50445
+ { type: "null" }
50446
+ ]
50447
+ }
50448
+ },
50449
+ required: ["items", "total", "hasMore", "nextOffset"],
50450
+ additionalProperties: false
50451
+ }
50452
+ },
50453
+ listMessages: {
50454
+ input: {
50455
+ $schema: "http://json-schema.org/draft-07/schema#",
50456
+ type: "object",
50457
+ properties: {
50458
+ conversationId: { type: "integer", exclusiveMinimum: 0, maximum: 9007199254740991 },
50459
+ limit: { default: 100, type: "integer", minimum: 1, maximum: 1e3 },
50460
+ cursor: { type: "integer", exclusiveMinimum: 0, maximum: 9007199254740991 },
50461
+ includeArchived: { type: "boolean" }
50462
+ },
50463
+ required: ["conversationId"]
50464
+ },
50465
+ output: {
50466
+ $schema: "http://json-schema.org/draft-07/schema#",
50467
+ type: "object",
50468
+ properties: {
50469
+ items: {
50470
+ type: "array",
50471
+ items: {
50472
+ type: "object",
50473
+ properties: {
50474
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50475
+ conversationId: {
50476
+ anyOf: [
50477
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50478
+ { type: "null" }
50479
+ ]
50480
+ },
50481
+ direction: { anyOf: [{ type: "string" }, { type: "null" }] },
50482
+ body: { anyOf: [{ type: "string" }, { type: "null" }] },
50483
+ failed: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50484
+ segments: {
50485
+ anyOf: [
50486
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50487
+ { type: "null" }
50488
+ ]
50489
+ },
50490
+ archived: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50491
+ number: { anyOf: [{ type: "string" }, { type: "null" }] },
50492
+ user: {
50493
+ anyOf: [
50494
+ {
50495
+ type: "object",
50496
+ properties: {
50497
+ id: {
50498
+ type: "integer",
50499
+ minimum: -9007199254740991,
50500
+ maximum: 9007199254740991
50501
+ },
50502
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
50503
+ email: { anyOf: [{ type: "string" }, { type: "null" }] }
50504
+ },
50505
+ required: ["id", "name", "email"],
50506
+ additionalProperties: false
50507
+ },
50508
+ { type: "null" }
50509
+ ]
50510
+ },
50511
+ contact: {
50512
+ anyOf: [
50513
+ {
50514
+ type: "object",
50515
+ properties: {
50516
+ id: {
50517
+ type: "integer",
50518
+ minimum: -9007199254740991,
50519
+ maximum: 9007199254740991
50520
+ },
50521
+ name: { anyOf: [{ type: "string" }, { type: "null" }] }
50522
+ },
50523
+ required: ["id", "name"],
50524
+ additionalProperties: false
50525
+ },
50526
+ { type: "null" }
50527
+ ]
50528
+ },
50529
+ createdAt: { anyOf: [{ type: "string" }, { type: "null" }] }
50530
+ },
50531
+ required: [
50532
+ "id",
50533
+ "conversationId",
50534
+ "direction",
50535
+ "body",
50536
+ "failed",
50537
+ "segments",
50538
+ "archived",
50539
+ "number",
50540
+ "user",
50541
+ "contact",
50542
+ "createdAt"
50543
+ ],
50544
+ additionalProperties: false
50545
+ }
50546
+ },
50547
+ total: {
50548
+ anyOf: [
50549
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50550
+ { type: "null" }
50551
+ ]
50552
+ },
50553
+ nextCursor: {
50554
+ anyOf: [
50555
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50556
+ { type: "null" }
50557
+ ]
50558
+ }
50559
+ },
50560
+ required: ["items", "total", "nextCursor"],
50561
+ additionalProperties: false
50562
+ }
50563
+ },
50564
+ listNumbers: {
50565
+ input: {
50566
+ $schema: "http://json-schema.org/draft-07/schema#",
50567
+ type: "object",
50568
+ properties: {
50569
+ include: {
50570
+ minItems: 1,
50571
+ type: "array",
50572
+ items: { type: "string", enum: ["user", "ivr", "conference", "fax", "available"] }
50573
+ }
50574
+ }
50575
+ },
50576
+ output: {
50577
+ $schema: "http://json-schema.org/draft-07/schema#",
50578
+ type: "object",
50579
+ properties: {
50580
+ items: {
50581
+ type: "array",
50582
+ items: {
50583
+ type: "object",
50584
+ properties: {
50585
+ number: { type: "string" },
50586
+ e164: { anyOf: [{ type: "string" }, { type: "null" }] },
50587
+ national: { anyOf: [{ type: "string" }, { type: "null" }] },
50588
+ international: { anyOf: [{ type: "string" }, { type: "null" }] },
50589
+ countryCode: { anyOf: [{ type: "string" }, { type: "null" }] },
50590
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
50591
+ label: { anyOf: [{ type: "string" }, { type: "null" }] },
50592
+ userId: {
50593
+ anyOf: [
50594
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50595
+ { type: "null" }
50596
+ ]
50597
+ },
50598
+ ivrId: {
50599
+ anyOf: [
50600
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50601
+ { type: "null" }
50602
+ ]
50603
+ },
50604
+ conferenceId: {
50605
+ anyOf: [
50606
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50607
+ { type: "null" }
50608
+ ]
50609
+ },
50610
+ smsEnabled: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50611
+ smsSendEnabled: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50612
+ callable: { anyOf: [{ type: "boolean" }, { type: "null" }] }
50613
+ },
50614
+ required: [
50615
+ "number",
50616
+ "e164",
50617
+ "national",
50618
+ "international",
50619
+ "countryCode",
50620
+ "type",
50621
+ "label",
50622
+ "userId",
50623
+ "ivrId",
50624
+ "conferenceId",
50625
+ "smsEnabled",
50626
+ "smsSendEnabled",
50627
+ "callable"
50628
+ ],
50629
+ additionalProperties: false
50630
+ }
50631
+ },
50632
+ total: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 }
50633
+ },
50634
+ required: ["items", "total"],
50635
+ additionalProperties: false
50636
+ }
50637
+ },
50638
+ listPresences: {
50639
+ input: { $schema: "http://json-schema.org/draft-07/schema#", type: "object", properties: {} },
50640
+ output: {
50641
+ $schema: "http://json-schema.org/draft-07/schema#",
50642
+ type: "object",
50643
+ properties: {
50644
+ items: {
50645
+ type: "array",
50646
+ items: {
50647
+ type: "object",
50648
+ properties: {
50649
+ userId: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50650
+ inCall: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50651
+ connectedDevices: {
50652
+ anyOf: [
50653
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50654
+ { type: "null" }
50655
+ ]
50656
+ },
50657
+ planningEnabled: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50658
+ inPlanning: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50659
+ snoozed: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50660
+ snoozeType: { anyOf: [{ type: "string" }, { type: "null" }] },
50661
+ snoozeEnd: { anyOf: [{ type: "string" }, { type: "null" }] }
50662
+ },
50663
+ required: [
50664
+ "userId",
50665
+ "inCall",
50666
+ "connectedDevices",
50667
+ "planningEnabled",
50668
+ "inPlanning",
50669
+ "snoozed",
50670
+ "snoozeType",
50671
+ "snoozeEnd"
50672
+ ],
50673
+ additionalProperties: false
50674
+ }
50675
+ },
50676
+ total: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 }
50677
+ },
50678
+ required: ["items", "total"],
50679
+ additionalProperties: false
50680
+ }
50681
+ },
50682
+ listTags: {
50683
+ input: { $schema: "http://json-schema.org/draft-07/schema#", type: "object", properties: {} },
50684
+ output: {
50685
+ $schema: "http://json-schema.org/draft-07/schema#",
50686
+ type: "object",
50687
+ properties: {
50688
+ items: {
50689
+ type: "array",
50690
+ items: {
50691
+ type: "object",
50692
+ properties: {
50693
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50694
+ name: { type: "string" },
50695
+ color: { anyOf: [{ type: "string" }, { type: "null" }] },
50696
+ description: { anyOf: [{ type: "string" }, { type: "null" }] }
50697
+ },
50698
+ required: ["id", "name", "color", "description"],
50699
+ additionalProperties: false
50700
+ }
50701
+ },
50702
+ total: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 }
50703
+ },
50704
+ required: ["items", "total"],
50705
+ additionalProperties: false
50706
+ }
50707
+ },
50708
+ listUsers: {
50709
+ input: { $schema: "http://json-schema.org/draft-07/schema#", type: "object", properties: {} },
50710
+ output: {
50711
+ $schema: "http://json-schema.org/draft-07/schema#",
50712
+ type: "object",
50713
+ properties: {
50714
+ items: {
50715
+ type: "array",
50716
+ items: {
50717
+ type: "object",
50718
+ properties: {
50719
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50720
+ firstName: { anyOf: [{ type: "string" }, { type: "null" }] },
50721
+ lastName: { anyOf: [{ type: "string" }, { type: "null" }] },
50722
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
50723
+ email: { anyOf: [{ type: "string" }, { type: "null" }] },
50724
+ company: { anyOf: [{ type: "string" }, { type: "null" }] },
50725
+ numbers: {
50726
+ type: "array",
50727
+ items: {
50728
+ type: "object",
50729
+ properties: {
50730
+ number: { type: "string" },
50731
+ e164: { anyOf: [{ type: "string" }, { type: "null" }] },
50732
+ national: { anyOf: [{ type: "string" }, { type: "null" }] },
50733
+ international: { anyOf: [{ type: "string" }, { type: "null" }] },
50734
+ countryCode: { anyOf: [{ type: "string" }, { type: "null" }] },
50735
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
50736
+ label: { anyOf: [{ type: "string" }, { type: "null" }] }
50737
+ },
50738
+ required: [
50739
+ "number",
50740
+ "e164",
50741
+ "national",
50742
+ "international",
50743
+ "countryCode",
50744
+ "type",
50745
+ "label"
50746
+ ],
50747
+ additionalProperties: false
50748
+ }
50749
+ },
50750
+ plan: { anyOf: [{ type: "string" }, { type: "null" }] },
50751
+ ref: {
50752
+ type: "object",
50753
+ properties: {
50754
+ provider: { type: "string" },
50755
+ type: { type: "string" },
50756
+ id: { type: "string" },
50757
+ label: { type: "string" },
50758
+ url: { type: "string" }
50759
+ },
50760
+ required: ["provider", "type", "id", "label"],
50761
+ additionalProperties: false
50762
+ }
50763
+ },
50764
+ required: [
50765
+ "id",
50766
+ "firstName",
50767
+ "lastName",
50768
+ "name",
50769
+ "email",
50770
+ "company",
50771
+ "numbers",
50772
+ "plan",
50773
+ "ref"
50774
+ ],
50775
+ additionalProperties: false
50776
+ }
50777
+ },
50778
+ total: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 }
50779
+ },
50780
+ required: ["items", "total"],
50781
+ additionalProperties: false
50782
+ }
50783
+ },
50784
+ sendSms: {
50785
+ input: {
50786
+ $schema: "http://json-schema.org/draft-07/schema#",
50787
+ type: "object",
50788
+ properties: {
50789
+ from: { type: "string", pattern: "^\\+[1-9]\\d{6,14}$" },
50790
+ to: { type: "string", pattern: "^\\+[1-9]\\d{6,14}$" },
50791
+ content: { type: "string", minLength: 1, maxLength: 1530 },
50792
+ asUserId: { type: "integer", exclusiveMinimum: 0, maximum: 9007199254740991 },
50793
+ scheduledAt: {
50794
+ type: "string",
50795
+ pattern: "^\\d{4}-\\d{2}-\\d{2}(?:T\\d{2}:\\d{2}(?::\\d{2}(?:\\.\\d+)?)?(?:Z|[+-]\\d{2}:\\d{2})?)?$"
50796
+ }
50797
+ },
50798
+ required: ["from", "to", "content"]
50799
+ },
50800
+ output: {
50801
+ $schema: "http://json-schema.org/draft-07/schema#",
50802
+ type: "object",
50803
+ properties: {
50804
+ messageId: {
50805
+ anyOf: [
50806
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50807
+ { type: "null" }
50808
+ ]
50809
+ },
50810
+ conversationId: {
50811
+ anyOf: [
50812
+ { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50813
+ { type: "null" }
50814
+ ]
50815
+ }
50816
+ },
50817
+ required: ["messageId", "conversationId"],
50818
+ additionalProperties: false
50819
+ }
50820
+ },
50821
+ updateContact: {
50822
+ input: {
50823
+ $schema: "http://json-schema.org/draft-07/schema#",
50824
+ type: "object",
50825
+ properties: {
50826
+ contactId: { type: "integer", exclusiveMinimum: 0, maximum: 9007199254740991 },
50827
+ firstName: { type: "string", maxLength: 255 },
50828
+ lastName: { type: "string", maxLength: 255 },
50829
+ company: { type: "string", maxLength: 255 },
50830
+ shared: { type: "boolean" },
50831
+ numbers: {
50832
+ minItems: 1,
50833
+ maxItems: 20,
50834
+ type: "array",
50835
+ items: {
50836
+ type: "object",
50837
+ properties: {
50838
+ number: { type: "string", pattern: "^\\+[1-9]\\d{6,14}$" },
50839
+ type: {
50840
+ default: "mobile",
50841
+ type: "string",
50842
+ enum: ["mobile", "office", "home", "fax", "other"]
50843
+ }
50844
+ },
50845
+ required: ["number"]
50846
+ }
50847
+ }
50848
+ },
50849
+ required: ["contactId"]
50850
+ },
50851
+ output: {
50852
+ $schema: "http://json-schema.org/draft-07/schema#",
50853
+ type: "object",
50854
+ properties: {
50855
+ id: { type: "integer", minimum: -9007199254740991, maximum: 9007199254740991 },
50856
+ firstName: { anyOf: [{ type: "string" }, { type: "null" }] },
50857
+ lastName: { anyOf: [{ type: "string" }, { type: "null" }] },
50858
+ company: { anyOf: [{ type: "string" }, { type: "null" }] },
50859
+ name: { anyOf: [{ type: "string" }, { type: "null" }] },
50860
+ shared: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50861
+ owned: { anyOf: [{ type: "boolean" }, { type: "null" }] },
50862
+ emails: { type: "array", items: { type: "string" } },
50863
+ numbers: {
50864
+ type: "array",
50865
+ items: {
50866
+ type: "object",
50867
+ properties: {
50868
+ number: { type: "string" },
50869
+ e164: { anyOf: [{ type: "string" }, { type: "null" }] },
50870
+ national: { anyOf: [{ type: "string" }, { type: "null" }] },
50871
+ international: { anyOf: [{ type: "string" }, { type: "null" }] },
50872
+ countryCode: { anyOf: [{ type: "string" }, { type: "null" }] },
50873
+ type: { anyOf: [{ type: "string" }, { type: "null" }] },
50874
+ label: { anyOf: [{ type: "string" }, { type: "null" }] }
50875
+ },
50876
+ required: [
50877
+ "number",
50878
+ "e164",
50879
+ "national",
50880
+ "international",
50881
+ "countryCode",
50882
+ "type",
50883
+ "label"
50884
+ ],
50885
+ additionalProperties: false
50886
+ }
50887
+ },
50888
+ createdAt: { anyOf: [{ type: "string" }, { type: "null" }] },
50889
+ ref: {
50890
+ type: "object",
50891
+ properties: {
50892
+ provider: { type: "string" },
50893
+ type: { type: "string" },
50894
+ id: { type: "string" },
50895
+ label: { type: "string" },
50896
+ url: { type: "string" }
50897
+ },
50898
+ required: ["provider", "type", "id", "label"],
50899
+ additionalProperties: false
50900
+ }
50901
+ },
50902
+ required: [
50903
+ "id",
50904
+ "firstName",
50905
+ "lastName",
50906
+ "company",
50907
+ "name",
50908
+ "shared",
50909
+ "owned",
50910
+ "emails",
50911
+ "numbers",
50912
+ "createdAt",
50913
+ "ref"
50914
+ ],
50915
+ additionalProperties: false
50916
+ }
50917
+ }
50918
+ },
50919
+ shopify: {
50920
+ addTagToOrder: {
50921
+ input: {
50922
+ $schema: "http://json-schema.org/draft-07/schema#",
50923
+ type: "object",
50924
+ properties: { orderId: { type: "string" }, tag: { type: "string" } },
50925
+ required: ["orderId", "tag"]
50926
+ },
50927
+ output: {
50928
+ $schema: "http://json-schema.org/draft-07/schema#",
50929
+ type: "object",
50930
+ properties: { ok: { type: "boolean" } },
50931
+ required: ["ok"],
50932
+ additionalProperties: false
50933
+ }
50934
+ },
50935
+ createGiftCard: {
50936
+ input: {
50937
+ $schema: "http://json-schema.org/draft-07/schema#",
50938
+ type: "object",
50939
+ properties: {
50940
+ initialValue: { type: "string", minLength: 1 },
50941
+ customerId: { type: "string", minLength: 1 },
50942
+ note: { type: "string" },
50943
+ expiresOn: { type: "string" }
50944
+ },
50945
+ required: ["initialValue", "customerId"]
50946
+ },
50947
+ output: {
50948
+ $schema: "http://json-schema.org/draft-07/schema#",
50949
+ type: "object",
50950
+ properties: {
50951
+ id: { type: "string" },
50952
+ numericId: { type: "string" },
50953
+ code: { type: "string" },
50954
+ lastCharacters: { type: "string" },
50955
+ amount: { type: "string" },
50956
+ currency: { type: "string" },
50957
+ customerId: { anyOf: [{ type: "string" }, { type: "null" }] },
50958
+ expiresOn: { anyOf: [{ type: "string" }, { type: "null" }] }
50959
+ },
50960
+ required: [
50961
+ "id",
50962
+ "numericId",
50963
+ "code",
50964
+ "lastCharacters",
50965
+ "amount",
50966
+ "currency",
50967
+ "customerId",
50968
+ "expiresOn"
50969
+ ],
50970
+ additionalProperties: false
50971
+ }
50972
+ },
50973
+ ensureCustomerByEmail: {
50974
+ input: {
50975
+ $schema: "http://json-schema.org/draft-07/schema#",
50976
+ type: "object",
50977
+ properties: {
50978
+ email: { type: "string", minLength: 1 },
50979
+ firstName: { type: "string" },
50980
+ lastName: { type: "string" }
50981
+ },
50982
+ required: ["email"]
50983
+ },
50984
+ output: {
50985
+ $schema: "http://json-schema.org/draft-07/schema#",
50986
+ type: "object",
50987
+ properties: {
50988
+ id: { type: "string" },
50989
+ email: { anyOf: [{ type: "string" }, { type: "null" }] },
50990
+ firstName: { anyOf: [{ type: "string" }, { type: "null" }] },
50991
+ lastName: { anyOf: [{ type: "string" }, { type: "null" }] },
50992
+ created: { type: "boolean" }
50993
+ },
50994
+ required: ["id", "email", "firstName", "lastName", "created"],
50995
+ additionalProperties: false
50996
+ }
50997
+ },
50998
+ getAdminUrl: {
50999
+ input: {
51000
+ $schema: "http://json-schema.org/draft-07/schema#",
48693
51001
  type: "object",
48694
51002
  properties: {
48695
51003
  type: {
@@ -50099,7 +52407,7 @@ function listSourceFiles(dir, out = []) {
50099
52407
  function findUndeclaredScopeCalls(manifest, projectRoot) {
50100
52408
  const declared = /* @__PURE__ */ new Map();
50101
52409
  for (const entry of manifest.integrations ?? []) {
50102
- declared.set(entry.provider, new Set(expandDeclaredScopes(entry.scopes)));
52410
+ declared.set(entry.provider, new Set(expandDeclaredScopes(entry.scopes, entry.provider)));
50103
52411
  }
50104
52412
  const findings = [];
50105
52413
  for (const file2 of listSourceFiles((0, import_path.join)(projectRoot, "src"))) {
@@ -50150,7 +52458,7 @@ function renderUndeclaredScopeDiagnostic(findings) {
50150
52458
  "Add them to `integrations` in src/app.manifest.ts:",
50151
52459
  suggestion,
50152
52460
  "",
50153
- "`write_x` implies `read_x` \u2014 declare only the write half."
52461
+ "`write_x` implies `read_x` when the catalogue lists it \u2014 declare only the write half."
50154
52462
  ].join("\n");
50155
52463
  }
50156
52464
 
@@ -50590,6 +52898,14 @@ async function lookupRun(opts) {
50590
52898
  const params = new URLSearchParams({ ref: opts.ref });
50591
52899
  return getJson(opts.baseUrl, "/runs/lookup", params, opts.apiKey);
50592
52900
  }
52901
+ async function cancelRun(opts) {
52902
+ return postJson(
52903
+ opts.baseUrl,
52904
+ `/runs/${encodeURIComponent(opts.runId)}/cancel`,
52905
+ {},
52906
+ opts.apiKey
52907
+ );
52908
+ }
50593
52909
  async function triggerJob(opts) {
50594
52910
  return postJson(
50595
52911
  opts.baseUrl,
@@ -52057,11 +54373,23 @@ function renderRunDetail(detail) {
52057
54373
  if (detail.error) {
52058
54374
  lines.push("", `Error: ${detail.error}`);
52059
54375
  }
54376
+ const retry = detail.pendingRetry;
54377
+ if (retry) {
54378
+ const at = retry.failedAt ? ` at ${formatLocalTimestamp(retry.failedAt)}` : "";
54379
+ lines.push(
54380
+ "",
54381
+ `Waiting to retry: step "${retry.step}" failed on attempt ${retry.attempt}${at}.`,
54382
+ ` ${retry.error ?? "(error message unavailable)"}`,
54383
+ ` Inngest retries it on its own; \`runs cancel ${detail.id}\` to stop the run instead.`
54384
+ );
54385
+ }
52060
54386
  if (detail.steps.length > 0) {
52061
54387
  lines.push("", "Steps:");
52062
54388
  for (const step of detail.steps) {
52063
54389
  const duration3 = step.durationMs !== null && step.durationMs !== void 0 ? formatDurationMs(step.durationMs) : "-";
52064
- lines.push(` - ${step.name} [${step.status}] ${duration3}`);
54390
+ const attempts = (step.attempts ?? 1) > 1 ? ` (${step.attempts} attempts)` : "";
54391
+ lines.push(` - ${step.name} [${step.status}] ${duration3}${attempts}`);
54392
+ if (step.error) lines.push(` last failed attempt: ${step.error}`);
52065
54393
  }
52066
54394
  }
52067
54395
  return lines.join("\n");
@@ -52115,11 +54443,24 @@ function buildShowCommand() {
52115
54443
  }
52116
54444
  });
52117
54445
  }
54446
+ function buildCancelCommand() {
54447
+ return new Command("cancel").description("Cancel a RUNNING or QUEUED run (EDITOR on the platform or on its app)").argument("<runId>", "Run ID").option("--json", "Output the raw response as JSON").option("--remote <name>", "Named remote server to target").action(async (runId, opts) => {
54448
+ const baseUrl = opts.remote ? getRemoteUrl(opts.remote) : DEFAULT_REMOTE_URL;
54449
+ const apiKey = resolveApiKey(opts.remote);
54450
+ try {
54451
+ const result = await cancelRun({ baseUrl, apiKey, runId });
54452
+ console.log(opts.json ? JSON.stringify(result) : `Run ${result.runId}: ${result.status}`);
54453
+ } catch (err) {
54454
+ reportApiError(err);
54455
+ }
54456
+ });
54457
+ }
52118
54458
  function buildRunsCommand() {
52119
- const runs = new Command("runs").description("Inspect and trigger job/function runs");
54459
+ const runs = new Command("runs").description("Inspect, trigger and cancel job/function runs");
52120
54460
  runs.addCommand(buildListCommand());
52121
54461
  runs.addCommand(buildShowCommand());
52122
54462
  runs.addCommand(buildRunsStartCommand());
54463
+ runs.addCommand(buildCancelCommand());
52123
54464
  return runs;
52124
54465
  }
52125
54466
 
@@ -52463,7 +54804,7 @@ function renderScopeCatalog(provider) {
52463
54804
  if (scopes.length === 0) return "";
52464
54805
  return [
52465
54806
  "",
52466
- `SCOPES (${scopes.length}) \u2014 \xE0 d\xE9clarer dans manifest.integrations ; write_x implique read_x`,
54807
+ `SCOPES (${scopes.length}) \u2014 \xE0 d\xE9clarer dans manifest.integrations ; write_x implique read_x s'il existe au catalogue`,
52467
54808
  "",
52468
54809
  renderTable(
52469
54810
  ["SCOPE", "LIBELL\xC9 (modale de consentement)"],