@hahnpro/hpc-api 2026.1.0 → 2026.1.1

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/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # @hahnpro/hpc-api
2
2
 
3
+ ## 2026.1.1
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated Endpoint, TimeSeries and Vault Interfaces
8
+ - Added arbitrary options to FlowDeploymentService::updateOne(...) method
9
+
3
10
  ## 2026.1.0
4
11
 
5
12
  - Updated Task Interface
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hahnpro/hpc-api",
3
- "version": "2026.1.0",
3
+ "version": "2026.1.1",
4
4
  "description": "Module for easy access to the HahnPRO Cloud API",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -1,3 +1,5 @@
1
+ import { Author } from './author.interface';
2
+ import { Owner } from './owner.interface';
1
3
  export interface Endpoint {
2
4
  id?: string;
3
5
  name: string;
@@ -14,6 +16,12 @@ export interface Endpoint {
14
16
  nbOfNotificationsBetweenPauseInterval: number;
15
17
  readPermissions: string[];
16
18
  readWritePermissions: string[];
19
+ owner?: Owner;
20
+ createdBy?: Author;
21
+ updatedBy?: Author;
22
+ createdAt?: string;
23
+ updatedAt?: string;
24
+ deletedAt?: string;
17
25
  }
18
26
  export interface EndpointLog {
19
27
  id?: string;
@@ -19,7 +19,7 @@ export type { NotificationRule, StatusRule, TagRule } from './notification-rule.
19
19
  export type { Notification, NotificationType } from './notification.interface';
20
20
  export type { OrganizationRoleRepresentation } from './organization-role-representation.interface';
21
21
  export { OrganizationMembersInviteOrAdd } from './organization.interface';
22
- export type { Organization, OrganizationCreateDto, OrganizationData, OrganizationDataKind, OrganizationDomain, OrganizationExtraProperties, OrganizationName, OrganizationRolesAdjustment, OrganizationSearchQuery, SubscriptionType, UserWithOrgRoles, } from './organization.interface';
22
+ export type { Organization, CreateOrganizationDto, OrganizationData, OrganizationDataKind, OrganizationDomain, OrganizationExtraProperties, OrganizationName, OrganizationRolesAdjustment, OrganizationSearchQuery, SubscriptionType, UserWithOrgRoles, } from './organization.interface';
23
23
  export type { CreateOrgWithResourcesDto, OrganizationResourcesProgress, OrganizationResourcesProgressDto, OrganizationResourcesProgressErrorDto, } from './organizations-resources.interface';
24
24
  export type { Owner } from './owner.interface';
25
25
  export type { DeleteAssetQuery, DeleteAssetTypeQuery, DeleteQuery } from './query.interface';
@@ -20,7 +20,7 @@ export interface Organization extends Api {
20
20
  deletionRequested?: boolean;
21
21
  isSuperOrganization?: boolean;
22
22
  }
23
- export interface OrganizationCreateDto {
23
+ export interface CreateOrganizationDto {
24
24
  name: string;
25
25
  description?: string;
26
26
  domains?: string[];
@@ -1,3 +1,5 @@
1
+ import { Author } from './author.interface';
2
+ import { Owner } from './owner.interface';
1
3
  export interface TimeSeries {
2
4
  id?: string;
3
5
  name: string;
@@ -15,6 +17,11 @@ export interface TimeSeries {
15
17
  autoDelData: Date;
16
18
  autoDelBucket: Date;
17
19
  metadata?: Record<string, any>;
20
+ owner?: Owner;
21
+ createdBy?: Author;
22
+ updatedBy?: Author;
23
+ createdAt?: string;
24
+ updatedAt?: string;
18
25
  deletedAt?: string;
19
26
  }
20
27
  export interface TimeSeriesCondition {
@@ -1,3 +1,5 @@
1
+ import { Author } from './author.interface';
2
+ import { Owner } from './owner.interface';
1
3
  export interface VaultSecret {
2
4
  id?: string;
3
5
  name: string;
@@ -6,5 +8,8 @@ export interface VaultSecret {
6
8
  version?: number;
7
9
  readPermissions: string[];
8
10
  readWritePermissions: string[];
11
+ owner?: Owner;
12
+ createdBy?: Author;
13
+ updatedBy?: Author;
9
14
  updatedAt?: string;
10
15
  }
@@ -1,6 +1,6 @@
1
1
  import { Observable } from 'rxjs';
2
2
  import { APIBaseMock, OrganizationsMockService } from '.';
3
- import { Filter, Organization, OrganizationCreateDto, OrganizationResourcesProgress, OrganizationSearchQuery, Paginated, RequestParameter, ServerSentEvent, SubscriptionType, UserWithOrgRoles } from '../interfaces';
3
+ import { CreateOrganizationDto, Filter, Organization, OrganizationResourcesProgress, OrganizationSearchQuery, Paginated, RequestParameter, ServerSentEvent, SubscriptionType, UserWithOrgRoles } from '../interfaces';
4
4
  import { OrganizationsAdministrationService } from '../services';
5
5
  export declare class OrganizationsAdministrationMockService extends APIBaseMock<Organization> implements OrganizationsAdministrationService {
6
6
  private readonly organizationMockService;
@@ -14,6 +14,6 @@ export declare class OrganizationsAdministrationMockService extends APIBaseMock<
14
14
  getMany(params?: RequestParameter): Promise<Paginated<Organization>>;
15
15
  getManyFiltered(filter: Filter, params?: RequestParameter): Promise<Paginated<Organization>>;
16
16
  search(query: OrganizationSearchQuery): Promise<Organization[]>;
17
- createOrganization(organizationCreateDto: OrganizationCreateDto, emailsToInvite: string[], emailsToAdd: string[], createOrgAsOwner?: boolean): Promise<Organization>;
17
+ createOrganization(organizationCreateDto: CreateOrganizationDto, usersWithOrgRolesToInvite: UserWithOrgRoles[], usersWithOrgRolesToAdd: UserWithOrgRoles[], createOrgAsOwner?: boolean): Promise<Organization>;
18
18
  getOrganizationDeletionProgress(organizationId: string): Observable<ServerSentEvent<OrganizationResourcesProgress>>;
19
19
  }
@@ -76,9 +76,9 @@ class OrganizationsAdministrationMockService extends _1.APIBaseMock {
76
76
  async search(query) {
77
77
  return Promise.resolve(this.data.filter((entry) => entry.name === query.name || entry.name.startsWith(query.name)));
78
78
  }
79
- createOrganization(organizationCreateDto, emailsToInvite, emailsToAdd, createOrgAsOwner = false) {
79
+ createOrganization(organizationCreateDto, usersWithOrgRolesToInvite, usersWithOrgRolesToAdd, createOrgAsOwner = false) {
80
80
  if (!organizationCreateDto?.name ||
81
- ([...emailsToInvite, ...emailsToAdd].length === 0 && !createOrgAsOwner) ||
81
+ ([...usersWithOrgRolesToInvite, ...usersWithOrgRolesToAdd].length === 0 && !createOrgAsOwner) ||
82
82
  this.data.some((org) => org.name === organizationCreateDto.name)) {
83
83
  return Promise.reject('Bad Request');
84
84
  }
@@ -1,12 +1,12 @@
1
1
  import { APIBaseMock } from '.';
2
- import { KeycloakProfile, Organization, OrganizationCreateDto, OrganizationData, OrganizationDataKind, OrganizationName, OrganizationRolesAdjustment } from '../interfaces';
2
+ import { CreateOrganizationDto, KeycloakProfile, Organization, OrganizationData, OrganizationDataKind, OrganizationName, OrganizationRolesAdjustment } from '../interfaces';
3
3
  import { OrganizationsService } from '../services';
4
4
  import { OrganizationRoleRepresentation } from '../services/organizations.service';
5
5
  export declare class OrganizationsMockService extends APIBaseMock<Organization> implements OrganizationsService {
6
6
  constructor(organizations: Organization[]);
7
- addOrganizationInvitation(id: string, email: string, roles: string[]): Promise<void>;
7
+ inviteUser(id: string, email: string, roles: string[]): Promise<void>;
8
8
  getOrganizationIdByName(name: string): Promise<OrganizationName>;
9
- addOne(dto: OrganizationCreateDto): Promise<Organization>;
9
+ addOne(dto: CreateOrganizationDto): Promise<Organization>;
10
10
  getOneCombined(id: string): Promise<Organization>;
11
11
  addOrganizationRole(id: string, roleDto: OrganizationRoleRepresentation): Promise<OrganizationRoleRepresentation[]>;
12
12
  checkForOrganizationUniqueness(name: string): Promise<void>;
@@ -8,7 +8,7 @@ class OrganizationsMockService extends _1.APIBaseMock {
8
8
  super(null);
9
9
  this.data = organizations;
10
10
  }
11
- addOrganizationInvitation(id, email, roles) {
11
+ inviteUser(id, email, roles) {
12
12
  if (!id || !email || !roles?.length) {
13
13
  return Promise.reject('Bad Request');
14
14
  }
@@ -11,6 +11,7 @@ export declare class FlowDeploymentService extends BaseService {
11
11
  addMany(dto: any[], options?: TokenOption): Promise<FlowDeployment[]>;
12
12
  updateOne(id: string, dto: any, options?: TokenOption & {
13
13
  force: boolean;
14
+ [key: string]: any;
14
15
  }): Promise<FlowDeployment>;
15
16
  getDeploymentStatistics(id: string, options?: TokenOption): Promise<FlowDeploymentStatistic>;
16
17
  getDeploymentMetrics(id: string, range?: string, interval?: string, options?: TokenOption): Promise<FlowDeploymentMetrics>;
@@ -1,6 +1,6 @@
1
1
  import { Observable } from 'rxjs';
2
2
  import { APIBase } from '../api-base';
3
- import { Filter, Organization, OrganizationCreateDto, OrganizationResourcesProgress, OrganizationSearchQuery, Paginated, RequestParameter, ServerSentEvent, SubscriptionType, UserWithOrgRoles } from '../interfaces';
3
+ import { CreateOrganizationDto, Filter, Organization, OrganizationResourcesProgress, OrganizationSearchQuery, Paginated, RequestParameter, ServerSentEvent, SubscriptionType, UserWithOrgRoles } from '../interfaces';
4
4
  import { HttpClientService } from './';
5
5
  /**
6
6
  * Service for managing organizations with administrative privileges (superuser role required).
@@ -41,13 +41,13 @@ export declare class OrganizationsAdministrationService extends APIBase {
41
41
  * Creates an organization with a free subscription and invites or adds a user to it.
42
42
  * The owner of the organization can be either the user or the service account 'organization-client', depending on the 'createOrgAsOwner' flag in the OrganizationCreateFlowDto.
43
43
  *
44
- * @param {OrganizationCreateDto} organizationCreateDto - The data transfer object containing the organization details for creation
45
- * @param {string[]} emailsToInvite - The email addresses of the users to be invited to the organization
46
- * @param {string[]} emailsToAdd - The email addresses of the users to be added without an invitation to the organization
44
+ * @param {CreateOrganizationDto} createOrganizationDto - The data transfer object containing the organization details for creation
45
+ * @param {UserWithOrgRoles[]} usersWithOrgRolesToInvite - The email addresses with the individual org roles of the users to be invited to the organization
46
+ * @param {UserWithOrgRoles[]} usersWithOrgRolesToAdd - The email addresses with the individual org roles of the users to be added without an invitation to the organization
47
47
  * @param {boolean} createOrgAsOwner - Whether to create the organization with the user as the owner
48
48
  * @returns {Promise<Organization>} - An promise of the created organization
49
49
  */
50
- createOrganization(organizationCreateDto: OrganizationCreateDto, emailsToInvite: string[], emailsToAdd: string[], createOrgAsOwner?: boolean): Promise<Organization>;
50
+ createOrganization(createOrganizationDto: CreateOrganizationDto, usersWithOrgRolesToInvite: UserWithOrgRoles[], usersWithOrgRolesToAdd: UserWithOrgRoles[], createOrgAsOwner?: boolean): Promise<Organization>;
51
51
  addOrganizationMembers(id: string, usersWithOrgRoles: UserWithOrgRoles[]): Promise<void>;
52
52
  addSubscriptionToOrganization(id: string, type: SubscriptionType): Promise<Organization>;
53
53
  /**
@@ -56,17 +56,17 @@ class OrganizationsAdministrationService extends api_base_1.APIBase {
56
56
  * Creates an organization with a free subscription and invites or adds a user to it.
57
57
  * The owner of the organization can be either the user or the service account 'organization-client', depending on the 'createOrgAsOwner' flag in the OrganizationCreateFlowDto.
58
58
  *
59
- * @param {OrganizationCreateDto} organizationCreateDto - The data transfer object containing the organization details for creation
60
- * @param {string[]} emailsToInvite - The email addresses of the users to be invited to the organization
61
- * @param {string[]} emailsToAdd - The email addresses of the users to be added without an invitation to the organization
59
+ * @param {CreateOrganizationDto} createOrganizationDto - The data transfer object containing the organization details for creation
60
+ * @param {UserWithOrgRoles[]} usersWithOrgRolesToInvite - The email addresses with the individual org roles of the users to be invited to the organization
61
+ * @param {UserWithOrgRoles[]} usersWithOrgRolesToAdd - The email addresses with the individual org roles of the users to be added without an invitation to the organization
62
62
  * @param {boolean} createOrgAsOwner - Whether to create the organization with the user as the owner
63
63
  * @returns {Promise<Organization>} - An promise of the created organization
64
64
  */
65
- createOrganization(organizationCreateDto, emailsToInvite, emailsToAdd, createOrgAsOwner = false) {
65
+ createOrganization(createOrganizationDto, usersWithOrgRolesToInvite, usersWithOrgRolesToAdd, createOrgAsOwner = false) {
66
66
  return this.httpClient.post(`${this.basePath}/create-org`, {
67
- organizationDto: organizationCreateDto,
68
- emailsToInvite,
69
- emailsToAdd,
67
+ createOrganizationDto,
68
+ usersWithOrgRolesToInvite,
69
+ usersWithOrgRolesToAdd,
70
70
  createOrgAsOwner,
71
71
  });
72
72
  }
@@ -1,5 +1,5 @@
1
1
  import { APIBase } from '../api-base';
2
- import { KeycloakProfile, Organization, OrganizationCreateDto, OrganizationData, OrganizationDataKind, OrganizationName, OrganizationRolesAdjustment } from '../interfaces';
2
+ import { CreateOrganizationDto, KeycloakProfile, Organization, OrganizationData, OrganizationDataKind, OrganizationName, OrganizationRolesAdjustment } from '../interfaces';
3
3
  import { HttpClientService } from './';
4
4
  export declare class OrganizationsService extends APIBase {
5
5
  constructor(httpClientClient: HttpClientService);
@@ -9,7 +9,7 @@ export declare class OrganizationsService extends APIBase {
9
9
  * @param dto organization information
10
10
  * @returns newly created organization
11
11
  */
12
- addOne(dto: OrganizationCreateDto): Promise<Organization>;
12
+ addOne(dto: CreateOrganizationDto): Promise<Organization>;
13
13
  /**
14
14
  * Invite a user to an organization.
15
15
  *
@@ -18,7 +18,7 @@ export declare class OrganizationsService extends APIBase {
18
18
  * @param roles roles (names) which the user should get in the organization
19
19
  * @returns newly created invitation
20
20
  */
21
- addOrganizationInvitation(id: string, email: string, roles: string[]): Promise<void>;
21
+ inviteUser(id: string, email: string, roles: string[]): Promise<void>;
22
22
  /**
23
23
  * Add organization role to an organization.
24
24
  *
@@ -23,7 +23,7 @@ class OrganizationsService extends api_base_1.APIBase {
23
23
  * @param roles roles (names) which the user should get in the organization
24
24
  * @returns newly created invitation
25
25
  */
26
- addOrganizationInvitation(id, email, roles) {
26
+ inviteUser(id, email, roles) {
27
27
  return this.httpClient.post(`${this.basePath}/${id}/data/invitations`, { roles, email });
28
28
  }
29
29
  /**