Skip to content

Commit 2bf640f

Browse files
hkardosHolden Kardos
andauthored
Adds the authorization type for adding validation hooks (#135)
* Adds the authorization type for adding validation hooks * Bump version --------- Co-authored-by: Holden Kardos <[email protected]>
1 parent 82bf38c commit 2bf640f

File tree

6 files changed

+18
-4
lines changed

6 files changed

+18
-4
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ This log is intended to keep track of package changes, including
77
but not limited to API changes and file location changes. Minor behavioral
88
changes may not be included if they are not expected to break existing code.
99

10+
## 0.7.2 (2025-07-01)
11+
12+
- Add `auth_type` to `OneSchemaValidationHookToAdd`
13+
- Add `format` to `NumberValidationOptions`
14+
1015
## 0.7.1 (2025-03-11)
1116

1217
- Add `is_locked` to `OneSchemaTemplateColumn` type.

packages/importer-angular/projects/oneschema/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@oneschema/angular",
33
"private": false,
4-
"version": "0.7.1",
4+
"version": "0.7.2",
55
"description": "Angular module for embedding OneSchema Importer",
66
"author": "OneSchema",
77
"license": "MIT",

packages/importer-react/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@oneschema/react",
33
"private": false,
4-
"version": "0.7.1",
4+
"version": "0.7.2",
55
"description": "React component for embedding OneSchema Importer",
66
"author": "OneSchema",
77
"license": "MIT",

packages/importer-vue/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@oneschema/vue",
33
"private": false,
4-
"version": "0.7.1",
4+
"version": "0.7.2",
55
"description": "Vue plugin for embedding OneSchema Importer",
66
"author": "OneSchema",
77
"license": "MIT",

packages/importer/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@oneschema/importer",
33
"private": false,
4-
"version": "0.7.1",
4+
"version": "0.7.2",
55
"description": "Vanilla JS library for embedding OneSchema Importer",
66
"author": "OneSchema",
77
"license": "MIT",

packages/importer/src/config.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -397,6 +397,14 @@ export type OneSchemaTemplateColumnToRemove = Pick<OneSchemaTemplateColumn, "key
397397
*/
398398
export type ValidationHookType = "row" | "column"
399399

400+
/**
401+
* Type of authorization used in the header of a validation hook: either "basic" or "bearer_user_jwt".
402+
* For "basic", the secret key is used to authenticate the request.
403+
* For "bearer_user_jwt", the user JWT is used to authenticate the request.
404+
* For more information on a particular setting see https://docs.oneschema.co/docs/validation-webhook#securing-your-validation-hook
405+
*/
406+
export type ValidationHookAuthorizationType = "basic" | "bearer_user_jwt"
407+
400408
/**
401409
* Params for adding a validation hook to a template
402410
*/
@@ -406,6 +414,7 @@ export interface OneSchemaValidationHookToAdd {
406414
column_keys?: string[]
407415
custom_column_keys?: string[]
408416
hook_type?: ValidationHookType
417+
authorization_type?: ValidationHookAuthorizationType
409418
secret_key?: string
410419
batch_size?: number
411420
}

0 commit comments

Comments
 (0)