@algolia/ingestion 1.0.0-beta.3 → 1.0.0-beta.5

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.
Files changed (98) hide show
  1. package/dist/builds/browser.d.ts +41 -33
  2. package/dist/builds/browser.d.ts.map +1 -1
  3. package/dist/builds/node.d.ts +41 -33
  4. package/dist/builds/node.d.ts.map +1 -1
  5. package/dist/ingestion.cjs +271 -32
  6. package/dist/ingestion.esm.browser.js +272 -34
  7. package/dist/ingestion.esm.node.js +271 -32
  8. package/dist/ingestion.umd.js +2 -2
  9. package/dist/model/authentication.d.ts +2 -2
  10. package/dist/model/authenticationCreateResponse.d.ts +1 -1
  11. package/dist/model/authenticationUpdateResponse.d.ts +1 -1
  12. package/dist/model/clientMethodProps.d.ts +57 -13
  13. package/dist/model/clientMethodProps.d.ts.map +1 -1
  14. package/dist/model/deleteResponse.d.ts +1 -1
  15. package/dist/model/destination.d.ts +2 -2
  16. package/dist/model/destinationCreateResponse.d.ts +1 -1
  17. package/dist/model/destinationUpdateResponse.d.ts +1 -1
  18. package/dist/model/event.d.ts +1 -1
  19. package/dist/model/index.d.ts +11 -2
  20. package/dist/model/index.d.ts.map +1 -1
  21. package/dist/model/listTransformationsResponse.d.ts +10 -0
  22. package/dist/model/listTransformationsResponse.d.ts.map +1 -0
  23. package/dist/model/onDemandDateUtilsInput.d.ts +2 -2
  24. package/dist/model/onDemandTrigger.d.ts +1 -1
  25. package/dist/model/run.d.ts +3 -3
  26. package/dist/model/runResponse.d.ts +1 -1
  27. package/dist/model/scheduleTrigger.d.ts +2 -2
  28. package/dist/model/sortKeys.d.ts +5 -0
  29. package/dist/model/sortKeys.d.ts.map +1 -0
  30. package/dist/model/source.d.ts +2 -2
  31. package/dist/model/sourceCreateResponse.d.ts +1 -1
  32. package/dist/model/sourceUpdateResponse.d.ts +1 -1
  33. package/dist/model/sourceWatchResponse.d.ts +20 -0
  34. package/dist/model/sourceWatchResponse.d.ts.map +1 -0
  35. package/dist/model/task.d.ts +6 -2
  36. package/dist/model/task.d.ts.map +1 -1
  37. package/dist/model/taskCreate.d.ts +4 -0
  38. package/dist/model/taskCreate.d.ts.map +1 -1
  39. package/dist/model/taskCreateResponse.d.ts +1 -1
  40. package/dist/model/taskUpdateResponse.d.ts +1 -1
  41. package/dist/model/transformation.d.ts +27 -0
  42. package/dist/model/transformation.d.ts.map +1 -0
  43. package/dist/model/transformationCreate.d.ts +18 -0
  44. package/dist/model/transformationCreate.d.ts.map +1 -0
  45. package/dist/model/transformationCreateResponse.d.ts +14 -0
  46. package/dist/model/transformationCreateResponse.d.ts.map +1 -0
  47. package/dist/model/transformationSearch.d.ts +4 -0
  48. package/dist/model/transformationSearch.d.ts.map +1 -0
  49. package/dist/model/transformationTry.d.ts +11 -0
  50. package/dist/model/transformationTry.d.ts.map +1 -0
  51. package/dist/model/transformationTryResponse.d.ts +9 -0
  52. package/dist/model/transformationTryResponse.d.ts.map +1 -0
  53. package/dist/model/transformationTryResponseError.d.ts +14 -0
  54. package/dist/model/transformationTryResponseError.d.ts.map +1 -0
  55. package/dist/model/transformationUpdateResponse.d.ts +14 -0
  56. package/dist/model/transformationUpdateResponse.d.ts.map +1 -0
  57. package/dist/model/window.d.ts +2 -2
  58. package/dist/src/ingestionClient.d.ts +117 -22
  59. package/dist/src/ingestionClient.d.ts.map +1 -1
  60. package/model/authentication.ts +2 -2
  61. package/model/authenticationCreateResponse.ts +1 -1
  62. package/model/authenticationUpdateResponse.ts +1 -1
  63. package/model/clientMethodProps.ts +62 -14
  64. package/model/deleteResponse.ts +1 -1
  65. package/model/destination.ts +2 -2
  66. package/model/destinationCreateResponse.ts +1 -1
  67. package/model/destinationUpdateResponse.ts +1 -1
  68. package/model/event.ts +1 -1
  69. package/model/index.ts +11 -2
  70. package/model/listTransformationsResponse.ts +13 -0
  71. package/model/onDemandDateUtilsInput.ts +2 -2
  72. package/model/onDemandTrigger.ts +1 -1
  73. package/model/run.ts +3 -3
  74. package/model/runResponse.ts +1 -1
  75. package/model/scheduleTrigger.ts +2 -2
  76. package/model/sortKeys.ts +6 -0
  77. package/model/source.ts +2 -2
  78. package/model/sourceCreateResponse.ts +1 -1
  79. package/model/sourceUpdateResponse.ts +1 -1
  80. package/model/sourceWatchResponse.ts +25 -0
  81. package/model/task.ts +7 -2
  82. package/model/taskCreate.ts +5 -0
  83. package/model/taskCreateResponse.ts +1 -1
  84. package/model/taskUpdateResponse.ts +1 -1
  85. package/model/transformation.ts +33 -0
  86. package/model/transformationCreate.ts +21 -0
  87. package/model/transformationCreateResponse.ts +16 -0
  88. package/model/{dockerSourceStreams.ts → transformationSearch.ts} +2 -2
  89. package/model/{dockerSourceDiscover.ts → transformationTry.ts} +5 -5
  90. package/model/transformationTryResponse.ts +12 -0
  91. package/model/transformationTryResponseError.ts +16 -0
  92. package/model/transformationUpdateResponse.ts +16 -0
  93. package/model/window.ts +2 -2
  94. package/package.json +10 -7
  95. package/dist/model/dockerSourceDiscover.d.ts +0 -11
  96. package/dist/model/dockerSourceDiscover.d.ts.map +0 -1
  97. package/dist/model/dockerSourceStreams.d.ts +0 -4
  98. package/dist/model/dockerSourceStreams.d.ts.map +0 -1
@@ -14,12 +14,12 @@ export type ScheduleTrigger = {
14
14
  cron: string;
15
15
 
16
16
  /**
17
- * The last time the scheduled task ran in RFC3339 format.
17
+ * The last time the scheduled task ran in RFC 3339 format.
18
18
  */
19
19
  lastRun?: string;
20
20
 
21
21
  /**
22
- * The next scheduled run of the task in RFC3339 format.
22
+ * The next scheduled run of the task in RFC 3339 format.
23
23
  */
24
24
  nextRun: string;
25
25
  };
@@ -0,0 +1,6 @@
1
+ // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
+
3
+ /**
4
+ * Property by which to sort the list.
5
+ */
6
+ export type SortKeys = 'createdAt' | 'name' | 'type' | 'updatedAt';
package/model/source.ts CHANGED
@@ -21,12 +21,12 @@ export type Source = {
21
21
  authenticationID?: string;
22
22
 
23
23
  /**
24
- * Date of creation in RFC3339 format.
24
+ * Date of creation in RFC 3339 format.
25
25
  */
26
26
  createdAt: string;
27
27
 
28
28
  /**
29
- * Date of last update in RFC3339 format.
29
+ * Date of last update in RFC 3339 format.
30
30
  */
31
31
  updatedAt?: string;
32
32
  };
@@ -12,7 +12,7 @@ export type SourceCreateResponse = {
12
12
  name: string;
13
13
 
14
14
  /**
15
- * Date of creation in RFC3339 format.
15
+ * Date of creation in RFC 3339 format.
16
16
  */
17
17
  createdAt: string;
18
18
  };
@@ -12,7 +12,7 @@ export type SourceUpdateResponse = {
12
12
  name: string;
13
13
 
14
14
  /**
15
- * Date of last update in RFC3339 format.
15
+ * Date of last update in RFC 3339 format.
16
16
  */
17
17
  updatedAt: string;
18
18
  };
@@ -0,0 +1,25 @@
1
+ // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
+
3
+ import type { Event } from './event';
4
+
5
+ export type SourceWatchResponse = {
6
+ /**
7
+ * Universally unique identifier (UUID) of a task run.
8
+ */
9
+ runID?: string;
10
+
11
+ /**
12
+ * Depending on the source type, the validation returns sampling data of your source (JSON, CSV, BigQuery).
13
+ */
14
+ data?: Array<Record<string, any>>;
15
+
16
+ /**
17
+ * In case of error, observability events will be added to the response, if any.
18
+ */
19
+ events?: Event[];
20
+
21
+ /**
22
+ * A message describing the outcome of a validate run.
23
+ */
24
+ message: string;
25
+ };
package/model/task.ts CHANGED
@@ -37,12 +37,17 @@ export type Task = {
37
37
  action: ActionType;
38
38
 
39
39
  /**
40
- * Date of creation in RFC3339 format.
40
+ * Date of the last cursor in RFC 3339 format.
41
+ */
42
+ cursor?: string;
43
+
44
+ /**
45
+ * Date of creation in RFC 3339 format.
41
46
  */
42
47
  createdAt: string;
43
48
 
44
49
  /**
45
- * Date of last update in RFC3339 format.
50
+ * Date of last update in RFC 3339 format.
46
51
  */
47
52
  updatedAt?: string;
48
53
  };
@@ -33,4 +33,9 @@ export type TaskCreate = {
33
33
  failureThreshold?: number;
34
34
 
35
35
  input?: TaskInput;
36
+
37
+ /**
38
+ * Date of the last cursor in RFC 3339 format.
39
+ */
40
+ cursor?: string;
36
41
  };
@@ -10,7 +10,7 @@ export type TaskCreateResponse = {
10
10
  taskID: string;
11
11
 
12
12
  /**
13
- * Date of creation in RFC3339 format.
13
+ * Date of creation in RFC 3339 format.
14
14
  */
15
15
  createdAt: string;
16
16
  };
@@ -10,7 +10,7 @@ export type TaskUpdateResponse = {
10
10
  taskID: string;
11
11
 
12
12
  /**
13
- * Date of last update in RFC3339 format.
13
+ * Date of last update in RFC 3339 format.
14
14
  */
15
15
  updatedAt: string;
16
16
  };
@@ -0,0 +1,33 @@
1
+ // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
+
3
+ export type Transformation = {
4
+ /**
5
+ * Universally unique identifier (UUID) of a transformation.
6
+ */
7
+ transformationID: string;
8
+
9
+ /**
10
+ * The source code of the transformation.
11
+ */
12
+ code: string;
13
+
14
+ /**
15
+ * The uniquely identified name of your transformation.
16
+ */
17
+ name: string;
18
+
19
+ /**
20
+ * A descriptive name for your transformation of what it does.
21
+ */
22
+ description: string;
23
+
24
+ /**
25
+ * Date of creation in RFC 3339 format.
26
+ */
27
+ createdAt: string;
28
+
29
+ /**
30
+ * Date of last update in RFC 3339 format.
31
+ */
32
+ updatedAt?: string;
33
+ };
@@ -0,0 +1,21 @@
1
+ // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
+
3
+ /**
4
+ * API request body for creating a transformation.
5
+ */
6
+ export type TransformationCreate = {
7
+ /**
8
+ * The source code of the transformation.
9
+ */
10
+ code: string;
11
+
12
+ /**
13
+ * The uniquely identified name of your transformation.
14
+ */
15
+ name: string;
16
+
17
+ /**
18
+ * A descriptive name for your transformation of what it does.
19
+ */
20
+ description: string;
21
+ };
@@ -0,0 +1,16 @@
1
+ // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
+
3
+ /**
4
+ * API response for creating a transformation.
5
+ */
6
+ export type TransformationCreateResponse = {
7
+ /**
8
+ * Universally unique identifier (UUID) of a transformation.
9
+ */
10
+ transformationID: string;
11
+
12
+ /**
13
+ * Date of creation in RFC 3339 format.
14
+ */
15
+ createdAt: string;
16
+ };
@@ -1,5 +1,5 @@
1
1
  // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
2
 
3
- export type DockerSourceStreams = {
4
- streams: Array<Record<string, any>>;
3
+ export type TransformationSearch = {
4
+ transformationsIDs: string[];
5
5
  };
@@ -1,13 +1,13 @@
1
1
  // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
2
 
3
- export type DockerSourceDiscover = {
3
+ export type TransformationTry = {
4
4
  /**
5
- * Universally unique identifier (UUID) of a task run.
5
+ * The source code of the transformation.
6
6
  */
7
- runID: string;
7
+ code: string;
8
8
 
9
9
  /**
10
- * Date of creation in RFC3339 format.
10
+ * The record to apply the given code to.
11
11
  */
12
- createdAt: string;
12
+ sampleRecord: Record<string, any>;
13
13
  };
@@ -0,0 +1,12 @@
1
+ // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
+
3
+ import type { TransformationTryResponseError } from './transformationTryResponseError';
4
+
5
+ export type TransformationTryResponse = {
6
+ /**
7
+ * The array of records returned by the transformation service.
8
+ */
9
+ payloads: Array<Record<string, any>>;
10
+
11
+ error?: TransformationTryResponseError;
12
+ };
@@ -0,0 +1,16 @@
1
+ // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
+
3
+ /**
4
+ * The error if the transformation failed.
5
+ */
6
+ export type TransformationTryResponseError = {
7
+ /**
8
+ * The error status code.
9
+ */
10
+ code?: number;
11
+
12
+ /**
13
+ * A descriptive message explaining the failure.
14
+ */
15
+ message?: string;
16
+ };
@@ -0,0 +1,16 @@
1
+ // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
+
3
+ /**
4
+ * API response for updating a transformation.
5
+ */
6
+ export type TransformationUpdateResponse = {
7
+ /**
8
+ * Universally unique identifier (UUID) of a transformation.
9
+ */
10
+ transformationID: string;
11
+
12
+ /**
13
+ * Date of last update in RFC 3339 format.
14
+ */
15
+ updatedAt: string;
16
+ };
package/model/window.ts CHANGED
@@ -5,12 +5,12 @@
5
5
  */
6
6
  export type Window = {
7
7
  /**
8
- * Date in RFC3339 format representing the oldest data in the time window.
8
+ * Date in RFC 3339 format representing the oldest data in the time window.
9
9
  */
10
10
  startDate: string;
11
11
 
12
12
  /**
13
- * Date in RFC3339 format representing the newest data in the time window.
13
+ * Date in RFC 3339 format representing the newest data in the time window.
14
14
  */
15
15
  endDate: string;
16
16
  };
package/package.json CHANGED
@@ -1,8 +1,11 @@
1
1
  {
2
2
  "name": "@algolia/ingestion",
3
- "version": "1.0.0-beta.3",
3
+ "version": "1.0.0-beta.5",
4
4
  "description": "JavaScript client for ingestion",
5
- "repository": "algolia/algoliasearch-client-javascript",
5
+ "repository": {
6
+ "type": "git",
7
+ "url": "git+https://github.com/algolia/algoliasearch-client-javascript.git"
8
+ },
6
9
  "license": "MIT",
7
10
  "author": "Algolia",
8
11
  "type": "module",
@@ -39,14 +42,14 @@
39
42
  "clean": "rm -rf ./dist || true"
40
43
  },
41
44
  "dependencies": {
42
- "@algolia/client-common": "5.0.0-beta.3",
43
- "@algolia/requester-browser-xhr": "5.0.0-beta.3",
44
- "@algolia/requester-node-http": "5.0.0-beta.3"
45
+ "@algolia/client-common": "5.0.0-beta.6",
46
+ "@algolia/requester-browser-xhr": "5.0.0-beta.6",
47
+ "@algolia/requester-node-http": "5.0.0-beta.6"
45
48
  },
46
49
  "devDependencies": {
47
- "@types/node": "20.14.2",
50
+ "@types/node": "20.14.8",
48
51
  "rollup": "4.18.0",
49
- "typescript": "5.4.5"
52
+ "typescript": "5.5.2"
50
53
  },
51
54
  "engines": {
52
55
  "node": ">= 14.0.0"
@@ -1,11 +0,0 @@
1
- export type DockerSourceDiscover = {
2
- /**
3
- * Universally unique identifier (UUID) of a task run.
4
- */
5
- runID: string;
6
- /**
7
- * Date of creation in RFC3339 format.
8
- */
9
- createdAt: string;
10
- };
11
- //# sourceMappingURL=dockerSourceDiscover.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dockerSourceDiscover.d.ts","sourceRoot":"","sources":["../../model/dockerSourceDiscover.ts"],"names":[],"mappings":"AAEA,MAAM,MAAM,oBAAoB,GAAG;IACjC;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC"}
@@ -1,4 +0,0 @@
1
- export type DockerSourceStreams = {
2
- streams: Array<Record<string, any>>;
3
- };
4
- //# sourceMappingURL=dockerSourceStreams.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dockerSourceStreams.d.ts","sourceRoot":"","sources":["../../model/dockerSourceStreams.ts"],"names":[],"mappings":"AAEA,MAAM,MAAM,mBAAmB,GAAG;IAChC,OAAO,EAAE,KAAK,CAAC,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,CAAC;CACrC,CAAC"}