@ignos/api-client 20260826.246.1 → 20260826.247.1-alpha

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.
@@ -2879,6 +2879,69 @@ export declare class InspectMatchSpecificationsClient extends AuthorizedApiBase
2879
2879
  listSpecifications(): Promise<ImaSpecificationLiteDto[]>;
2880
2880
  protected processListSpecifications(response: Response): Promise<ImaSpecificationLiteDto[]>;
2881
2881
  }
2882
+ export interface IInspectSchemaCreatorClient {
2883
+ getSchemaCreatorState(id: string): Promise<SchemaCreatorStateDto>;
2884
+ /**
2885
+ * Creates the initial creator state for a schema version. Returns 409 if
2886
+ state already exists; the caller should re-fetch it instead of writing.
2887
+ */
2888
+ createSchemaCreatorState(id: string, state: SchemaCreatorStateDto): Promise<SchemaCreatorStateDto>;
2889
+ updateSchemaCreatorState(id: string, state: SchemaCreatorStateDto): Promise<SchemaCreatorStateDto>;
2890
+ /**
2891
+ * Starts a full drawing AI parse: clears every element and locks the
2892
+ schema for every viewer until it completes. If one is already in
2893
+ progress, returns that instead of starting a second one.
2894
+ */
2895
+ requestSchemaCreatorDocumentParse(id: string): Promise<SchemaCreatorStateDto>;
2896
+ /**
2897
+ * Stamps the creator state's balloons onto the schema's drawing PDF and
2898
+ returns a temporary download link.
2899
+ */
2900
+ exportSchemaCreatorDrawing(id: string): Promise<DownloadDto>;
2901
+ /**
2902
+ * Starts an async snip resolve; the result is delivered through the
2903
+ SchemaCreatorSnipResolved SignalR notification.
2904
+ * @param image (optional)
2905
+ */
2906
+ requestSchemaCreatorSnipParse(id: string, elementId: string, image: FileParameter | null | undefined): Promise<void>;
2907
+ }
2908
+ export declare class InspectSchemaCreatorClient extends AuthorizedApiBase implements IInspectSchemaCreatorClient {
2909
+ private http;
2910
+ private baseUrl;
2911
+ constructor(configuration: IApiClientConfig, baseUrl?: string, http?: {
2912
+ fetch(url: RequestInfo, init?: RequestInit): Promise<Response>;
2913
+ });
2914
+ getSchemaCreatorState(id: string): Promise<SchemaCreatorStateDto>;
2915
+ protected processGetSchemaCreatorState(response: Response): Promise<SchemaCreatorStateDto>;
2916
+ /**
2917
+ * Creates the initial creator state for a schema version. Returns 409 if
2918
+ state already exists; the caller should re-fetch it instead of writing.
2919
+ */
2920
+ createSchemaCreatorState(id: string, state: SchemaCreatorStateDto): Promise<SchemaCreatorStateDto>;
2921
+ protected processCreateSchemaCreatorState(response: Response): Promise<SchemaCreatorStateDto>;
2922
+ updateSchemaCreatorState(id: string, state: SchemaCreatorStateDto): Promise<SchemaCreatorStateDto>;
2923
+ protected processUpdateSchemaCreatorState(response: Response): Promise<SchemaCreatorStateDto>;
2924
+ /**
2925
+ * Starts a full drawing AI parse: clears every element and locks the
2926
+ schema for every viewer until it completes. If one is already in
2927
+ progress, returns that instead of starting a second one.
2928
+ */
2929
+ requestSchemaCreatorDocumentParse(id: string): Promise<SchemaCreatorStateDto>;
2930
+ protected processRequestSchemaCreatorDocumentParse(response: Response): Promise<SchemaCreatorStateDto>;
2931
+ /**
2932
+ * Stamps the creator state's balloons onto the schema's drawing PDF and
2933
+ returns a temporary download link.
2934
+ */
2935
+ exportSchemaCreatorDrawing(id: string): Promise<DownloadDto>;
2936
+ protected processExportSchemaCreatorDrawing(response: Response): Promise<DownloadDto>;
2937
+ /**
2938
+ * Starts an async snip resolve; the result is delivered through the
2939
+ SchemaCreatorSnipResolved SignalR notification.
2940
+ * @param image (optional)
2941
+ */
2942
+ requestSchemaCreatorSnipParse(id: string, elementId: string, image: FileParameter | null | undefined): Promise<void>;
2943
+ protected processRequestSchemaCreatorSnipParse(response: Response): Promise<void>;
2944
+ }
2882
2945
  export interface IMeasurementFormSchemasAdminClient {
2883
2946
  getArchivedMeasurementFormSchema(id: string): Promise<MeasurementFormSchemaDto>;
2884
2947
  createMeasurementForm(request: CreateMeasurementFormSchema): Promise<MeasurementFormDto>;
@@ -8605,10 +8668,9 @@ export interface ImaDocumentTypesResultsDto {
8605
8668
  export interface ImaSupplementaryCheckResultDto {
8606
8669
  heatNumbers?: string[];
8607
8670
  status?: string | null;
8608
- documentId?: string | null;
8671
+ errorString?: string | null;
8609
8672
  acceptable?: boolean | null;
8610
8673
  standards: string[];
8611
- summary?: string | null;
8612
8674
  override?: ImaResultLineOverrideDto | null;
8613
8675
  }
8614
8676
  export interface ImaOverrideMaterialCheckRequestDto {
@@ -9154,6 +9216,99 @@ export interface ImaSpecificationLiteDto {
9154
9216
  updated: Date;
9155
9217
  isDeleted: boolean;
9156
9218
  }
9219
+ export interface SchemaCreatorStateDto {
9220
+ settings: SchemaCreatorSettingsDto;
9221
+ elements: SchemaCreatorElementDto[];
9222
+ documentParseStatus?: SchemaCreatorDocumentParseStatusDto | null;
9223
+ isAutoGenerated?: boolean;
9224
+ createdBy?: SchemaCreatorAuditInfoDto | null;
9225
+ createdAt?: Date | null;
9226
+ updatedBy?: SchemaCreatorAuditInfoDto | null;
9227
+ updatedAt?: Date | null;
9228
+ }
9229
+ export interface SchemaCreatorSettingsDto {
9230
+ unit?: UnitOfMeasureDto;
9231
+ tolerance?: GeneralToleranceDto;
9232
+ balloonSize?: number;
9233
+ transparentBalloons?: boolean;
9234
+ }
9235
+ export type UnitOfMeasureDto = "Millimeter" | "Inch";
9236
+ export type GeneralToleranceDto = "NotSet" | "Fine" | "Medium" | "Coarse" | "VeryCoarse";
9237
+ export interface SchemaCreatorElementDto {
9238
+ id: string;
9239
+ kind: SchemaCreatorElementKindDto;
9240
+ drawings: SchemaCreatorElementDrawingsDto;
9241
+ isDirty?: boolean | null;
9242
+ values?: SchemaCreatorElementValuesDto | null;
9243
+ parseResult?: SchemaCreatorSnipResultDto | null;
9244
+ resolveAttempt?: SchemaCreatorParseAttemptDto | null;
9245
+ createdBy?: SchemaCreatorAuditInfoDto | null;
9246
+ createdAt?: Date | null;
9247
+ updatedBy?: SchemaCreatorAuditInfoDto | null;
9248
+ updatedAt?: Date | null;
9249
+ }
9250
+ export type SchemaCreatorElementKindDto = "Pending" | "Auto" | "Manual";
9251
+ export interface SchemaCreatorElementDrawingsDto {
9252
+ snip: SchemaCreatorSnipDto;
9253
+ balloon: SchemaCreatorPointDto;
9254
+ pageIndex: number;
9255
+ }
9256
+ export interface SchemaCreatorSnipDto {
9257
+ rect: SchemaCreatorRectDto;
9258
+ rotation?: number | null;
9259
+ unrotatedRect?: SchemaCreatorRectDto | null;
9260
+ }
9261
+ export interface SchemaCreatorRectDto {
9262
+ origin: SchemaCreatorPointDto;
9263
+ size: SchemaCreatorSizeDto;
9264
+ }
9265
+ export interface SchemaCreatorPointDto {
9266
+ x: number;
9267
+ y: number;
9268
+ }
9269
+ export interface SchemaCreatorSizeDto {
9270
+ width: number;
9271
+ height: number;
9272
+ }
9273
+ export interface SchemaCreatorElementValuesDto {
9274
+ reference: number;
9275
+ nominal?: number | null;
9276
+ nominalText?: string | null;
9277
+ plusTolerance?: number | null;
9278
+ minusTolerance?: number | null;
9279
+ coatingThickness?: number | null;
9280
+ measurementFrequency: MeasurementFrequency;
9281
+ measurementFrequencyParameter?: number | null;
9282
+ type?: string | null;
9283
+ count?: number | null;
9284
+ comment?: string | null;
9285
+ canCopy: boolean;
9286
+ visibleToCustomer: boolean;
9287
+ isDocumentedExternally: boolean;
9288
+ }
9289
+ export type MeasurementFrequency = "All" | "FirstArticle" | "NFirst" | "NPercent" | "ISO2859" | "Nth" | "FirstAndLast" | "None";
9290
+ export interface SchemaCreatorSnipResultDto {
9291
+ nominal?: number | null;
9292
+ nominalText?: string | null;
9293
+ plusTolerance?: number | null;
9294
+ minusTolerance?: number | null;
9295
+ count?: number | null;
9296
+ }
9297
+ export interface SchemaCreatorParseAttemptDto {
9298
+ startedAt: Date;
9299
+ errorType?: SchemaCreatorParseErrorTypeDto | null;
9300
+ errorMessage?: string | null;
9301
+ }
9302
+ export type SchemaCreatorParseErrorTypeDto = "Timeout" | "ParseError";
9303
+ export interface SchemaCreatorAuditInfoDto {
9304
+ objectId: string;
9305
+ userId: string;
9306
+ userFullName?: string | null;
9307
+ }
9308
+ export interface SchemaCreatorDocumentParseStatusDto {
9309
+ inProgress: boolean;
9310
+ attempt?: SchemaCreatorParseAttemptDto | null;
9311
+ }
9157
9312
  export interface MeasurementFormSchemaDto {
9158
9313
  id: string;
9159
9314
  versionId: number;
@@ -9185,9 +9340,7 @@ export interface MeasurementFormSchemaDto {
9185
9340
  }
9186
9341
  export type MeasurementFormStatus = "Draft" | "Released" | "Revoked";
9187
9342
  export type MeasurementFormSource = "Unknown" | "InspectionXpert" | "Excel" | "Manual";
9188
- export type UnitOfMeasureDto = "Millimeter" | "Inch";
9189
9343
  export type DimensionSettingDto = "Tolerance" | "MinMaxDimension";
9190
- export type GeneralToleranceDto = "NotSet" | "Fine" | "Medium" | "Coarse" | "VeryCoarse";
9191
9344
  export interface MeasurementFormSchemaAttachmentDto {
9192
9345
  url: string;
9193
9346
  title: string;
@@ -9236,7 +9389,6 @@ export interface MeasurementFormGroupedElementDto {
9236
9389
  isValid: boolean;
9237
9390
  validationErrorMessage?: string | null;
9238
9391
  }
9239
- export type MeasurementFrequency = "All" | "FirstArticle" | "NFirst" | "NPercent" | "ISO2859" | "Nth" | "FirstAndLast" | "None";
9240
9392
  export type MeasurementFormValueType = "None" | "Bool" | "Decimal" | "String";
9241
9393
  export type BonusType = "None" | "Positive" | "PositiveAndNegative";
9242
9394
  export interface MeasurementFormLinkedSchemaDto {
@@ -23815,6 +23815,281 @@ export class InspectMatchSpecificationsClient extends AuthorizedApiBase {
23815
23815
  return Promise.resolve(null);
23816
23816
  }
23817
23817
  }
23818
+ export class InspectSchemaCreatorClient extends AuthorizedApiBase {
23819
+ constructor(configuration, baseUrl, http) {
23820
+ super(configuration);
23821
+ this.http = http ? http : window;
23822
+ this.baseUrl = baseUrl !== null && baseUrl !== void 0 ? baseUrl : "";
23823
+ }
23824
+ getSchemaCreatorState(id) {
23825
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate";
23826
+ if (id === undefined || id === null)
23827
+ throw new globalThis.Error("The parameter 'id' must be defined.");
23828
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
23829
+ url_ = url_.replace(/[?&]$/, "");
23830
+ let options_ = {
23831
+ method: "GET",
23832
+ headers: {
23833
+ "Accept": "application/json"
23834
+ }
23835
+ };
23836
+ return this.transformOptions(options_).then(transformedOptions_ => {
23837
+ return this.http.fetch(url_, transformedOptions_);
23838
+ }).then((_response) => {
23839
+ return this.processGetSchemaCreatorState(_response);
23840
+ });
23841
+ }
23842
+ processGetSchemaCreatorState(response) {
23843
+ const status = response.status;
23844
+ let _headers = {};
23845
+ if (response.headers && response.headers.forEach) {
23846
+ response.headers.forEach((v, k) => _headers[k] = v);
23847
+ }
23848
+ ;
23849
+ if (status === 200) {
23850
+ return response.text().then((_responseText) => {
23851
+ let result200 = null;
23852
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
23853
+ return result200;
23854
+ });
23855
+ }
23856
+ else if (status !== 200 && status !== 204) {
23857
+ return response.text().then((_responseText) => {
23858
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
23859
+ });
23860
+ }
23861
+ return Promise.resolve(null);
23862
+ }
23863
+ /**
23864
+ * Creates the initial creator state for a schema version. Returns 409 if
23865
+ state already exists; the caller should re-fetch it instead of writing.
23866
+ */
23867
+ createSchemaCreatorState(id, state) {
23868
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate";
23869
+ if (id === undefined || id === null)
23870
+ throw new globalThis.Error("The parameter 'id' must be defined.");
23871
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
23872
+ url_ = url_.replace(/[?&]$/, "");
23873
+ const content_ = JSON.stringify(state);
23874
+ let options_ = {
23875
+ body: content_,
23876
+ method: "POST",
23877
+ headers: {
23878
+ "Content-Type": "application/json",
23879
+ "Accept": "application/json"
23880
+ }
23881
+ };
23882
+ return this.transformOptions(options_).then(transformedOptions_ => {
23883
+ return this.http.fetch(url_, transformedOptions_);
23884
+ }).then((_response) => {
23885
+ return this.processCreateSchemaCreatorState(_response);
23886
+ });
23887
+ }
23888
+ processCreateSchemaCreatorState(response) {
23889
+ const status = response.status;
23890
+ let _headers = {};
23891
+ if (response.headers && response.headers.forEach) {
23892
+ response.headers.forEach((v, k) => _headers[k] = v);
23893
+ }
23894
+ ;
23895
+ if (status === 201) {
23896
+ return response.text().then((_responseText) => {
23897
+ let result201 = null;
23898
+ result201 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
23899
+ return result201;
23900
+ });
23901
+ }
23902
+ else if (status === 409) {
23903
+ return response.text().then((_responseText) => {
23904
+ let result409 = null;
23905
+ result409 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
23906
+ return throwException("A server side error occurred.", status, _responseText, _headers, result409);
23907
+ });
23908
+ }
23909
+ else if (status !== 200 && status !== 204) {
23910
+ return response.text().then((_responseText) => {
23911
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
23912
+ });
23913
+ }
23914
+ return Promise.resolve(null);
23915
+ }
23916
+ updateSchemaCreatorState(id, state) {
23917
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate";
23918
+ if (id === undefined || id === null)
23919
+ throw new globalThis.Error("The parameter 'id' must be defined.");
23920
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
23921
+ url_ = url_.replace(/[?&]$/, "");
23922
+ const content_ = JSON.stringify(state);
23923
+ let options_ = {
23924
+ body: content_,
23925
+ method: "PUT",
23926
+ headers: {
23927
+ "Content-Type": "application/json",
23928
+ "Accept": "application/json"
23929
+ }
23930
+ };
23931
+ return this.transformOptions(options_).then(transformedOptions_ => {
23932
+ return this.http.fetch(url_, transformedOptions_);
23933
+ }).then((_response) => {
23934
+ return this.processUpdateSchemaCreatorState(_response);
23935
+ });
23936
+ }
23937
+ processUpdateSchemaCreatorState(response) {
23938
+ const status = response.status;
23939
+ let _headers = {};
23940
+ if (response.headers && response.headers.forEach) {
23941
+ response.headers.forEach((v, k) => _headers[k] = v);
23942
+ }
23943
+ ;
23944
+ if (status === 200) {
23945
+ return response.text().then((_responseText) => {
23946
+ let result200 = null;
23947
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
23948
+ return result200;
23949
+ });
23950
+ }
23951
+ else if (status !== 200 && status !== 204) {
23952
+ return response.text().then((_responseText) => {
23953
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
23954
+ });
23955
+ }
23956
+ return Promise.resolve(null);
23957
+ }
23958
+ /**
23959
+ * Starts a full drawing AI parse: clears every element and locks the
23960
+ schema for every viewer until it completes. If one is already in
23961
+ progress, returns that instead of starting a second one.
23962
+ */
23963
+ requestSchemaCreatorDocumentParse(id) {
23964
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate/parse-document";
23965
+ if (id === undefined || id === null)
23966
+ throw new globalThis.Error("The parameter 'id' must be defined.");
23967
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
23968
+ url_ = url_.replace(/[?&]$/, "");
23969
+ let options_ = {
23970
+ method: "POST",
23971
+ headers: {
23972
+ "Accept": "application/json"
23973
+ }
23974
+ };
23975
+ return this.transformOptions(options_).then(transformedOptions_ => {
23976
+ return this.http.fetch(url_, transformedOptions_);
23977
+ }).then((_response) => {
23978
+ return this.processRequestSchemaCreatorDocumentParse(_response);
23979
+ });
23980
+ }
23981
+ processRequestSchemaCreatorDocumentParse(response) {
23982
+ const status = response.status;
23983
+ let _headers = {};
23984
+ if (response.headers && response.headers.forEach) {
23985
+ response.headers.forEach((v, k) => _headers[k] = v);
23986
+ }
23987
+ ;
23988
+ if (status === 200) {
23989
+ return response.text().then((_responseText) => {
23990
+ let result200 = null;
23991
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
23992
+ return result200;
23993
+ });
23994
+ }
23995
+ else if (status !== 200 && status !== 204) {
23996
+ return response.text().then((_responseText) => {
23997
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
23998
+ });
23999
+ }
24000
+ return Promise.resolve(null);
24001
+ }
24002
+ /**
24003
+ * Stamps the creator state's balloons onto the schema's drawing PDF and
24004
+ returns a temporary download link.
24005
+ */
24006
+ exportSchemaCreatorDrawing(id) {
24007
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate/download";
24008
+ if (id === undefined || id === null)
24009
+ throw new globalThis.Error("The parameter 'id' must be defined.");
24010
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
24011
+ url_ = url_.replace(/[?&]$/, "");
24012
+ let options_ = {
24013
+ method: "POST",
24014
+ headers: {
24015
+ "Accept": "application/json"
24016
+ }
24017
+ };
24018
+ return this.transformOptions(options_).then(transformedOptions_ => {
24019
+ return this.http.fetch(url_, transformedOptions_);
24020
+ }).then((_response) => {
24021
+ return this.processExportSchemaCreatorDrawing(_response);
24022
+ });
24023
+ }
24024
+ processExportSchemaCreatorDrawing(response) {
24025
+ const status = response.status;
24026
+ let _headers = {};
24027
+ if (response.headers && response.headers.forEach) {
24028
+ response.headers.forEach((v, k) => _headers[k] = v);
24029
+ }
24030
+ ;
24031
+ if (status === 200) {
24032
+ return response.text().then((_responseText) => {
24033
+ let result200 = null;
24034
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
24035
+ return result200;
24036
+ });
24037
+ }
24038
+ else if (status !== 200 && status !== 204) {
24039
+ return response.text().then((_responseText) => {
24040
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
24041
+ });
24042
+ }
24043
+ return Promise.resolve(null);
24044
+ }
24045
+ /**
24046
+ * Starts an async snip resolve; the result is delivered through the
24047
+ SchemaCreatorSnipResolved SignalR notification.
24048
+ * @param image (optional)
24049
+ */
24050
+ requestSchemaCreatorSnipParse(id, elementId, image) {
24051
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate/elements/{elementId}/parse-snip";
24052
+ if (id === undefined || id === null)
24053
+ throw new globalThis.Error("The parameter 'id' must be defined.");
24054
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
24055
+ if (elementId === undefined || elementId === null)
24056
+ throw new globalThis.Error("The parameter 'elementId' must be defined.");
24057
+ url_ = url_.replace("{elementId}", encodeURIComponent("" + elementId));
24058
+ url_ = url_.replace(/[?&]$/, "");
24059
+ const content_ = new FormData();
24060
+ if (image !== null && image !== undefined)
24061
+ content_.append("image", image.data, image.fileName ? image.fileName : "image");
24062
+ let options_ = {
24063
+ body: content_,
24064
+ method: "POST",
24065
+ headers: {}
24066
+ };
24067
+ return this.transformOptions(options_).then(transformedOptions_ => {
24068
+ return this.http.fetch(url_, transformedOptions_);
24069
+ }).then((_response) => {
24070
+ return this.processRequestSchemaCreatorSnipParse(_response);
24071
+ });
24072
+ }
24073
+ processRequestSchemaCreatorSnipParse(response) {
24074
+ const status = response.status;
24075
+ let _headers = {};
24076
+ if (response.headers && response.headers.forEach) {
24077
+ response.headers.forEach((v, k) => _headers[k] = v);
24078
+ }
24079
+ ;
24080
+ if (status === 200) {
24081
+ return response.text().then((_responseText) => {
24082
+ return;
24083
+ });
24084
+ }
24085
+ else if (status !== 200 && status !== 204) {
24086
+ return response.text().then((_responseText) => {
24087
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
24088
+ });
24089
+ }
24090
+ return Promise.resolve(null);
24091
+ }
24092
+ }
23818
24093
  export class MeasurementFormSchemasAdminClient extends AuthorizedApiBase {
23819
24094
  constructor(configuration, baseUrl, http) {
23820
24095
  super(configuration);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ignos/api-client",
3
- "version": "20260826.246.1",
3
+ "version": "20260826.247.1-alpha",
4
4
  "description": "IGNOS API Client",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",
@@ -25474,6 +25474,315 @@ export class InspectMatchSpecificationsClient extends AuthorizedApiBase implemen
25474
25474
  }
25475
25475
  }
25476
25476
 
25477
+ export interface IInspectSchemaCreatorClient {
25478
+
25479
+ getSchemaCreatorState(id: string): Promise<SchemaCreatorStateDto>;
25480
+
25481
+ /**
25482
+ * Creates the initial creator state for a schema version. Returns 409 if
25483
+ state already exists; the caller should re-fetch it instead of writing.
25484
+ */
25485
+ createSchemaCreatorState(id: string, state: SchemaCreatorStateDto): Promise<SchemaCreatorStateDto>;
25486
+
25487
+ updateSchemaCreatorState(id: string, state: SchemaCreatorStateDto): Promise<SchemaCreatorStateDto>;
25488
+
25489
+ /**
25490
+ * Starts a full drawing AI parse: clears every element and locks the
25491
+ schema for every viewer until it completes. If one is already in
25492
+ progress, returns that instead of starting a second one.
25493
+ */
25494
+ requestSchemaCreatorDocumentParse(id: string): Promise<SchemaCreatorStateDto>;
25495
+
25496
+ /**
25497
+ * Stamps the creator state's balloons onto the schema's drawing PDF and
25498
+ returns a temporary download link.
25499
+ */
25500
+ exportSchemaCreatorDrawing(id: string): Promise<DownloadDto>;
25501
+
25502
+ /**
25503
+ * Starts an async snip resolve; the result is delivered through the
25504
+ SchemaCreatorSnipResolved SignalR notification.
25505
+ * @param image (optional)
25506
+ */
25507
+ requestSchemaCreatorSnipParse(id: string, elementId: string, image: FileParameter | null | undefined): Promise<void>;
25508
+ }
25509
+
25510
+ export class InspectSchemaCreatorClient extends AuthorizedApiBase implements IInspectSchemaCreatorClient {
25511
+ private http: { fetch(url: RequestInfo, init?: RequestInit): Promise<Response> };
25512
+ private baseUrl: string;
25513
+
25514
+ constructor(configuration: IApiClientConfig, baseUrl?: string, http?: { fetch(url: RequestInfo, init?: RequestInit): Promise<Response> }) {
25515
+ super(configuration);
25516
+ this.http = http ? http : window as any;
25517
+ this.baseUrl = baseUrl ?? "";
25518
+ }
25519
+
25520
+ getSchemaCreatorState(id: string): Promise<SchemaCreatorStateDto> {
25521
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate";
25522
+ if (id === undefined || id === null)
25523
+ throw new globalThis.Error("The parameter 'id' must be defined.");
25524
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
25525
+ url_ = url_.replace(/[?&]$/, "");
25526
+
25527
+ let options_: RequestInit = {
25528
+ method: "GET",
25529
+ headers: {
25530
+ "Accept": "application/json"
25531
+ }
25532
+ };
25533
+
25534
+ return this.transformOptions(options_).then(transformedOptions_ => {
25535
+ return this.http.fetch(url_, transformedOptions_);
25536
+ }).then((_response: Response) => {
25537
+ return this.processGetSchemaCreatorState(_response);
25538
+ });
25539
+ }
25540
+
25541
+ protected processGetSchemaCreatorState(response: Response): Promise<SchemaCreatorStateDto> {
25542
+ const status = response.status;
25543
+ let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
25544
+ if (status === 200) {
25545
+ return response.text().then((_responseText) => {
25546
+ let result200: any = null;
25547
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as SchemaCreatorStateDto;
25548
+ return result200;
25549
+ });
25550
+ } else if (status !== 200 && status !== 204) {
25551
+ return response.text().then((_responseText) => {
25552
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
25553
+ });
25554
+ }
25555
+ return Promise.resolve<SchemaCreatorStateDto>(null as any);
25556
+ }
25557
+
25558
+ /**
25559
+ * Creates the initial creator state for a schema version. Returns 409 if
25560
+ state already exists; the caller should re-fetch it instead of writing.
25561
+ */
25562
+ createSchemaCreatorState(id: string, state: SchemaCreatorStateDto): Promise<SchemaCreatorStateDto> {
25563
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate";
25564
+ if (id === undefined || id === null)
25565
+ throw new globalThis.Error("The parameter 'id' must be defined.");
25566
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
25567
+ url_ = url_.replace(/[?&]$/, "");
25568
+
25569
+ const content_ = JSON.stringify(state);
25570
+
25571
+ let options_: RequestInit = {
25572
+ body: content_,
25573
+ method: "POST",
25574
+ headers: {
25575
+ "Content-Type": "application/json",
25576
+ "Accept": "application/json"
25577
+ }
25578
+ };
25579
+
25580
+ return this.transformOptions(options_).then(transformedOptions_ => {
25581
+ return this.http.fetch(url_, transformedOptions_);
25582
+ }).then((_response: Response) => {
25583
+ return this.processCreateSchemaCreatorState(_response);
25584
+ });
25585
+ }
25586
+
25587
+ protected processCreateSchemaCreatorState(response: Response): Promise<SchemaCreatorStateDto> {
25588
+ const status = response.status;
25589
+ let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
25590
+ if (status === 201) {
25591
+ return response.text().then((_responseText) => {
25592
+ let result201: any = null;
25593
+ result201 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as SchemaCreatorStateDto;
25594
+ return result201;
25595
+ });
25596
+ } else if (status === 409) {
25597
+ return response.text().then((_responseText) => {
25598
+ let result409: any = null;
25599
+ result409 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ProblemDetails;
25600
+ return throwException("A server side error occurred.", status, _responseText, _headers, result409);
25601
+ });
25602
+ } else if (status !== 200 && status !== 204) {
25603
+ return response.text().then((_responseText) => {
25604
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
25605
+ });
25606
+ }
25607
+ return Promise.resolve<SchemaCreatorStateDto>(null as any);
25608
+ }
25609
+
25610
+ updateSchemaCreatorState(id: string, state: SchemaCreatorStateDto): Promise<SchemaCreatorStateDto> {
25611
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate";
25612
+ if (id === undefined || id === null)
25613
+ throw new globalThis.Error("The parameter 'id' must be defined.");
25614
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
25615
+ url_ = url_.replace(/[?&]$/, "");
25616
+
25617
+ const content_ = JSON.stringify(state);
25618
+
25619
+ let options_: RequestInit = {
25620
+ body: content_,
25621
+ method: "PUT",
25622
+ headers: {
25623
+ "Content-Type": "application/json",
25624
+ "Accept": "application/json"
25625
+ }
25626
+ };
25627
+
25628
+ return this.transformOptions(options_).then(transformedOptions_ => {
25629
+ return this.http.fetch(url_, transformedOptions_);
25630
+ }).then((_response: Response) => {
25631
+ return this.processUpdateSchemaCreatorState(_response);
25632
+ });
25633
+ }
25634
+
25635
+ protected processUpdateSchemaCreatorState(response: Response): Promise<SchemaCreatorStateDto> {
25636
+ const status = response.status;
25637
+ let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
25638
+ if (status === 200) {
25639
+ return response.text().then((_responseText) => {
25640
+ let result200: any = null;
25641
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as SchemaCreatorStateDto;
25642
+ return result200;
25643
+ });
25644
+ } else if (status !== 200 && status !== 204) {
25645
+ return response.text().then((_responseText) => {
25646
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
25647
+ });
25648
+ }
25649
+ return Promise.resolve<SchemaCreatorStateDto>(null as any);
25650
+ }
25651
+
25652
+ /**
25653
+ * Starts a full drawing AI parse: clears every element and locks the
25654
+ schema for every viewer until it completes. If one is already in
25655
+ progress, returns that instead of starting a second one.
25656
+ */
25657
+ requestSchemaCreatorDocumentParse(id: string): Promise<SchemaCreatorStateDto> {
25658
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate/parse-document";
25659
+ if (id === undefined || id === null)
25660
+ throw new globalThis.Error("The parameter 'id' must be defined.");
25661
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
25662
+ url_ = url_.replace(/[?&]$/, "");
25663
+
25664
+ let options_: RequestInit = {
25665
+ method: "POST",
25666
+ headers: {
25667
+ "Accept": "application/json"
25668
+ }
25669
+ };
25670
+
25671
+ return this.transformOptions(options_).then(transformedOptions_ => {
25672
+ return this.http.fetch(url_, transformedOptions_);
25673
+ }).then((_response: Response) => {
25674
+ return this.processRequestSchemaCreatorDocumentParse(_response);
25675
+ });
25676
+ }
25677
+
25678
+ protected processRequestSchemaCreatorDocumentParse(response: Response): Promise<SchemaCreatorStateDto> {
25679
+ const status = response.status;
25680
+ let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
25681
+ if (status === 200) {
25682
+ return response.text().then((_responseText) => {
25683
+ let result200: any = null;
25684
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as SchemaCreatorStateDto;
25685
+ return result200;
25686
+ });
25687
+ } else if (status !== 200 && status !== 204) {
25688
+ return response.text().then((_responseText) => {
25689
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
25690
+ });
25691
+ }
25692
+ return Promise.resolve<SchemaCreatorStateDto>(null as any);
25693
+ }
25694
+
25695
+ /**
25696
+ * Stamps the creator state's balloons onto the schema's drawing PDF and
25697
+ returns a temporary download link.
25698
+ */
25699
+ exportSchemaCreatorDrawing(id: string): Promise<DownloadDto> {
25700
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate/download";
25701
+ if (id === undefined || id === null)
25702
+ throw new globalThis.Error("The parameter 'id' must be defined.");
25703
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
25704
+ url_ = url_.replace(/[?&]$/, "");
25705
+
25706
+ let options_: RequestInit = {
25707
+ method: "POST",
25708
+ headers: {
25709
+ "Accept": "application/json"
25710
+ }
25711
+ };
25712
+
25713
+ return this.transformOptions(options_).then(transformedOptions_ => {
25714
+ return this.http.fetch(url_, transformedOptions_);
25715
+ }).then((_response: Response) => {
25716
+ return this.processExportSchemaCreatorDrawing(_response);
25717
+ });
25718
+ }
25719
+
25720
+ protected processExportSchemaCreatorDrawing(response: Response): Promise<DownloadDto> {
25721
+ const status = response.status;
25722
+ let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
25723
+ if (status === 200) {
25724
+ return response.text().then((_responseText) => {
25725
+ let result200: any = null;
25726
+ result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as DownloadDto;
25727
+ return result200;
25728
+ });
25729
+ } else if (status !== 200 && status !== 204) {
25730
+ return response.text().then((_responseText) => {
25731
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
25732
+ });
25733
+ }
25734
+ return Promise.resolve<DownloadDto>(null as any);
25735
+ }
25736
+
25737
+ /**
25738
+ * Starts an async snip resolve; the result is delivered through the
25739
+ SchemaCreatorSnipResolved SignalR notification.
25740
+ * @param image (optional)
25741
+ */
25742
+ requestSchemaCreatorSnipParse(id: string, elementId: string, image: FileParameter | null | undefined): Promise<void> {
25743
+ let url_ = this.baseUrl + "/measurementforms/schemas/{id}/creatorstate/elements/{elementId}/parse-snip";
25744
+ if (id === undefined || id === null)
25745
+ throw new globalThis.Error("The parameter 'id' must be defined.");
25746
+ url_ = url_.replace("{id}", encodeURIComponent("" + id));
25747
+ if (elementId === undefined || elementId === null)
25748
+ throw new globalThis.Error("The parameter 'elementId' must be defined.");
25749
+ url_ = url_.replace("{elementId}", encodeURIComponent("" + elementId));
25750
+ url_ = url_.replace(/[?&]$/, "");
25751
+
25752
+ const content_ = new FormData();
25753
+ if (image !== null && image !== undefined)
25754
+ content_.append("image", image.data, image.fileName ? image.fileName : "image");
25755
+
25756
+ let options_: RequestInit = {
25757
+ body: content_,
25758
+ method: "POST",
25759
+ headers: {
25760
+ }
25761
+ };
25762
+
25763
+ return this.transformOptions(options_).then(transformedOptions_ => {
25764
+ return this.http.fetch(url_, transformedOptions_);
25765
+ }).then((_response: Response) => {
25766
+ return this.processRequestSchemaCreatorSnipParse(_response);
25767
+ });
25768
+ }
25769
+
25770
+ protected processRequestSchemaCreatorSnipParse(response: Response): Promise<void> {
25771
+ const status = response.status;
25772
+ let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
25773
+ if (status === 200) {
25774
+ return response.text().then((_responseText) => {
25775
+ return;
25776
+ });
25777
+ } else if (status !== 200 && status !== 204) {
25778
+ return response.text().then((_responseText) => {
25779
+ return throwException("An unexpected server error occurred.", status, _responseText, _headers);
25780
+ });
25781
+ }
25782
+ return Promise.resolve<void>(null as any);
25783
+ }
25784
+ }
25785
+
25477
25786
  export interface IMeasurementFormSchemasAdminClient {
25478
25787
 
25479
25788
  getArchivedMeasurementFormSchema(id: string): Promise<MeasurementFormSchemaDto>;
@@ -37171,10 +37480,9 @@ export interface ImaDocumentTypesResultsDto {
37171
37480
  export interface ImaSupplementaryCheckResultDto {
37172
37481
  heatNumbers?: string[];
37173
37482
  status?: string | null;
37174
- documentId?: string | null;
37483
+ errorString?: string | null;
37175
37484
  acceptable?: boolean | null;
37176
37485
  standards: string[];
37177
- summary?: string | null;
37178
37486
  override?: ImaResultLineOverrideDto | null;
37179
37487
  }
37180
37488
 
@@ -37785,6 +38093,117 @@ export interface ImaSpecificationLiteDto {
37785
38093
  isDeleted: boolean;
37786
38094
  }
37787
38095
 
38096
+ export interface SchemaCreatorStateDto {
38097
+ settings: SchemaCreatorSettingsDto;
38098
+ elements: SchemaCreatorElementDto[];
38099
+ documentParseStatus?: SchemaCreatorDocumentParseStatusDto | null;
38100
+ isAutoGenerated?: boolean;
38101
+ createdBy?: SchemaCreatorAuditInfoDto | null;
38102
+ createdAt?: Date | null;
38103
+ updatedBy?: SchemaCreatorAuditInfoDto | null;
38104
+ updatedAt?: Date | null;
38105
+ }
38106
+
38107
+ export interface SchemaCreatorSettingsDto {
38108
+ unit?: UnitOfMeasureDto;
38109
+ tolerance?: GeneralToleranceDto;
38110
+ balloonSize?: number;
38111
+ transparentBalloons?: boolean;
38112
+ }
38113
+
38114
+ export type UnitOfMeasureDto = "Millimeter" | "Inch";
38115
+
38116
+ export type GeneralToleranceDto = "NotSet" | "Fine" | "Medium" | "Coarse" | "VeryCoarse";
38117
+
38118
+ export interface SchemaCreatorElementDto {
38119
+ id: string;
38120
+ kind: SchemaCreatorElementKindDto;
38121
+ drawings: SchemaCreatorElementDrawingsDto;
38122
+ isDirty?: boolean | null;
38123
+ values?: SchemaCreatorElementValuesDto | null;
38124
+ parseResult?: SchemaCreatorSnipResultDto | null;
38125
+ resolveAttempt?: SchemaCreatorParseAttemptDto | null;
38126
+ createdBy?: SchemaCreatorAuditInfoDto | null;
38127
+ createdAt?: Date | null;
38128
+ updatedBy?: SchemaCreatorAuditInfoDto | null;
38129
+ updatedAt?: Date | null;
38130
+ }
38131
+
38132
+ export type SchemaCreatorElementKindDto = "Pending" | "Auto" | "Manual";
38133
+
38134
+ export interface SchemaCreatorElementDrawingsDto {
38135
+ snip: SchemaCreatorSnipDto;
38136
+ balloon: SchemaCreatorPointDto;
38137
+ pageIndex: number;
38138
+ }
38139
+
38140
+ export interface SchemaCreatorSnipDto {
38141
+ rect: SchemaCreatorRectDto;
38142
+ rotation?: number | null;
38143
+ unrotatedRect?: SchemaCreatorRectDto | null;
38144
+ }
38145
+
38146
+ export interface SchemaCreatorRectDto {
38147
+ origin: SchemaCreatorPointDto;
38148
+ size: SchemaCreatorSizeDto;
38149
+ }
38150
+
38151
+ export interface SchemaCreatorPointDto {
38152
+ x: number;
38153
+ y: number;
38154
+ }
38155
+
38156
+ export interface SchemaCreatorSizeDto {
38157
+ width: number;
38158
+ height: number;
38159
+ }
38160
+
38161
+ export interface SchemaCreatorElementValuesDto {
38162
+ reference: number;
38163
+ nominal?: number | null;
38164
+ nominalText?: string | null;
38165
+ plusTolerance?: number | null;
38166
+ minusTolerance?: number | null;
38167
+ coatingThickness?: number | null;
38168
+ measurementFrequency: MeasurementFrequency;
38169
+ measurementFrequencyParameter?: number | null;
38170
+ type?: string | null;
38171
+ count?: number | null;
38172
+ comment?: string | null;
38173
+ canCopy: boolean;
38174
+ visibleToCustomer: boolean;
38175
+ isDocumentedExternally: boolean;
38176
+ }
38177
+
38178
+ export type MeasurementFrequency = "All" | "FirstArticle" | "NFirst" | "NPercent" | "ISO2859" | "Nth" | "FirstAndLast" | "None";
38179
+
38180
+ export interface SchemaCreatorSnipResultDto {
38181
+ nominal?: number | null;
38182
+ nominalText?: string | null;
38183
+ plusTolerance?: number | null;
38184
+ minusTolerance?: number | null;
38185
+ count?: number | null;
38186
+ }
38187
+
38188
+ export interface SchemaCreatorParseAttemptDto {
38189
+ startedAt: Date;
38190
+ errorType?: SchemaCreatorParseErrorTypeDto | null;
38191
+ errorMessage?: string | null;
38192
+ }
38193
+
38194
+ export type SchemaCreatorParseErrorTypeDto = "Timeout" | "ParseError";
38195
+
38196
+ export interface SchemaCreatorAuditInfoDto {
38197
+ objectId: string;
38198
+ userId: string;
38199
+ userFullName?: string | null;
38200
+ }
38201
+
38202
+ export interface SchemaCreatorDocumentParseStatusDto {
38203
+ inProgress: boolean;
38204
+ attempt?: SchemaCreatorParseAttemptDto | null;
38205
+ }
38206
+
37788
38207
  export interface MeasurementFormSchemaDto {
37789
38208
  id: string;
37790
38209
  versionId: number;
@@ -37819,12 +38238,8 @@ export type MeasurementFormStatus = "Draft" | "Released" | "Revoked";
37819
38238
 
37820
38239
  export type MeasurementFormSource = "Unknown" | "InspectionXpert" | "Excel" | "Manual";
37821
38240
 
37822
- export type UnitOfMeasureDto = "Millimeter" | "Inch";
37823
-
37824
38241
  export type DimensionSettingDto = "Tolerance" | "MinMaxDimension";
37825
38242
 
37826
- export type GeneralToleranceDto = "NotSet" | "Fine" | "Medium" | "Coarse" | "VeryCoarse";
37827
-
37828
38243
  export interface MeasurementFormSchemaAttachmentDto {
37829
38244
  url: string;
37830
38245
  title: string;
@@ -37875,8 +38290,6 @@ export interface MeasurementFormGroupedElementDto {
37875
38290
  validationErrorMessage?: string | null;
37876
38291
  }
37877
38292
 
37878
- export type MeasurementFrequency = "All" | "FirstArticle" | "NFirst" | "NPercent" | "ISO2859" | "Nth" | "FirstAndLast" | "None";
37879
-
37880
38293
  export type MeasurementFormValueType = "None" | "Bool" | "Decimal" | "String";
37881
38294
 
37882
38295
  export type BonusType = "None" | "Positive" | "PositiveAndNegative";