@harnessio/react-rmg-service-client 0.54.0 → 0.56.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.
@@ -0,0 +1,25 @@
1
+ import { UseMutationOptions } from '@tanstack/react-query';
2
+ import type { DeleteReleaseResponseResponse } from '../responses/DeleteReleaseResponseResponse';
3
+ import type { ErrorResponseResponse } from '../responses/ErrorResponseResponse';
4
+ import type { ResponseWithPagination } from '../helpers';
5
+ import { FetcherOptions } from '../../../../fetcher/index.js';
6
+ export interface DeleteReleaseMutationPathParams {
7
+ releaseId: string;
8
+ }
9
+ export interface DeleteReleaseMutationQueryParams {
10
+ orgIdentifier?: string;
11
+ projectIdentifier?: string;
12
+ }
13
+ export interface DeleteReleaseMutationHeaderParams {
14
+ 'Harness-Account': string;
15
+ }
16
+ export type DeleteReleaseOkResponse = ResponseWithPagination<DeleteReleaseResponseResponse>;
17
+ export type DeleteReleaseErrorResponse = ErrorResponseResponse;
18
+ export interface DeleteReleaseProps extends DeleteReleaseMutationPathParams, Omit<FetcherOptions<DeleteReleaseMutationQueryParams, unknown, DeleteReleaseMutationHeaderParams>, 'url'> {
19
+ queryParams: DeleteReleaseMutationQueryParams;
20
+ }
21
+ export declare function deleteRelease(props: DeleteReleaseProps): Promise<DeleteReleaseOkResponse>;
22
+ /**
23
+ * Delete a release. For ADHOC releases, deletes both the release and its stub release group. For RECURRING releases, deletes only the release. The identifier can be either the slug_id or UUID of the release. Cannot delete releases in Running, Paused, or InputWaiting states.
24
+ */
25
+ export declare function useDeleteReleaseMutation(options?: Omit<UseMutationOptions<DeleteReleaseOkResponse, DeleteReleaseErrorResponse, DeleteReleaseProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<DeleteReleaseOkResponse, import("..").Error, DeleteReleaseProps, unknown>;
@@ -0,0 +1,14 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ import { useMutation } from '@tanstack/react-query';
5
+ import { fetcher } from '../../../../fetcher/index.js';
6
+ export function deleteRelease(props) {
7
+ return fetcher(Object.assign({ url: `/release/${props.releaseId}`, method: 'DELETE' }, props));
8
+ }
9
+ /**
10
+ * Delete a release. For ADHOC releases, deletes both the release and its stub release group. For RECURRING releases, deletes only the release. The identifier can be either the slug_id or UUID of the release. Cannot delete releases in Running, Paused, or InputWaiting states.
11
+ */
12
+ export function useDeleteReleaseMutation(options) {
13
+ return useMutation((mutateProps) => deleteRelease(mutateProps), options);
14
+ }
@@ -9,6 +9,8 @@ export type { DeleteOrchestrationProcessErrorResponse, DeleteOrchestrationProces
9
9
  export { deleteOrchestrationProcess, useDeleteOrchestrationProcessMutation, } from './hooks/useDeleteOrchestrationProcessMutation';
10
10
  export type { DeleteReleaseGroupErrorResponse, DeleteReleaseGroupMutationPathParams, DeleteReleaseGroupMutationQueryParams, DeleteReleaseGroupOkResponse, DeleteReleaseGroupProps, } from './hooks/useDeleteReleaseGroupMutation';
11
11
  export { deleteReleaseGroup, useDeleteReleaseGroupMutation, } from './hooks/useDeleteReleaseGroupMutation';
12
+ export type { DeleteReleaseErrorResponse, DeleteReleaseMutationPathParams, DeleteReleaseMutationQueryParams, DeleteReleaseOkResponse, DeleteReleaseProps, } from './hooks/useDeleteReleaseMutation';
13
+ export { deleteRelease, useDeleteReleaseMutation } from './hooks/useDeleteReleaseMutation';
12
14
  export type { DeleteTaskCommentErrorResponse, DeleteTaskCommentMutationPathParams, DeleteTaskCommentMutationQueryParams, DeleteTaskCommentOkResponse, DeleteTaskCommentProps, } from './hooks/useDeleteTaskCommentMutation';
13
15
  export { deleteTaskComment, useDeleteTaskCommentMutation, } from './hooks/useDeleteTaskCommentMutation';
14
16
  export type { GetActivityRetryHistoryByIdentifiersErrorResponse, GetActivityRetryHistoryByIdentifiersOkResponse, GetActivityRetryHistoryByIdentifiersProps, GetActivityRetryHistoryByIdentifiersQueryPathParams, GetActivityRetryHistoryByIdentifiersQueryQueryParams, } from './hooks/useGetActivityRetryHistoryByIdentifiersQuery';
@@ -158,6 +160,7 @@ export type { CreateOrchestrationProcessResponseResponse } from './responses/Cre
158
160
  export type { CreateReleaseGroupResponseResponse } from './responses/CreateReleaseGroupResponseResponse';
159
161
  export type { CreateTaskCommentResponseResponse } from './responses/CreateTaskCommentResponseResponse';
160
162
  export type { DeleteReleaseGroupResponseResponse } from './responses/DeleteReleaseGroupResponseResponse';
163
+ export type { DeleteReleaseResponseResponse } from './responses/DeleteReleaseResponseResponse';
161
164
  export type { EnvironmentDashboardResponseResponse } from './responses/EnvironmentDashboardResponseResponse';
162
165
  export type { EnvironmentListPerReleaseResponseResponse } from './responses/EnvironmentListPerReleaseResponseResponse';
163
166
  export type { ErrorResponseResponse } from './responses/ErrorResponseResponse';
@@ -328,3 +331,4 @@ export type { TimeRangeDto } from './schemas/TimeRangeDto';
328
331
  export type { TriggerType } from './schemas/TriggerType';
329
332
  export type { TriggeredByDto } from './schemas/TriggeredByDto';
330
333
  export type { User } from './schemas/User';
334
+ export type { Weekday } from './schemas/Weekday';
@@ -3,6 +3,7 @@ export { deleteOrchestrationActivity, useDeleteOrchestrationActivityMutation, }
3
3
  export { deleteOrchestrationProcessInput, useDeleteOrchestrationProcessInputMutation, } from './hooks/useDeleteOrchestrationProcessInputMutation';
4
4
  export { deleteOrchestrationProcess, useDeleteOrchestrationProcessMutation, } from './hooks/useDeleteOrchestrationProcessMutation';
5
5
  export { deleteReleaseGroup, useDeleteReleaseGroupMutation, } from './hooks/useDeleteReleaseGroupMutation';
6
+ export { deleteRelease, useDeleteReleaseMutation } from './hooks/useDeleteReleaseMutation';
6
7
  export { deleteTaskComment, useDeleteTaskCommentMutation, } from './hooks/useDeleteTaskCommentMutation';
7
8
  export { getActivityRetryHistoryByIdentifiers, useGetActivityRetryHistoryByIdentifiersQuery, } from './hooks/useGetActivityRetryHistoryByIdentifiersQuery';
8
9
  export { getEventsByEntityTypeAndId, useGetEventsByEntityTypeAndIdQuery, } from './hooks/useGetEventsByEntityTypeAndIdQuery';
@@ -0,0 +1,14 @@
1
+ export interface DeleteReleaseResponseResponse {
2
+ /**
3
+ * UUID of the deleted release
4
+ */
5
+ id: string;
6
+ /**
7
+ * Source of the deleted release (ADHOC or RECURRING)
8
+ */
9
+ source: string;
10
+ /**
11
+ * Indicates whether the deletion was successful
12
+ */
13
+ success: boolean;
14
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
@@ -1,5 +1,6 @@
1
1
  import type { ReleaseFrequency } from '../schemas/ReleaseFrequency';
2
2
  import type { Freq } from '../schemas/Freq';
3
+ import type { Weekday } from '../schemas/Weekday';
3
4
  export interface ReleaseCadence {
4
5
  /**
5
6
  * duration for the release cadence.
@@ -17,9 +18,14 @@ export interface ReleaseCadence {
17
18
  */
18
19
  interval: number;
19
20
  /**
20
- * weekday
21
+ * Single weekday (e.g. '1MO'). Deprecated: use weekdays instead.
22
+ * @deprecated
21
23
  */
22
24
  weekday?: string;
25
+ /**
26
+ * Multiple weekdays for the custom cadence (e.g. [MO, TU, WE, TH]).
27
+ */
28
+ weekdays?: Weekday[];
23
29
  };
24
30
  /**
25
31
  * Start date of the release cadence (YYYY-MM-DD).
@@ -47,6 +47,10 @@ export interface ReleaseDto {
47
47
  * Identifier for the release group
48
48
  */
49
49
  releaseGroupId: string;
50
+ /**
51
+ * Source of the release (ADHOC for ad hoc releases, RECURRING for scheduled releases)
52
+ */
53
+ source?: 'ADHOC' | 'RECURRING';
50
54
  /**
51
55
  * Current status of the release
52
56
  */
@@ -0,0 +1,4 @@
1
+ /**
2
+ * Day of the week code for custom cadence scheduling.
3
+ */
4
+ export type Weekday = 'FR' | 'MO' | 'SA' | 'SU' | 'TH' | 'TU' | 'WE';
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@harnessio/react-rmg-service-client",
3
- "version": "0.54.0",
3
+ "version": "0.56.0",
4
4
  "description": "Harness Release Management Service APIs integrated with react hooks",
5
5
  "author": "Harness Inc",
6
6
  "license": "MIT",