Socket
Book a DemoInstallSign in
Socket

@atproto/lexicon

Package Overview
Dependencies
Maintainers
4
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@atproto/lexicon - npm Package Compare versions

Comparing version

to
0.4.12

6

CHANGELOG.md
# @atproto/lexicon
## 0.4.12
### Patch Changes
- [#3999](https://github.com/bluesky-social/atproto/pull/3999) [`8ef976d38`](https://github.com/bluesky-social/atproto/commit/8ef976d3852df4bfa376e515e131cc0810a42f20) Thanks [@matthieusieben](https://github.com/matthieusieben)! - Improve return type of `assertValidXrpcParams`
## 0.4.11

@@ -4,0 +10,0 @@

2

dist/lexicons.d.ts

@@ -54,3 +54,3 @@ import { LexUserType, LexiconDoc, ValidationResult } from './types';

*/
assertValidXrpcParams(lexUri: string, value: unknown): unknown;
assertValidXrpcParams(lexUri: string, value: unknown): Record<string, unknown> | undefined;
/**

@@ -57,0 +57,0 @@ * Validate xrpc input body and throw on any error.

import { Lexicons } from './lexicons';
import { LexRecord, LexXrpcProcedure, LexXrpcQuery, LexXrpcSubscription } from './types';
export declare function assertValidRecord(lexicons: Lexicons, def: LexRecord, value: unknown): unknown;
export declare function assertValidXrpcParams(lexicons: Lexicons, def: LexXrpcProcedure | LexXrpcQuery | LexXrpcSubscription, value: unknown): unknown;
export declare function assertValidXrpcParams(lexicons: Lexicons, def: LexXrpcProcedure | LexXrpcQuery | LexXrpcSubscription, value: unknown): Record<string, unknown> | undefined;
export declare function assertValidXrpcInput(lexicons: Lexicons, def: LexXrpcProcedure, value: unknown): unknown;

@@ -6,0 +6,0 @@ export declare function assertValidXrpcOutput(lexicons: Lexicons, def: LexXrpcProcedure | LexXrpcQuery, value: unknown): unknown;

import { Lexicons } from '../lexicons';
import { LexXrpcParameters, ValidationResult } from '../types';
export declare function params(lexicons: Lexicons, path: string, def: LexXrpcParameters, val: unknown): ValidationResult;
export declare function params(lexicons: Lexicons, path: string, def: LexXrpcParameters, val: unknown): ValidationResult<Record<string, unknown>>;
//# sourceMappingURL=xrpc.d.ts.map
Dual MIT/Apache-2.0 License
Copyright (c) 2022-2025 Bluesky PBC, and Contributors
Copyright (c) 2022-2025 Bluesky Social PBC, and Contributors

@@ -5,0 +5,0 @@ Except as otherwise noted in individual files, this software is licensed under the MIT license (<http://opensource.org/licenses/MIT>), or the Apache License, Version 2.0 (<http://www.apache.org/licenses/LICENSE-2.0>).

{
"name": "@atproto/lexicon",
"version": "0.4.11",
"version": "0.4.12",
"license": "MIT",

@@ -5,0 +5,0 @@ "description": "atproto Lexicon schema language library",

@@ -11,3 +11,3 @@ import { Lexicons } from '../lexicons'

val: unknown,
): ValidationResult {
): ValidationResult<Record<string, unknown>> {
// type

@@ -19,3 +19,3 @@ const value = val && typeof val === 'object' ? val : {}

// properties
let resultValue = value
let resultValue = value as Record<string, unknown>
if (typeof def.properties === 'object') {

@@ -22,0 +22,0 @@ for (const key in def.properties) {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet