@pushwoosh/rpc-v2-http-api-data 0.2.517 → 0.2.518

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/data.js CHANGED
@@ -23591,6 +23591,60 @@ export const data = {
23591
23591
  "method": "delete",
23592
23592
  "path": "/api/integrations/google-ads/ad-accounts/{ad_account_id}/audiences/{audience_id}"
23593
23593
  },
23594
+ "GetSnapAuthURL": {
23595
+ "request": "pushwoosh.rpc_v2.integrations.GetSnapAuthURLRequest",
23596
+ "response": "pushwoosh.rpc_v2.integrations.GetSnapAuthURLResponse",
23597
+ "method": "get",
23598
+ "path": "/api/integrations/snap/auth"
23599
+ },
23600
+ "GetSnapConfiguration": {
23601
+ "request": "pushwoosh.rpc_v2.integrations.GetSnapConfigurationRequest",
23602
+ "response": "pushwoosh.rpc_v2.integrations.GetSnapConfigurationResponse",
23603
+ "method": "get",
23604
+ "path": "/api/integrations/configurations/snap"
23605
+ },
23606
+ "DeleteSnapConfiguration": {
23607
+ "request": "pushwoosh.rpc_v2.integrations.DeleteSnapConfigurationRequest",
23608
+ "response": "pushwoosh.rpc_v2.integrations.DeleteSnapConfigurationResponse",
23609
+ "method": "delete",
23610
+ "path": "/api/integrations/configurations/snap"
23611
+ },
23612
+ "ListSnapAdAccounts": {
23613
+ "request": "pushwoosh.rpc_v2.integrations.ListSnapAdAccountsRequest",
23614
+ "response": "pushwoosh.rpc_v2.integrations.ListSnapAdAccountsResponse",
23615
+ "method": "get",
23616
+ "path": "/api/integrations/snap/ad-accounts"
23617
+ },
23618
+ "ConnectSnapAdAccounts": {
23619
+ "request": "pushwoosh.rpc_v2.integrations.ConnectSnapAdAccountsRequest",
23620
+ "response": "pushwoosh.rpc_v2.integrations.ConnectSnapAdAccountsResponse",
23621
+ "method": "post",
23622
+ "path": "/api/integrations/snap/ad-accounts/connect"
23623
+ },
23624
+ "DisconnectSnapAdAccounts": {
23625
+ "request": "pushwoosh.rpc_v2.integrations.DisconnectSnapAdAccountsRequest",
23626
+ "response": "pushwoosh.rpc_v2.integrations.DisconnectSnapAdAccountsResponse",
23627
+ "method": "post",
23628
+ "path": "/api/integrations/snap/ad-accounts/disconnect"
23629
+ },
23630
+ "ListSnapAudiences": {
23631
+ "request": "pushwoosh.rpc_v2.integrations.ListSnapAudiencesRequest",
23632
+ "response": "pushwoosh.rpc_v2.integrations.ListSnapAudiencesResponse",
23633
+ "method": "get",
23634
+ "path": "/api/integrations/snap/ad-accounts/{ad_account_id}/audiences"
23635
+ },
23636
+ "CreateSnapAudience": {
23637
+ "request": "pushwoosh.rpc_v2.integrations.CreateSnapAudienceRequest",
23638
+ "response": "pushwoosh.rpc_v2.integrations.CreateSnapAudienceResponse",
23639
+ "method": "post",
23640
+ "path": "/api/integrations/snap/ad-accounts/{ad_account_id}/audiences"
23641
+ },
23642
+ "DeleteSnapAudience": {
23643
+ "request": "pushwoosh.rpc_v2.integrations.DeleteSnapAudienceRequest",
23644
+ "response": "pushwoosh.rpc_v2.integrations.DeleteSnapAudienceResponse",
23645
+ "method": "delete",
23646
+ "path": "/api/integrations/snap/ad-accounts/{ad_account_id}/audiences/{audience_id}"
23647
+ },
23594
23648
  "SetMetaTagMapping": {
23595
23649
  "request": "pushwoosh.rpc_v2.integrations.SetMetaTagMappingRequest",
23596
23650
  "response": "pushwoosh.rpc_v2.integrations.SetMetaTagMappingResponse",
@@ -23683,7 +23737,8 @@ export const data = {
23683
23737
  "SALESFORCE",
23684
23738
  "DYNAMICS",
23685
23739
  "GOOGLE_ADS",
23686
- "FLIGHT_STATUS"
23740
+ "FLIGHT_STATUS",
23741
+ "SNAP"
23687
23742
  ]
23688
23743
  },
23689
23744
  "pushwoosh.rpc_v2.integrations.ImportSegmentPianoRequest": {
@@ -24833,6 +24888,188 @@ export const data = {
24833
24888
  }
24834
24889
  }
24835
24890
  },
24891
+ "pushwoosh.rpc_v2.integrations.SnapAdAccountStatus": {
24892
+ "type": "E",
24893
+ "values": [
24894
+ "SNAP_AD_ACCOUNT_STATUS_UNSPECIFIED",
24895
+ "SNAP_AD_ACCOUNT_STATUS_CONNECTED",
24896
+ "SNAP_AD_ACCOUNT_STATUS_DISCONNECTED"
24897
+ ]
24898
+ },
24899
+ "pushwoosh.rpc_v2.integrations.SnapAdAccount": {
24900
+ "type": "I",
24901
+ "fields": {
24902
+ "id": {
24903
+ "type": "string"
24904
+ },
24905
+ "name": {
24906
+ "type": "string"
24907
+ },
24908
+ "status": {
24909
+ "type": "pushwoosh.rpc_v2.integrations.SnapAdAccountStatus"
24910
+ }
24911
+ }
24912
+ },
24913
+ "pushwoosh.rpc_v2.integrations.GetSnapAuthURLRequest": {
24914
+ "type": "I",
24915
+ "fields": {
24916
+ "returnTo": {
24917
+ "type": "string"
24918
+ }
24919
+ }
24920
+ },
24921
+ "pushwoosh.rpc_v2.integrations.GetSnapAuthURLResponse": {
24922
+ "type": "I",
24923
+ "fields": {
24924
+ "authUrl": {
24925
+ "type": "string"
24926
+ }
24927
+ }
24928
+ },
24929
+ "pushwoosh.rpc_v2.integrations.GetSnapConfigurationRequest": {
24930
+ "type": "I",
24931
+ "fields": {}
24932
+ },
24933
+ "pushwoosh.rpc_v2.integrations.GetSnapConfigurationResponse": {
24934
+ "type": "I",
24935
+ "fields": {
24936
+ "connected": {
24937
+ "type": "boolean"
24938
+ },
24939
+ "identity": {
24940
+ "type": "string"
24941
+ },
24942
+ "adAccounts": {
24943
+ "type": "pushwoosh.rpc_v2.integrations.SnapAdAccount",
24944
+ "array": true
24945
+ }
24946
+ }
24947
+ },
24948
+ "pushwoosh.rpc_v2.integrations.DeleteSnapConfigurationRequest": {
24949
+ "type": "I",
24950
+ "fields": {}
24951
+ },
24952
+ "pushwoosh.rpc_v2.integrations.DeleteSnapConfigurationResponse": {
24953
+ "type": "I",
24954
+ "fields": {}
24955
+ },
24956
+ "pushwoosh.rpc_v2.integrations.ListSnapAdAccountsRequest": {
24957
+ "type": "I",
24958
+ "fields": {}
24959
+ },
24960
+ "pushwoosh.rpc_v2.integrations.ListSnapAdAccountsResponse": {
24961
+ "type": "I",
24962
+ "fields": {
24963
+ "adAccounts": {
24964
+ "type": "pushwoosh.rpc_v2.integrations.SnapAdAccount",
24965
+ "array": true
24966
+ }
24967
+ }
24968
+ },
24969
+ "pushwoosh.rpc_v2.integrations.ConnectSnapAdAccountsRequest": {
24970
+ "type": "I",
24971
+ "fields": {
24972
+ "adAccountIds": {
24973
+ "type": "string",
24974
+ "array": true
24975
+ }
24976
+ }
24977
+ },
24978
+ "pushwoosh.rpc_v2.integrations.ConnectSnapAdAccountsResponse": {
24979
+ "type": "I",
24980
+ "fields": {
24981
+ "adAccounts": {
24982
+ "type": "pushwoosh.rpc_v2.integrations.SnapAdAccount",
24983
+ "array": true
24984
+ }
24985
+ }
24986
+ },
24987
+ "pushwoosh.rpc_v2.integrations.DisconnectSnapAdAccountsRequest": {
24988
+ "type": "I",
24989
+ "fields": {
24990
+ "adAccountIds": {
24991
+ "type": "string",
24992
+ "array": true
24993
+ }
24994
+ }
24995
+ },
24996
+ "pushwoosh.rpc_v2.integrations.SnapAudience": {
24997
+ "type": "I",
24998
+ "fields": {
24999
+ "id": {
25000
+ "type": "string"
25001
+ },
25002
+ "name": {
25003
+ "type": "string"
25004
+ },
25005
+ "approximateCount": {
25006
+ "type": "number"
25007
+ }
25008
+ }
25009
+ },
25010
+ "pushwoosh.rpc_v2.integrations.ListSnapAudiencesRequest": {
25011
+ "type": "I",
25012
+ "fields": {
25013
+ "adAccountId": {
25014
+ "type": "string"
25015
+ }
25016
+ }
25017
+ },
25018
+ "pushwoosh.rpc_v2.integrations.ListSnapAudiencesResponse": {
25019
+ "type": "I",
25020
+ "fields": {
25021
+ "audiences": {
25022
+ "type": "pushwoosh.rpc_v2.integrations.SnapAudience",
25023
+ "array": true
25024
+ }
25025
+ }
25026
+ },
25027
+ "pushwoosh.rpc_v2.integrations.CreateSnapAudienceRequest": {
25028
+ "type": "I",
25029
+ "fields": {
25030
+ "adAccountId": {
25031
+ "type": "string"
25032
+ },
25033
+ "name": {
25034
+ "type": "string"
25035
+ },
25036
+ "description": {
25037
+ "type": "string"
25038
+ }
25039
+ }
25040
+ },
25041
+ "pushwoosh.rpc_v2.integrations.CreateSnapAudienceResponse": {
25042
+ "type": "I",
25043
+ "fields": {
25044
+ "audience": {
25045
+ "type": "pushwoosh.rpc_v2.integrations.SnapAudience"
25046
+ }
25047
+ }
25048
+ },
25049
+ "pushwoosh.rpc_v2.integrations.DeleteSnapAudienceRequest": {
25050
+ "type": "I",
25051
+ "fields": {
25052
+ "adAccountId": {
25053
+ "type": "string"
25054
+ },
25055
+ "audienceId": {
25056
+ "type": "string"
25057
+ }
25058
+ }
25059
+ },
25060
+ "pushwoosh.rpc_v2.integrations.DeleteSnapAudienceResponse": {
25061
+ "type": "I",
25062
+ "fields": {}
25063
+ },
25064
+ "pushwoosh.rpc_v2.integrations.DisconnectSnapAdAccountsResponse": {
25065
+ "type": "I",
25066
+ "fields": {
25067
+ "adAccounts": {
25068
+ "type": "pushwoosh.rpc_v2.integrations.SnapAdAccount",
25069
+ "array": true
25070
+ }
25071
+ }
25072
+ },
24836
25073
  "pushwoosh.rpc_v2.integrations.FlightStatusConfiguration": {
24837
25074
  "type": "I",
24838
25075
  "fields": {
package/integrations.d.ts CHANGED
@@ -38,6 +38,15 @@ export type IntegrationsService_DisconnectGoogleAdsAdAccounts = RpcMethod<Discon
38
38
  export type IntegrationsService_ListGoogleAdsAudiences = RpcMethod<ListGoogleAdsAudiencesRequest, ListGoogleAdsAudiencesResponse>;
39
39
  export type IntegrationsService_CreateGoogleAdsAudience = RpcMethod<CreateGoogleAdsAudienceRequest, CreateGoogleAdsAudienceResponse>;
40
40
  export type IntegrationsService_DeleteGoogleAdsAudience = RpcMethod<DeleteGoogleAdsAudienceRequest, DeleteGoogleAdsAudienceResponse>;
41
+ export type IntegrationsService_GetSnapAuthURL = RpcMethod<GetSnapAuthURLRequest, GetSnapAuthURLResponse>;
42
+ export type IntegrationsService_GetSnapConfiguration = RpcMethod<GetSnapConfigurationRequest, GetSnapConfigurationResponse>;
43
+ export type IntegrationsService_DeleteSnapConfiguration = RpcMethod<DeleteSnapConfigurationRequest, DeleteSnapConfigurationResponse>;
44
+ export type IntegrationsService_ListSnapAdAccounts = RpcMethod<ListSnapAdAccountsRequest, ListSnapAdAccountsResponse>;
45
+ export type IntegrationsService_ConnectSnapAdAccounts = RpcMethod<ConnectSnapAdAccountsRequest, ConnectSnapAdAccountsResponse>;
46
+ export type IntegrationsService_DisconnectSnapAdAccounts = RpcMethod<DisconnectSnapAdAccountsRequest, DisconnectSnapAdAccountsResponse>;
47
+ export type IntegrationsService_ListSnapAudiences = RpcMethod<ListSnapAudiencesRequest, ListSnapAudiencesResponse>;
48
+ export type IntegrationsService_CreateSnapAudience = RpcMethod<CreateSnapAudienceRequest, CreateSnapAudienceResponse>;
49
+ export type IntegrationsService_DeleteSnapAudience = RpcMethod<DeleteSnapAudienceRequest, DeleteSnapAudienceResponse>;
41
50
  export type IntegrationsService_SetMetaTagMapping = RpcMethod<SetMetaTagMappingRequest, SetMetaTagMappingResponse>;
42
51
  export type IntegrationsService_GetGoogleBQConfiguration = RpcMethod<GetGoogleBQConfigurationRequest, GetGoogleBQConfigurationResponse>;
43
52
  export type IntegrationsService_CreateGoogleBQConfiguration = RpcMethod<CreateGoogleBQConfigurationRequest, CreateGoogleBQConfigurationResponse>;
@@ -159,6 +168,27 @@ export interface IntegrationsService {
159
168
  CreateGoogleAdsAudience: IntegrationsService_CreateGoogleAdsAudience;
160
169
  /** Deletes a CRM-based user list at Google. Removal is permanent and every journey audience sync step pointing at the list stops working, so ask the user first. */
161
170
  DeleteGoogleAdsAudience: IntegrationsService_DeleteGoogleAdsAudience;
171
+ /**
172
+ * snap
173
+ * Builds the Snap OAuth authorization URL to start connecting a Snap account. The consent flow is owned by integration-oauth, which stores the grant and sends the browser back to return_to — there is no callback method here.
174
+ */
175
+ GetSnapAuthURL: IntegrationsService_GetSnapAuthURL;
176
+ /** Returns the Snap integration configuration for the current account: whether it is connected, the Snap identity (email) behind the grant and the connected ad accounts. Use to inspect the current Snap connection state. */
177
+ GetSnapConfiguration: IntegrationsService_GetSnapConfiguration;
178
+ /** Removes the entire Snap connection for the current account: the chosen ad accounts and the OAuth grant itself. Use to fully disconnect; not recoverable without reconnecting. */
179
+ DeleteSnapConfiguration: IntegrationsService_DeleteSnapConfiguration;
180
+ /** Lists the Snap ad accounts the connection can reach, each marked as connected or not. Use to discover ad accounts before connecting them with connect_snap_ad_accounts. */
181
+ ListSnapAdAccounts: IntegrationsService_ListSnapAdAccounts;
182
+ /** Connects the given Snap ad accounts by id. Ids the connection cannot reach are refused, so an account cannot be stored that would only fail later at send time. */
183
+ ConnectSnapAdAccounts: IntegrationsService_ConnectSnapAdAccounts;
184
+ /** Disconnects the given Snap ad accounts by id while keeping the OAuth grant. Use to remove specific ad accounts; to drop the whole connection use delete_snap_integration. */
185
+ DisconnectSnapAdAccounts: IntegrationsService_DisconnectSnapAdAccounts;
186
+ /** Lists the first-party (customer list) segments of a connected Snap ad account. Use to pick an audience for a journey audience sync point, or to see what create_snap_audience produced. */
187
+ ListSnapAudiences: IntegrationsService_ListSnapAudiences;
188
+ /** Creates a first-party (customer list) segment on a connected Snap ad account. Use before syncing users: an upload targets a segment that already exists. */
189
+ CreateSnapAudience: IntegrationsService_CreateSnapAudience;
190
+ /** Deletes a first-party (customer list) segment at Snap. Removal is permanent and every journey audience sync step pointing at the segment stops working, so ask the user first. */
191
+ DeleteSnapAudience: IntegrationsService_DeleteSnapAudience;
162
192
  /** Overwrites the mapping between Pushwoosh tags and Meta custom-audience fields for the current account. Use to define which PW tags sync to Meta audiences; replaces the entire mapping. */
163
193
  SetMetaTagMapping: IntegrationsService_SetMetaTagMapping;
164
194
  /**
@@ -193,7 +223,7 @@ export interface IntegrationsService {
193
223
  DeleteFlightStatusSubscription: IntegrationsService_DeleteFlightStatusSubscription;
194
224
  }
195
225
  /** Integration contains all available integration for clients (to update props) */
196
- export type Integration = 'UNKNOWN' | 'SEGMENT' | 'PIANO' | 'WEBHOOK' | 'HUBSPOT' | 'SHOPIFY' | 'STRIPE' | 'META' | 'INBOUND_WEBHOOK' | 'GOOGLE_BQ' | 'GOOGLE' | 'AZURE' | 'SALESFORCE' | 'DYNAMICS' | 'GOOGLE_ADS' | 'FLIGHT_STATUS';
226
+ export type Integration = 'UNKNOWN' | 'SEGMENT' | 'PIANO' | 'WEBHOOK' | 'HUBSPOT' | 'SHOPIFY' | 'STRIPE' | 'META' | 'INBOUND_WEBHOOK' | 'GOOGLE_BQ' | 'GOOGLE' | 'AZURE' | 'SALESFORCE' | 'DYNAMICS' | 'GOOGLE_ADS' | 'FLIGHT_STATUS' | 'SNAP';
197
227
  export type ImportSegmentPianoRequest = {
198
228
  /** application code */
199
229
  application?: string;
@@ -677,6 +707,72 @@ export type DeleteGoogleAdsAudienceResponse = {};
677
707
  export type DisconnectGoogleAdsAdAccountsResponse = {
678
708
  adAccounts: GoogleAdsAdAccount[];
679
709
  };
710
+ export type SnapAdAccountStatus = 'SNAP_AD_ACCOUNT_STATUS_UNSPECIFIED' | 'SNAP_AD_ACCOUNT_STATUS_CONNECTED' | 'SNAP_AD_ACCOUNT_STATUS_DISCONNECTED';
711
+ export type SnapAdAccount = {
712
+ /** Snap customer id, digits only */
713
+ id: string;
714
+ name: string;
715
+ status: SnapAdAccountStatus;
716
+ };
717
+ export type GetSnapAuthURLRequest = {
718
+ /** where the browser lands once the connection is stored */
719
+ returnTo?: string;
720
+ };
721
+ export type GetSnapAuthURLResponse = {
722
+ authUrl: string;
723
+ };
724
+ export type GetSnapConfigurationRequest = {};
725
+ export type GetSnapConfigurationResponse = {
726
+ connected: boolean;
727
+ /** snap account email the grant belongs to */
728
+ identity: string;
729
+ adAccounts: SnapAdAccount[];
730
+ };
731
+ export type DeleteSnapConfigurationRequest = {};
732
+ export type DeleteSnapConfigurationResponse = {};
733
+ export type ListSnapAdAccountsRequest = {};
734
+ export type ListSnapAdAccountsResponse = {
735
+ adAccounts: SnapAdAccount[];
736
+ };
737
+ export type ConnectSnapAdAccountsRequest = {
738
+ adAccountIds?: string[];
739
+ };
740
+ export type ConnectSnapAdAccountsResponse = {
741
+ adAccounts: SnapAdAccount[];
742
+ };
743
+ export type DisconnectSnapAdAccountsRequest = {
744
+ adAccountIds?: string[];
745
+ };
746
+ /** SnapAudience is a first-party (customer list) segment on an ad account. */
747
+ export type SnapAudience = {
748
+ id: string;
749
+ name: string;
750
+ /** Snap's estimate of matched users, 0 until matching runs */
751
+ approximateCount: number;
752
+ };
753
+ export type ListSnapAudiencesRequest = {
754
+ adAccountId?: string;
755
+ };
756
+ export type ListSnapAudiencesResponse = {
757
+ audiences: SnapAudience[];
758
+ };
759
+ export type CreateSnapAudienceRequest = {
760
+ adAccountId?: string;
761
+ name?: string;
762
+ /** optional, the integration fills its own default when empty */
763
+ description?: string;
764
+ };
765
+ export type CreateSnapAudienceResponse = {
766
+ audience: SnapAudience;
767
+ };
768
+ export type DeleteSnapAudienceRequest = {
769
+ adAccountId?: string;
770
+ audienceId?: string;
771
+ };
772
+ export type DeleteSnapAudienceResponse = {};
773
+ export type DisconnectSnapAdAccountsResponse = {
774
+ adAccounts: SnapAdAccount[];
775
+ };
680
776
  export type FlightStatusConfiguration = {
681
777
  provider: string;
682
778
  apiKey: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pushwoosh/rpc-v2-http-api-data",
3
- "version": "0.2.517",
3
+ "version": "0.2.518",
4
4
  "description": "RPC V2 HTTP API Types and Data",
5
5
  "main": "index.js",
6
6
  "module": "index.js",