@ingestro/pipelines-angular 1.0.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/README.md ADDED
@@ -0,0 +1,235 @@
1
+ <!-- markdownlint-disable -->
2
+ <p align="center">
3
+ <a href="https://ingestro.com/" rel="noopener" target="_blank"><img width="150" src="https://s3.eu-central-1.amazonaws.com/general-upload.ingestro.com/ingestro_logo_darkblue.svg" alt="Ingestro logo"></a>
4
+ </p>
5
+ <h1 align="center">@ingestro/pipelines-angular</h1>
6
+
7
+ <div align="center">
8
+ Embeddable Angular Components for Ingestro Data Pipelines
9
+
10
+ [![API status](https://img.shields.io/uptimerobot/ratio/m792354517-acd98c6100961072cc093759?color=2fa659&label=uptime)](https://status.ingestro.com/)
11
+ [![npm latest package](https://img.shields.io/npm/v/@ingestro%2Fpipelines-angular?color=5c8ef2&label=npm@latest)](https://badge.fury.io/js/@ingestro%2Fpipelines-angular)
12
+
13
+ An Angular component library that lets your users embed UI workflows for creating and managing Ingestro Data Pipelines directly into your applications.
14
+
15
+ </div>
16
+
17
+ ## Table of Contents
18
+
19
+ - [What is Ingestro Data Pipelines](#what-is-ingestro-data-pipelines)
20
+ - [Features & Components](#features--components)
21
+ - [Authentication](#authentication)
22
+ - [Getting Started](#getting-started)
23
+ - [Embeddables Usage](#embeddables-usage)
24
+ - [Using the API Directly](#using-the-api-directly)
25
+ - [Configuration & Props](#configuration--props-general)
26
+ - [Further Resources](#further-resources)
27
+
28
+ ## What is Ingestro Data Pipelines
29
+
30
+ Ingestro Data Pipelines is a full pipeline product that enables you to build, deploy, monitor and manage automated data ingestion workflows. Key capabilities include:
31
+
32
+ - Defining **connectors** (inputs/outputs) for various sources/destinations
33
+ - Specifying **target data models** (TDMs) to shape output schema
34
+ - Building & running **pipelines**, including scheduling, execution history, error tracking
35
+ - Embeddable Angular UI components ("embeddables") so you can embed parts of the workflow in your own app
36
+ - A REST API for full programmatic control
37
+
38
+ ## Features & Components
39
+
40
+ Here are the main components/ embeddables available in this package. Use them to provide UI workflows for your users inside your application. For full docs, see the [Embeddables Guide](https://docs.ingestro.com/dp/embeddables/).
41
+
42
+ | Embeddable | Purpose |
43
+ | ------------------------ | ------------------------------------------------------------- |
44
+ | `CreatePipeline` | UI to create a new pipeline workflow within your app |
45
+ | `PipelineDetails` | View / edit a specific pipeline |
46
+ | `PipelineList` | Show a list of all pipelines |
47
+ | `ExecutionDetails` | View, inspect and optionally rerun a particular execution run |
48
+ | `ExecutionList` | List of executions for one pipeline |
49
+ | `CreateConnector` | UI to add a new connector (input/output) for your pipelines |
50
+ | `ConnectorDetails` | Inspect/ modify a connector |
51
+ | `ConnectorList` | List available connectors |
52
+ | `CreateTargetDataModel` | UI to create a target data model (TDM) |
53
+ | `TargetDataModelDetails` | View or edit one TDM |
54
+ | `TargetDataModelList` | Listing of TDMs |
55
+
56
+ ## Authentication
57
+
58
+ To use the embeddables or call the API directly, you’ll need an **access token**. The flow is:
59
+
60
+ 1. Get your **license key** (from dashboard.ingestro.com)
61
+ 2. You authenticate using the license key + an identifier (either a user email or a sub-organization identifier). ([Authentication API guide](https://docs.ingestro.com/dp/authentication-api/))
62
+ 3. You receive an `access_token` which you include in subsequent requests
63
+
64
+ **Example: Get an access token**
65
+
66
+ ```bash
67
+ curl -X POST "https://api-gateway.ingestro.com/dp/api/v1/auth/access-token"
68
+ -H "Accept: application/json"
69
+ -H "Content-Type: application/json"
70
+ -d '{
71
+ "license_key": "YOUR_LICENSE_KEY",
72
+ "auth": {
73
+ "identifier": "user@example.com", // or sub-org identifier
74
+ "type": "USER" // or "SUB_ORG"
75
+ }
76
+ }'
77
+ ```
78
+
79
+ Response:
80
+
81
+ ```json
82
+ {
83
+ "access_token": "YOUR_ACCESS_TOKEN"
84
+ }
85
+ ```
86
+
87
+ ## Getting Started
88
+
89
+ Install the package:
90
+
91
+ ```bash
92
+ npm install @ingestro/pipelines-angular
93
+ # or
94
+ yarn add @ingestro/pipelines-angular
95
+ ```
96
+
97
+ ## Embeddables Usage
98
+
99
+ Here’s how to embed a component in your Angular app. All embeddables accept props such as `accessToken`, `settings`, and callbacks (e.g. `onClose`, `onCreate`, etc.). Always consult the specific guide for the embeddable you're using in the [Embeddables docs](https://docs.ingestro.com/dp/embeddables/).
100
+
101
+ **Example for `CreatePipeline`:**
102
+
103
+ ```jsx
104
+ import { CreatePipelineModule, ... } from '@ingestro/pipelines-angular';
105
+
106
+ @NgModule({
107
+ declarations: [CreatePipelineComponent],
108
+ imports: [CreatePipelineModule],
109
+ providers: [],
110
+ bootstrap: [CreatePipelineComponent],
111
+ })
112
+ export class AppModule {}
113
+ ```
114
+
115
+ ```jsx
116
+ <create-pipeline
117
+ [accessToken]="accessToken"
118
+ [templateId]="templateId"
119
+ [configuration]="configuration"
120
+ [settings]="settings"
121
+ (onPipelineCreate)="onPipelineCreate($event)"
122
+ (onClose)="onClose()"
123
+ (onConnectorCreate)="onConnectorCreate($event)"
124
+ (onTdmCreate)="onTdmCreate($event)"
125
+ (onExecutionView)="onExecutionView($event)"
126
+ />
127
+ ```
128
+
129
+ ```jsx
130
+ export class CreatePipelineComponent implements OnInit {
131
+ accessToken!: string;
132
+ templateId!: string;
133
+ configuration!: Configuration;
134
+ settings!: Settings;
135
+
136
+ ngOnInit(): void {
137
+ this.accessToken = "ACCESS_TOKEN";
138
+ this.templateId = "TEMPLATE_ID";
139
+ this.configuration = {
140
+ developerMode: false,
141
+ name: "string",
142
+ tdmId: "string",
143
+ outputConnectorId: "string",
144
+ inputConnectorId: "string",
145
+ errorConfig: {
146
+ errorThreshold: 0,
147
+ },
148
+ scheduleConfig: {
149
+ frequency: "HOURLY",
150
+ interval: 0,
151
+ startsOn: new Date(),
152
+ endsOn: new Date(),
153
+ }
154
+ };
155
+ this.settings = {
156
+ i18nOverrides: {},
157
+ language: "en",
158
+ modal: true,
159
+ allowTdmCreation: false,
160
+ allowInputConnectorCreation: false,
161
+ allowOutputConnectorCreation: false,
162
+ runPipelineOnCreation: false
163
+ };
164
+ }
165
+
166
+ onPipelineCreate({}): void {
167
+ // Handle pipeline creation
168
+ }
169
+
170
+ onClose(): void {
171
+ // Handle close
172
+ }
173
+
174
+ onConnectorCreate({}): void {
175
+ // Handle connector creation
176
+ }
177
+
178
+ onTdmCreate({}): void {
179
+ // Handle TDM creation
180
+ }
181
+
182
+ onExecutionView({}): void {
183
+ // Handle execution view
184
+ }
185
+ }
186
+ ```
187
+
188
+ ## Using the API Directly
189
+
190
+ If you want full control (e.g. automated processes, server-side integrations, or custom UI), you can use the REST API. See the [REST API guide](https://docs.ingestro.com/dp/guide-api/) and relevant sub-APIs.
191
+
192
+ **Example: Get all pipelines**
193
+
194
+ ```bash
195
+ curl -X GET "https://api-gateway.ingestro.com/dp/api/v1/pipeline/"
196
+ -H "Accept: application/json"
197
+ -H "Authorization: Bearer YOUR_ACCESS_TOKEN"
198
+
199
+ ```
200
+
201
+ **Example: Update a pipeline**
202
+
203
+ ```bash
204
+ curl -X PUT "https://api-gateway.ingestro.com/dp/api/v1/pipeline/{pipelineId}"
205
+ -H "Accept: application/json"
206
+ -H "Authorization: Bearer YOUR_ACCESS_TOKEN"
207
+ -H "Content-Type: application/json"
208
+ -d '{
209
+ "name": "New pipeline name",
210
+ "configuration": {},
211
+ "input_connectors": [],
212
+ "output_connectors": [],
213
+ "mapping_config": {}
214
+ }'
215
+
216
+ ```
217
+
218
+ ## Configuration & Props (General)
219
+
220
+ Some common props/settings across embeddables:
221
+
222
+ | Prop / Setting | Description |
223
+ | --------------- | ------------------------------------------------------------------------- |
224
+ | `accessToken` | Token obtained via authentication API (must be passed to all embeddables) |
225
+ | `settings` | UI settings like language, modal behavior, translations etc. |
226
+ | `configuration` | Embeddable-specific configuration options (defaults, initial values) |
227
+ | Callbacks | Events such as `onClose`, `onCreate`, `onUpdate`, `onError` etc. |
228
+
229
+ ## Further Resources
230
+
231
+ - [Authentication API guide](https://docs.ingestro.com/dp/authentication-api/)
232
+ - [Embeddables documentation](https://docs.ingestro.com/dp/embeddables/)
233
+ - [REST API guide](https://docs.ingestro.com/dp/guide-api/)
234
+ - [Connector API docs](https://docs.ingestro.com/dp/connector-api/)
235
+ - [Target Data Model API docs](https://docs.ingestro.com/dp/tdm-api/)