@adspireai/adspire-node-sdk 1.0.295 → 1.0.297

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.
@@ -3,7 +3,5 @@
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  exports.client = void 0;
5
5
  const client_fetch_1 = require("@hey-api/client-fetch");
6
- exports.client = (0, client_fetch_1.createClient)((0, client_fetch_1.createConfig)({
7
- baseUrl: 'https://staging.adspire.ai'
8
- }));
6
+ exports.client = (0, client_fetch_1.createClient)((0, client_fetch_1.createConfig)());
9
7
  //# sourceMappingURL=client.gen.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"client.gen.js","sourceRoot":"","sources":["../src-public/client.gen.ts"],"names":[],"mappings":";AAAA,qDAAqD;;;AAGrD,wDAA4H;AAY/G,QAAA,MAAM,GAAG,IAAA,2BAAY,EAAC,IAAA,2BAAY,EAAgB;IAC3D,OAAO,EAAE,4BAA4B;CACxC,CAAC,CAAC,CAAC"}
1
+ {"version":3,"file":"client.gen.js","sourceRoot":"","sources":["../src-public/client.gen.ts"],"names":[],"mappings":";AAAA,qDAAqD;;;AAGrD,wDAA4H;AAY/G,QAAA,MAAM,GAAG,IAAA,2BAAY,EAAC,IAAA,2BAAY,GAAiB,CAAC,CAAC"}
@@ -620,7 +620,7 @@ export type ActivityItem = {
620
620
  };
621
621
  export type ActivityLog = {
622
622
  id: string;
623
- event: string;
623
+ event: ActivityEvent;
624
624
  description: string;
625
625
  /**
626
626
  * The actor who performed the activity; null for system activities
@@ -712,6 +712,14 @@ export type BrandChannel = {
712
712
  [key: string]: unknown;
713
713
  } | null;
714
714
  };
715
+ export type BrandsCompact = {
716
+ id: string;
717
+ name: string;
718
+ website?: string | null;
719
+ email?: string | null;
720
+ telephone?: string | null;
721
+ brand_channels?: Array<BrandChannel> | null;
722
+ };
715
723
  /**
716
724
  * Company information extracted from the website
717
725
  */
@@ -848,19 +856,54 @@ export type BrandSetting = {
848
856
  */
849
857
  logo?: string | null;
850
858
  };
851
- export type Campaigns = {
852
- id?: string;
853
- brand?: Brands;
859
+ export type CampaignListItems = {
860
+ id: string;
854
861
  title: string;
862
+ /**
863
+ * Sqid of the workspace the campaign belongs to
864
+ */
865
+ workspace_id: string;
866
+ brand_id?: string | null;
867
+ brand_name?: string | null;
868
+ /**
869
+ * Sqid of the campaign's first whiteboard
870
+ */
871
+ whiteboard_id?: string | null;
855
872
  start_date?: string;
856
873
  end_date?: string;
857
874
  status?: string | null;
858
- description?: string | null;
875
+ /**
876
+ * Aggregated whiteboard preview counts for the campaign
877
+ */
878
+ whiteboard_statuses: {
879
+ approved_count?: number;
880
+ pending_count?: number;
881
+ /**
882
+ * Count of rejected and discarded previews
883
+ */
884
+ rejected_count?: number;
885
+ };
859
886
  /**
860
887
  * Image URL from the first whiteboard post that has one
861
888
  */
862
889
  cover_photo?: string | null;
863
- whiteboard?: Whiteboards;
890
+ };
891
+ export type Campaigns = {
892
+ id: string;
893
+ title: string;
894
+ /**
895
+ * Sqid of the workspace the campaign belongs to
896
+ */
897
+ workspace_id: string;
898
+ brand?: BrandsCompact | null;
899
+ /**
900
+ * Sqid of the campaign's first whiteboard
901
+ */
902
+ whiteboard_id?: string | null;
903
+ start_date?: string;
904
+ end_date?: string;
905
+ status?: string | null;
906
+ description?: string | null;
864
907
  };
865
908
  export type Comments = {
866
909
  id?: string;
@@ -1055,6 +1098,14 @@ export type WebhookLogs = {
1055
1098
  created_at: string;
1056
1099
  updated_at: string;
1057
1100
  };
1101
+ export type WhiteboardPreviewListItems = {
1102
+ id: string;
1103
+ whiteboard_id: string;
1104
+ campaign_id?: string | null;
1105
+ status: WhiteboardPreviewStatus;
1106
+ version?: number;
1107
+ created_at?: string;
1108
+ };
1058
1109
  export type WhiteboardPreviews = {
1059
1110
  id?: string;
1060
1111
  whiteboard_id: string;
@@ -1759,7 +1810,7 @@ export type ListCampaignsData = {
1759
1810
  };
1760
1811
  export type ListCampaignsErrors = {
1761
1812
  /**
1762
- * User does not have an active workspace.
1813
+ * User does not have an active workspace, or the provided status value is invalid.
1763
1814
  */
1764
1815
  422: {
1765
1816
  error?: string;
@@ -1770,7 +1821,7 @@ export type ListCampaignsResponses = {
1770
1821
  /**
1771
1822
  * Successful operation
1772
1823
  */
1773
- 200: Array<Campaigns>;
1824
+ 200: Array<CampaignListItems>;
1774
1825
  };
1775
1826
  export type ListCampaignsResponse = ListCampaignsResponses[keyof ListCampaignsResponses];
1776
1827
  export type CreateCampaignData = {
@@ -2897,7 +2948,7 @@ export type ListWhiteboardPreviewsResponses = {
2897
2948
  /**
2898
2949
  * List of whiteboard previews
2899
2950
  */
2900
- 200: Array<WhiteboardPreviews>;
2951
+ 200: Array<WhiteboardPreviewListItems>;
2901
2952
  };
2902
2953
  export type ListWhiteboardPreviewsResponse = ListWhiteboardPreviewsResponses[keyof ListWhiteboardPreviewsResponses];
2903
2954
  export type CreateWhiteboardPreviewData = {
@@ -2989,5 +3040,5 @@ export type DeleteWhiteboardPreviewResponses = {
2989
3040
  };
2990
3041
  export type DeleteWhiteboardPreviewResponse = DeleteWhiteboardPreviewResponses[keyof DeleteWhiteboardPreviewResponses];
2991
3042
  export type ClientOptions = {
2992
- baseUrl: 'https://staging.adspire.ai' | (string & {});
3043
+ baseUrl: `${string}://${string}` | (string & {});
2993
3044
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adspireai/adspire-node-sdk",
3
- "version": "1.0.295",
3
+ "version": "1.0.297",
4
4
  "description": "Official Node.js SDK for AdspireAI API",
5
5
  "main": "dist-public/index.js",
6
6
  "types": "dist-public/index.d.ts",