@remit/api-openapi-types 0.0.89 → 0.0.90
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/package.json +1 -1
- package/types.d.ts +102 -0
package/package.json
CHANGED
package/types.d.ts
CHANGED
|
@@ -225,6 +225,18 @@ current enum emitter anyway, so the wire contract uses the bare form.
|
|
|
225
225
|
* The request shape a classification provider speaks. `DecisionApi` returns a calibrated probability per label; `ChatJsonSchema` is an OpenAI-compatible chat completion constrained to the label enum; `JinaClassify` is Jina's `/v1/classify`.
|
|
226
226
|
*/
|
|
227
227
|
export type ClassificationAdapterShape = "DecisionApi" | "ChatJsonSchema" | "JinaClassify";
|
|
228
|
+
/**
|
|
229
|
+
* A label a classification provider picks for a message: the junk verdicts, priority, and the message categories.
|
|
230
|
+
*/
|
|
231
|
+
export type ClassificationLabel = "Spam" | "Phishing" | "Priority" | "Personal" | "Newsletter" | "Marketing" | "Automated" | "Transactional" | "Social";
|
|
232
|
+
/**
|
|
233
|
+
* Why a classification provider call gave no usable answer.
|
|
234
|
+
*/
|
|
235
|
+
export type ClassificationFailureKind = "Unauthorized" | "ModelNotFound" | "RateLimited" | "Rejected" | "ProviderError" | "Unreachable" | "TimedOut" | "Unparseable";
|
|
236
|
+
/**
|
|
237
|
+
* The classification provider form field a failure points at.
|
|
238
|
+
*/
|
|
239
|
+
export type ClassificationField = "ApiKey" | "Model" | "BaseUrl";
|
|
228
240
|
/**
|
|
229
241
|
* Sort order for list operations
|
|
230
242
|
*/
|
|
@@ -3742,6 +3754,65 @@ field on this resource rather than one more operation.
|
|
|
3742
3754
|
*/
|
|
3743
3755
|
classificationDailyLimit?: number;
|
|
3744
3756
|
}
|
|
3757
|
+
/**
|
|
3758
|
+
* The classification provider form as it stands, saved or not.
|
|
3759
|
+
*/
|
|
3760
|
+
export interface ClassificationTestInput {
|
|
3761
|
+
presetId: ClassificationPresetId;
|
|
3762
|
+
/**
|
|
3763
|
+
* The model to ask for. Empty means the preset's default model.
|
|
3764
|
+
*/
|
|
3765
|
+
model: string;
|
|
3766
|
+
/**
|
|
3767
|
+
* The http or https base URL to call. Empty means the preset's default base URL.
|
|
3768
|
+
*/
|
|
3769
|
+
baseUrl: string;
|
|
3770
|
+
/**
|
|
3771
|
+
* The provider's API key. Empty means the key saved for this preset.
|
|
3772
|
+
*/
|
|
3773
|
+
apiKey: string;
|
|
3774
|
+
}
|
|
3775
|
+
/**
|
|
3776
|
+
* The provider classified the sample message.
|
|
3777
|
+
*/
|
|
3778
|
+
export interface ClassificationTestPassed {
|
|
3779
|
+
state: "Passed";
|
|
3780
|
+
/**
|
|
3781
|
+
* How long the provider call took, in milliseconds.
|
|
3782
|
+
*/
|
|
3783
|
+
latencyMs: number;
|
|
3784
|
+
/**
|
|
3785
|
+
* The label the provider chose for the sample message.
|
|
3786
|
+
*/
|
|
3787
|
+
label: ClassificationLabel;
|
|
3788
|
+
/**
|
|
3789
|
+
* The provider's confidence in `label`, between 0 and 1.
|
|
3790
|
+
*/
|
|
3791
|
+
confidence: number;
|
|
3792
|
+
}
|
|
3793
|
+
/**
|
|
3794
|
+
* The provider call gave no usable answer.
|
|
3795
|
+
*/
|
|
3796
|
+
export interface ClassificationTestFailed {
|
|
3797
|
+
state: "Failed";
|
|
3798
|
+
/**
|
|
3799
|
+
* How long the provider call took, in milliseconds.
|
|
3800
|
+
*/
|
|
3801
|
+
latencyMs: number;
|
|
3802
|
+
/**
|
|
3803
|
+
* The HTTP status the provider answered with. Absent when no answer arrived.
|
|
3804
|
+
*/
|
|
3805
|
+
status?: number;
|
|
3806
|
+
kind: ClassificationFailureKind;
|
|
3807
|
+
/**
|
|
3808
|
+
* The form field to change. Absent when no field can fix it: a rate limit or a provider error.
|
|
3809
|
+
*/
|
|
3810
|
+
field?: ClassificationField;
|
|
3811
|
+
/**
|
|
3812
|
+
* What to change so the next test passes.
|
|
3813
|
+
*/
|
|
3814
|
+
fix: string;
|
|
3815
|
+
}
|
|
3745
3816
|
/**
|
|
3746
3817
|
* Tasks due in the requested window, in due order. Unpaginated: the window is the bound.
|
|
3747
3818
|
*/
|
|
@@ -7801,6 +7872,13 @@ declare namespace Paths {
|
|
|
7801
7872
|
export type $401 = void;
|
|
7802
7873
|
}
|
|
7803
7874
|
}
|
|
7875
|
+
namespace TestClassificationProvider {
|
|
7876
|
+
export type RequestBody = Components.Schemas.ClassificationTestInput;
|
|
7877
|
+
namespace Responses {
|
|
7878
|
+
export type $400 = void;
|
|
7879
|
+
export type $401 = void;
|
|
7880
|
+
}
|
|
7881
|
+
}
|
|
7804
7882
|
namespace ListCalendarTasks {
|
|
7805
7883
|
export interface QueryParameters {
|
|
7806
7884
|
from: string;
|
|
@@ -8796,6 +8874,14 @@ reader organizes the event, none otherwise.
|
|
|
8796
8874
|
data?: any,
|
|
8797
8875
|
config?: AxiosRequestConfig
|
|
8798
8876
|
): OperationResponse<Paths.ClearClassificationProvider.Responses.$200>;
|
|
8877
|
+
/**
|
|
8878
|
+
* testClassificationProvider - Classify one built-in sample message with the form values, saved or not, and answer with the label or the failure. An empty key uses the saved key. Saved settings stay as they were, and the call counts toward no daily limit.
|
|
8879
|
+
*/
|
|
8880
|
+
'testClassificationProvider'(
|
|
8881
|
+
parameters?: Parameters<UnknownParamsObject> | null,
|
|
8882
|
+
data?: Paths.TestClassificationProvider.RequestBody,
|
|
8883
|
+
config?: AxiosRequestConfig
|
|
8884
|
+
): OperationResponse<any>;
|
|
8799
8885
|
/**
|
|
8800
8886
|
* listCalendarTasks - Tasks due in a window, across every task collection the caller holds, in due order. Refused with 400 on the same window rules as the event listing.
|
|
8801
8887
|
*/
|
|
@@ -9765,6 +9851,16 @@ reader organizes the event, none otherwise.
|
|
|
9765
9851
|
config?: AxiosRequestConfig
|
|
9766
9852
|
): OperationResponse<Paths.ClearClassificationProvider.Responses.$200>;
|
|
9767
9853
|
};
|
|
9854
|
+
['/settings/classification-test']: {
|
|
9855
|
+
/**
|
|
9856
|
+
* testClassificationProvider - Classify one built-in sample message with the form values, saved or not, and answer with the label or the failure. An empty key uses the saved key. Saved settings stay as they were, and the call counts toward no daily limit.
|
|
9857
|
+
*/
|
|
9858
|
+
'post'(
|
|
9859
|
+
parameters?: Parameters<UnknownParamsObject> | null,
|
|
9860
|
+
data?: Paths.TestClassificationProvider.RequestBody,
|
|
9861
|
+
config?: AxiosRequestConfig
|
|
9862
|
+
): OperationResponse<any>;
|
|
9863
|
+
};
|
|
9768
9864
|
['/calendar-tasks']: {
|
|
9769
9865
|
/**
|
|
9770
9866
|
* listCalendarTasks - Tasks due in a window, across every task collection the caller holds, in due order. Refused with 400 on the same window rules as the event listing.
|
|
@@ -10382,6 +10478,9 @@ export type ClassificationNoPrice = Components.Schemas.ClassificationNoPrice;
|
|
|
10382
10478
|
export type ClassificationNotConfigured = Components.Schemas.ClassificationNotConfigured;
|
|
10383
10479
|
export type ClassificationConfigured = Components.Schemas.ClassificationConfigured;
|
|
10384
10480
|
export type UpdateUserSettingsInput = Components.Schemas.UpdateUserSettingsInput;
|
|
10481
|
+
export type ClassificationTestInput = Components.Schemas.ClassificationTestInput;
|
|
10482
|
+
export type ClassificationTestPassed = Components.Schemas.ClassificationTestPassed;
|
|
10483
|
+
export type ClassificationTestFailed = Components.Schemas.ClassificationTestFailed;
|
|
10385
10484
|
export type CalendarTaskListResponse = Components.Schemas.CalendarTaskListResponse;
|
|
10386
10485
|
export type CalendarTask = Components.Schemas.CalendarTask;
|
|
10387
10486
|
export type CalendarTaskResponse = Components.Schemas.CalendarTaskResponse;
|
|
@@ -10535,6 +10634,9 @@ export type CalendarInviteAnswer = Components.Schemas.CalendarInviteAnswer;
|
|
|
10535
10634
|
export type ClassificationPresetId = Components.Schemas.ClassificationPresetId;
|
|
10536
10635
|
export type ClassificationPresetGroup = Components.Schemas.ClassificationPresetGroup;
|
|
10537
10636
|
export type ClassificationAdapterShape = Components.Schemas.ClassificationAdapterShape;
|
|
10637
|
+
export type ClassificationLabel = Components.Schemas.ClassificationLabel;
|
|
10638
|
+
export type ClassificationFailureKind = Components.Schemas.ClassificationFailureKind;
|
|
10639
|
+
export type ClassificationField = Components.Schemas.ClassificationField;
|
|
10538
10640
|
export type SortOrder = Components.Schemas.SortOrder;
|
|
10539
10641
|
export type StarColor = Components.Schemas.StarColor;
|
|
10540
10642
|
export type MessageCategory = Components.Schemas.MessageCategory;
|